#ifndef MAXHANDLER_H_ #define MAXHANDLER_H_ #include "software_SPI.h" #include "RSLinkCustom.h" #include "SYSTEM.h" //Define some channel stuff here typedef struct{ uint8_t state; uint32_t Temperature; uint16_t CJTemp; uint32_t lastTick; uint8_t captureFlags; //uint8_t pin; } ThermoData; #define THERMO_CHN_COUNT 3 //TODO Duplicate from IDIBUS_IMPL_Custom //Also hardcoded value in sSPI ThermoData ThermoSensor[THERMO_CHN_COUNT]; enum InitMode { //BitFlags NoConversion = 0x00, OneShotConversion = 0x01, AutoConversion = 0x02 }; uint8_t MaxSelectedChannel; void Max_Init(uint8_t ch, uint8_t initMode); uint8_t IsMaxDRDYLow(uint8_t ch); void Max_Handler(); #endif /* MAXHANDLER_H_ */