move thermistor calculation to watch utilities

This commit is contained in:
Joey Castillo
2021-11-22 17:31:51 -05:00
parent fb8f4584a5
commit 0ca729eaba
4 changed files with 66 additions and 65 deletions

View File

@@ -1,10 +1,16 @@
#ifndef THERMISTOR_DRIVER_H_
#define THERMISTOR_DRIVER_H_
// NOTE: This implementation is specific to one prototype sensor board, OSO-MISC-21-009, but both
// the sensor board design and this implementation are likely to change. Thermistor functionality
// may even end up being baked into the Sensor Watch library. This is all by way of saying this
// code is very temporary and the thermistor screens will likely get a rewrite in the future.
// TODO: Do these belong in movement_config.h? In settings we can set on the watch? In an EEPROM configuration area?
// Think on this. [joey 11/22]
#define THERMISTOR_SENSE_PIN (A2)
#define THERMISTOR_ENABLE_PIN (A0)
#define THERMISTOR_ENABLE_VALUE (false)
#define THERMISTOR_HIGH_SIDE (true)
#define THERMISTOR_B_COEFFICIENT (3380.0)
#define THERMISTOR_NOMINAL_TEMPERATURE (25.0)
#define THERMISTOR_NOMINAL_RESISTANCE (10000.0)
#define THERMISTOR_SERIES_RESISTANCE (10000.0)
void thermistor_driver_enable();
void thermistor_driver_disable();