Add settable seed TEC setpoint and °C readout
Expose the Koheron CTL200 thermistor setpoint (rtset) as a settable HA number in ohms, clamped to SEED_RT_SETPOINT_MIN/MAX_OHM. The former read-only setpoint sensor is replaced by this control. Add a read-only seed temperature in °C, computed in firmware from the actual thermistor resistance via an NTC β-model (constants in config.h; update once the DFB1550LP thermistor R25/β are confirmed). Verified end-to-end over MQTT: set/clamp/restore of rtset and the °C conversion (10 kΩ → 25.00 °C). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
61f4526d09
commit
b31065acd7
@@ -31,6 +31,21 @@
|
||||
// guardrail against accidental over-drive, not a safety interlock.
|
||||
#define PUMP_CURRENT_MAX_MA 4000
|
||||
|
||||
// Seed thermistor setpoint (CTL200 `rtset`) clamp, in ohms. The CTL200 has no
|
||||
// native °C setpoint; it regulates the seed TEC to hold the thermistor at this
|
||||
// resistance. The default operating point is 10 kΩ. The range below spans
|
||||
// roughly 39…13 °C on the β-model (a guardrail, not a diode-safe interlock —
|
||||
// narrow it if the DFB1550LP datasheet gives a tighter window).
|
||||
#define SEED_RT_SETPOINT_MIN_OHM 6000
|
||||
#define SEED_RT_SETPOINT_MAX_OHM 16000
|
||||
|
||||
// NTC β-model for the read-only resistance→°C conversion (display only; the
|
||||
// CTL200 does its own regulation in ohms). Assumes a 10 kΩ @ 25 °C NTC with
|
||||
// β = 3435 K. Update if the seed thermistor's R25/β are known to differ.
|
||||
#define SEED_THERMISTOR_R25_OHM 10000.0f
|
||||
#define SEED_THERMISTOR_BETA_K 3435.0f
|
||||
#define SEED_THERMISTOR_T25_K 298.15f
|
||||
|
||||
// ── Serial links to the instruments (wired in later increments) ─────
|
||||
// UART0 stays the USB console. The classic ESP32 has 3 hardware UARTs.
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user