Central Heating controller using the real time clock, PHY module for internet, 1-wire interface for temperature sensors, a system log and a configuration file

Dependencies:   net 1-wire lpc1768 crypto clock web fram log

/media/uploads/andrewboyson/heating.sch

/media/uploads/andrewboyson/heating.brd

/media/uploads/andrewboyson/eagle.epf

Committer:
andrewboyson
Date:
Wed Jun 10 10:08:06 2020 +0000
Revision:
91:8b192efd0288
Parent:
53:c1bf7d9db507
Child:
104:46ce1aaf8be7
Changed the run on residual to a fixed 4 bit fraction temperature to allow better than one degree precision.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
andrewboyson 24:e3ed1b52c6e6 1 #include <stdlib.h>
andrewboyson 24:e3ed1b52c6e6 2 #include <string.h>
andrewboyson 24:e3ed1b52c6e6 3 #include "http.h"
andrewboyson 24:e3ed1b52c6e6 4 #include "boiler.h"
andrewboyson 24:e3ed1b52c6e6 5
andrewboyson 49:9491c966dc60 6 void WebBoilerQuery(char* pQuery)
andrewboyson 24:e3ed1b52c6e6 7 {
andrewboyson 24:e3ed1b52c6e6 8 while (pQuery)
andrewboyson 24:e3ed1b52c6e6 9 {
andrewboyson 24:e3ed1b52c6e6 10 char* pName;
andrewboyson 24:e3ed1b52c6e6 11 char* pValue;
andrewboyson 26:85e3becbebc9 12 pQuery = HttpQuerySplit(pQuery, &pName, &pValue);
andrewboyson 24:e3ed1b52c6e6 13
andrewboyson 91:8b192efd0288 14 if (HttpSameStr(pName, "tanksetpoint" ))
andrewboyson 91:8b192efd0288 15 {
andrewboyson 91:8b192efd0288 16 int value = HttpQueryValueAsInt(pValue);
andrewboyson 91:8b192efd0288 17 BoilerSetTankSetPoint(value);
andrewboyson 91:8b192efd0288 18 return;
andrewboyson 91:8b192efd0288 19 }
andrewboyson 91:8b192efd0288 20 if (HttpSameStr(pName, "tankhysteresis"))
andrewboyson 91:8b192efd0288 21 {
andrewboyson 91:8b192efd0288 22 int value = HttpQueryValueAsInt(pValue);
andrewboyson 91:8b192efd0288 23 BoilerSetTankHysteresis(value);
andrewboyson 91:8b192efd0288 24 return;
andrewboyson 91:8b192efd0288 25 }
andrewboyson 91:8b192efd0288 26 if (HttpSameStr(pName, "boilerresidual"))
andrewboyson 91:8b192efd0288 27 {
andrewboyson 91:8b192efd0288 28 double value = HttpQueryValueAsDouble(pValue);
andrewboyson 91:8b192efd0288 29 BoilerSetRunOnResidual16ths((int)(value * 16));
andrewboyson 91:8b192efd0288 30 return;
andrewboyson 91:8b192efd0288 31 }
andrewboyson 91:8b192efd0288 32 if (HttpSameStr(pName, "boilerrunon" ))
andrewboyson 91:8b192efd0288 33 {
andrewboyson 91:8b192efd0288 34 int value = HttpQueryValueAsInt(pValue);
andrewboyson 91:8b192efd0288 35 BoilerSetRunOnTime(value);
andrewboyson 91:8b192efd0288 36 return;
andrewboyson 91:8b192efd0288 37 }
andrewboyson 24:e3ed1b52c6e6 38 }
andrewboyson 24:e3ed1b52c6e6 39 }