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
Diff: settings/settings.c
- Revision:
- 101:77fd93f0bde1
- Parent:
- 74:8228f0297227
- Child:
- 103:15583327fcdd
--- a/settings/settings.c Fri Nov 27 18:34:54 2020 +0000 +++ b/settings/settings.c Tue Dec 29 20:19:43 2020 +0000 @@ -15,8 +15,7 @@ #include "ntp.h" #include "dhcp.h" #include "ns.h" -#include "nr4.h" -#include "nr6.h" +#include "nr.h" #include "ntpclient.h" #include "1-wire.h" #include "echo4.h" @@ -69,7 +68,7 @@ static int iNsRecvAdv; static int iNsSendSol; static int iNr4; -static int iNr6; +static int iNr; static int iNtpClient; static int iEcho4; static int iEcho6; @@ -130,7 +129,7 @@ void ChgTraceNsRecvAdv () { NsTraceRecvAdv = !NsTraceRecvAdv; FramWrite(iNsRecvAdv, 1, &NsTraceRecvAdv); } void ChgTraceNsSendSol () { NsTraceSendSol = !NsTraceSendSol; FramWrite(iNsSendSol, 1, &NsTraceSendSol); } void ChgTraceNr4 () { Nr4Trace = !Nr4Trace ; FramWrite(iNr4, 1, &Nr4Trace ); } -void ChgTraceNr6 () { Nr6Trace = !Nr6Trace ; FramWrite(iNr6, 1, &Nr6Trace ); } +void ChgTraceNr6 () { NrTrace = !NrTrace ; FramWrite(iNr, 1, &NrTrace ); } void ChgTraceNtpClient () { NtpClientTrace = !NtpClientTrace ; FramWrite(iNtpClient, 1, &NtpClientTrace ); } void ChgTraceEcho4 () { Echo4Trace = !Echo4Trace ; FramWrite(iEcho4, 1, &Echo4Trace ); } void ChgTraceEcho6 () { Echo6Trace = !Echo6Trace ; FramWrite(iEcho6, 1, &Echo6Trace ); } @@ -214,7 +213,7 @@ address = FramLoad( 1, &b, NULL); NsTraceRecvAdv = b; if (address < 0) return -1; iNsRecvAdv = address; address = FramLoad( 1, &b, NULL); NsTraceSendSol = b; if (address < 0) return -1; iNsSendSol = address; address = FramLoad( 1, &b, NULL); Nr4Trace = b; if (address < 0) return -1; iNr4 = address; - address = FramLoad( 1, &b, NULL); Nr6Trace = b; if (address < 0) return -1; iNr6 = address; + address = FramLoad( 1, &b, NULL); NrTrace = b; if (address < 0) return -1; iNr = address; address = FramLoad( 1, &b, NULL); NtpClientTrace = b; if (address < 0) return -1; iNtpClient = address; address = FramLoad( 1, &b, NULL); Echo4Trace = b; if (address < 0) return -1; iEcho4 = address; address = FramLoad( 1, &b, NULL); Echo6Trace = b; if (address < 0) return -1; iEcho6 = address;