diff options
author | Bernhard Tittelbach <xro@realraum.at> | 2013-12-11 20:05:40 +0000 |
---|---|---|
committer | Bernhard Tittelbach <xro@realraum.at> | 2013-12-11 20:05:40 +0000 |
commit | d1317d01ba705596b86aebbdbdc72dfb21365b02 (patch) | |
tree | 48bbc3c5864af81003731b30a06d21caca48afcf /pcr-controller/temp_curve.c | |
parent | update (diff) |
json stateless info update, topheater pwm, etc
git-svn-id: https://svn.spreadspace.org/avr/trunk@249 aa12f405-d877-488e-9caf-2d797e2a1cc7
Diffstat (limited to 'pcr-controller/temp_curve.c')
-rw-r--r-- | pcr-controller/temp_curve.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/pcr-controller/temp_curve.c b/pcr-controller/temp_curve.c index f44981f..bf9b309 100644 --- a/pcr-controller/temp_curve.c +++ b/pcr-controller/temp_curve.c @@ -24,7 +24,7 @@ extern uint8_t debug_; -const int16_t temp_margin_ = 8; // 0.5 °C +const int16_t temp_margin_ = 16; // 1 °C typedef struct tc_entry tc_entry; struct tc_entry { @@ -122,14 +122,14 @@ void tcurve_setRepeatEndPosToLatestEntry(void) temp_curve_loop_last_ = temp_curve_end_; } -void tcurve_printCurve(void) +void tcurve_printCurve(uint8_t cmd) { if (temp_curve_ == 0) { - printf("{\"cmd_ok\":false,\"error\":\"No curve set\"}\r\n"); + printf("{\"cmd\":\"%c\",\"cmd_ok\":false,\"error\":\"No curve set\"}\r\n",cmd); return; } - printf("{\"curve\":["); + printf("{\"cmd\":\"%c\",\"curve\":[",cmd); for (tc_entry *ce = temp_curve_; ; ce=ce->next) { printf("{\"temp\":%d,\"duration\":%u,\"is_curr\":%d,\"is_loop_start\":%d,\"is_loop_end\":%d},", @@ -174,4 +174,4 @@ int16_t tcurve_getTempToSet(int16_t current_temp, uint16_t ticks_elapsed) //else stay on temperature of last element forever (until reset is called or new elements are added) } return temp_curve_current_->target_temp; -}
\ No newline at end of file +} |