tsensor_ll.h 1.1 KB

12345678910111213141516171819202122232425262728293031323334
  1. #ifndef APP_TSENSOR_LL_H
  2. #define APP_TSENSOR_LL_H
  3. #include "app/thermo/tsensor_common.h"
  4. typedef struct
  5. {
  6. bool ( * Init)();
  7. bool ( * GetTemp)( tTSensorTemp * temp );
  8. void ( * DeInit)();
  9. }
  10. sI2CTempSensorHandle_t;
  11. // THERMO_SENSOR_POWERCONTROL_HW
  12. // Use hardware power control: enable and disable the sensor power delivery
  13. #define THERMO_SENSOR_POWERCONTROL_HW 0
  14. // THERMO_SENSOR_POWERCONTROL_HW_KEEPPOWERED
  15. // Hardware power control: keep the sensor powered even the sensor is deinitialized
  16. #define THERMO_SENSOR_POWERCONTROL_HW_KEEPPOWERED 1
  17. // THERMO_SENSOR_POWERCONTROL_HW_LAZYCONFIG
  18. // Hardware power control: do not reconfigure sensor if the power kept
  19. // Depends on: THERMO_SENSOR_POWERCONTROL_HW=1
  20. #define THERMO_SENSOR_POWERCONTROL_HW_LAZYCONFIG 0
  21. // THERMO_SENSOR_ADDRESS
  22. // 8-bit I2C-bus address (the bit-0 will be ignored)
  23. #define THERMO_SENSOR_8bit_ADDRESS (0x92)
  24. // THERMO_SENSOR_MODEL
  25. #define THERMO_SENSOR_MODEL AD7414
  26. extern const sI2CTempSensorHandle_t I2CTempSensor;
  27. #endif