V0.2.2.0 for distribution

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@5620 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
gbamber
2017-01-10 07:53:26 +00:00
parent 33d48a18d2
commit 3106f1eb0c
11 changed files with 264 additions and 171 deletions

View File

@ -226,9 +226,9 @@ begin
FooBotTriggerArray[C_HIGH, C_HUM] := ReadFloat(sFoobotName, 'humTriggerHigh', 0); FooBotTriggerArray[C_HIGH, C_HUM] := ReadFloat(sFoobotName, 'humTriggerHigh', 0);
FooBotTriggerArray[C_LOW, C_HUM] := ReadFloat(sFoobotName, 'humTriggerLow', 0); FooBotTriggerArray[C_LOW, C_HUM] := ReadFloat(sFoobotName, 'humTriggerLow', 0);
FooBotTriggerArray[C_HIGH, C_CO2] := ReadFloat(sFoobotName, 'co2TriggerHigh', 0); FooBotTriggerArray[C_HIGH, C_CO2] := ReadFloat(sFoobotName, 'co2TriggerHigh', 0);
FooBotTriggerArray[C_LOW, C_CO2] := ReadFloat(sFoobotName, 'co2TriggerLow', 0); FooBotTriggerArray[C_LOW, C_CO2] := ReadFloat(sFoobotName, 'co2TriggerLow', 450);
FooBotTriggerArray[C_HIGH, C_VOC] := ReadFloat(sFoobotName, 'vocTriggerHigh', 0); FooBotTriggerArray[C_HIGH, C_VOC] := ReadFloat(sFoobotName, 'vocTriggerHigh', 0);
FooBotTriggerArray[C_LOW, C_VOC] := ReadFloat(sFoobotName, 'vocTriggerLow', 0); FooBotTriggerArray[C_LOW, C_VOC] := ReadFloat(sFoobotName, 'vocTriggerLow', 125);
FooBotTriggerArray[C_HIGH, C_ALLPOLLU] := FooBotTriggerArray[C_HIGH, C_ALLPOLLU] :=
ReadFloat(sFoobotName, 'allpolluTriggerHigh', 0); ReadFloat(sFoobotName, 'allpolluTriggerHigh', 0);
FooBotTriggerArray[C_LOW, C_ALLPOLLU] := FooBotTriggerArray[C_LOW, C_ALLPOLLU] :=

View File

@ -24,7 +24,7 @@
<UseVersionInfo Value="True"/> <UseVersionInfo Value="True"/>
<MinorVersionNr Value="2"/> <MinorVersionNr Value="2"/>
<RevisionNr Value="2"/> <RevisionNr Value="2"/>
<StringTable Comments="Uses Foobot public API to query Foobot #1" FileDescription="Monitor for Foobot" InternalName="foobotmonitor" LegalCopyright="(c)2016 minesadorada@charcodelvalle.com" LegalTrademarks="Foobot" ProductName="Foobot" ProductVersion="0.0.0.0"/> <StringTable Comments="Uses Foobot public API to query Foobots" FileDescription="Monitor for Foobot" InternalName="foobotmonitor" LegalCopyright="(c)2016 minesadorada@charcodelvalle.com" LegalTrademarks="Foobot" ProductName="Foobot" ProductVersion="0.0.0.0"/>
</VersionInfo> </VersionInfo>
<BuildModes Count="6"> <BuildModes Count="6">
<Item1 Name="Debug" Default="True"/> <Item1 Name="Debug" Default="True"/>

View File

@ -3,14 +3,14 @@
<ProjectSession> <ProjectSession>
<PathDelim Value="\"/> <PathDelim Value="\"/>
<Version Value="10"/> <Version Value="10"/>
<BuildModes Active="win64"/> <BuildModes Active="win32GTK2"/>
<Units Count="34"> <Units Count="34">
<Unit0> <Unit0>
<Filename Value="foobotmonitor.lpr"/> <Filename Value="foobotmonitor.lpr"/>
<IsPartOfProject Value="True"/> <IsPartOfProject Value="True"/>
<EditorIndex Value="12"/> <EditorIndex Value="12"/>
<CursorPos Y="35"/> <CursorPos Y="35"/>
<UsageCount Value="151"/> <UsageCount Value="153"/>
<Loaded Value="True"/> <Loaded Value="True"/>
</Unit0> </Unit0>
<Unit1> <Unit1>
@ -19,10 +19,9 @@
<ComponentName Value="mainform"/> <ComponentName Value="mainform"/>
<HasResources Value="True"/> <HasResources Value="True"/>
<ResourceBaseClass Value="Form"/> <ResourceBaseClass Value="Form"/>
<IsVisibleTab Value="True"/> <TopLine Value="199"/>
<TopLine Value="770"/> <CursorPos X="47" Y="22"/>
<CursorPos X="6" Y="780"/> <UsageCount Value="153"/>
<UsageCount Value="151"/>
<Loaded Value="True"/> <Loaded Value="True"/>
<LoadedDesigner Value="True"/> <LoadedDesigner Value="True"/>
</Unit1> </Unit1>
@ -35,7 +34,7 @@
<EditorIndex Value="7"/> <EditorIndex Value="7"/>
<TopLine Value="33"/> <TopLine Value="33"/>
<CursorPos X="41" Y="45"/> <CursorPos X="41" Y="45"/>
<UsageCount Value="141"/> <UsageCount Value="143"/>
<Loaded Value="True"/> <Loaded Value="True"/>
<LoadedDesigner Value="True"/> <LoadedDesigner Value="True"/>
</Unit2> </Unit2>
@ -45,7 +44,7 @@
<EditorIndex Value="1"/> <EditorIndex Value="1"/>
<TopLine Value="13"/> <TopLine Value="13"/>
<CursorPos X="49" Y="20"/> <CursorPos X="49" Y="20"/>
<UsageCount Value="133"/> <UsageCount Value="135"/>
<Loaded Value="True"/> <Loaded Value="True"/>
</Unit3> </Unit3>
<Unit4> <Unit4>
@ -55,15 +54,16 @@
<WindowIndex Value="-1"/> <WindowIndex Value="-1"/>
<TopLine Value="-1"/> <TopLine Value="-1"/>
<CursorPos X="-1" Y="-1"/> <CursorPos X="-1" Y="-1"/>
<UsageCount Value="133"/> <UsageCount Value="135"/>
</Unit4> </Unit4>
<Unit5> <Unit5>
<Filename Value="..\foobot_utility.pas"/> <Filename Value="..\foobot_utility.pas"/>
<IsPartOfProject Value="True"/> <IsPartOfProject Value="True"/>
<IsVisibleTab Value="True"/>
<EditorIndex Value="9"/> <EditorIndex Value="9"/>
<TopLine Value="241"/> <TopLine Value="199"/>
<CursorPos X="68" Y="261"/> <CursorPos X="56" Y="232"/>
<UsageCount Value="151"/> <UsageCount Value="153"/>
<Loaded Value="True"/> <Loaded Value="True"/>
</Unit5> </Unit5>
<Unit6> <Unit6>
@ -73,7 +73,7 @@
<WindowIndex Value="-1"/> <WindowIndex Value="-1"/>
<TopLine Value="-1"/> <TopLine Value="-1"/>
<CursorPos X="-1" Y="-1"/> <CursorPos X="-1" Y="-1"/>
<UsageCount Value="133"/> <UsageCount Value="135"/>
</Unit6> </Unit6>
<Unit7> <Unit7>
<Filename Value="foobot_sensors.pas"/> <Filename Value="foobot_sensors.pas"/>
@ -81,7 +81,7 @@
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="299"/> <TopLine Value="299"/>
<CursorPos X="14" Y="321"/> <CursorPos X="14" Y="321"/>
<UsageCount Value="85"/> <UsageCount Value="87"/>
</Unit7> </Unit7>
<Unit8> <Unit8>
<Filename Value="usplash.pas"/> <Filename Value="usplash.pas"/>
@ -91,7 +91,7 @@
<ResourceBaseClass Value="Form"/> <ResourceBaseClass Value="Form"/>
<EditorIndex Value="3"/> <EditorIndex Value="3"/>
<CursorPos X="48" Y="37"/> <CursorPos X="48" Y="37"/>
<UsageCount Value="80"/> <UsageCount Value="82"/>
<Loaded Value="True"/> <Loaded Value="True"/>
<LoadedDesigner Value="True"/> <LoadedDesigner Value="True"/>
</Unit8> </Unit8>
@ -102,9 +102,9 @@
<HasResources Value="True"/> <HasResources Value="True"/>
<ResourceBaseClass Value="Form"/> <ResourceBaseClass Value="Form"/>
<EditorIndex Value="2"/> <EditorIndex Value="2"/>
<TopLine Value="232"/> <TopLine Value="382"/>
<CursorPos X="81" Y="254"/> <CursorPos X="26" Y="21"/>
<UsageCount Value="71"/> <UsageCount Value="73"/>
<Loaded Value="True"/> <Loaded Value="True"/>
<LoadedDesigner Value="True"/> <LoadedDesigner Value="True"/>
</Unit9> </Unit9>
@ -113,7 +113,7 @@
<EditorIndex Value="8"/> <EditorIndex Value="8"/>
<TopLine Value="43"/> <TopLine Value="43"/>
<CursorPos X="47" Y="13"/> <CursorPos X="47" Y="13"/>
<UsageCount Value="90"/> <UsageCount Value="91"/>
<Loaded Value="True"/> <Loaded Value="True"/>
</Unit10> </Unit10>
<Unit11> <Unit11>
@ -121,7 +121,7 @@
<EditorIndex Value="11"/> <EditorIndex Value="11"/>
<TopLine Value="141"/> <TopLine Value="141"/>
<CursorPos X="31" Y="148"/> <CursorPos X="31" Y="148"/>
<UsageCount Value="90"/> <UsageCount Value="91"/>
<Loaded Value="True"/> <Loaded Value="True"/>
</Unit11> </Unit11>
<Unit12> <Unit12>
@ -130,12 +130,12 @@
<WindowIndex Value="-1"/> <WindowIndex Value="-1"/>
<TopLine Value="-1"/> <TopLine Value="-1"/>
<CursorPos X="-1" Y="-1"/> <CursorPos X="-1" Y="-1"/>
<UsageCount Value="31"/> <UsageCount Value="30"/>
</Unit12> </Unit12>
<Unit13> <Unit13>
<Filename Value="..\latest_stable\umainform.lfm"/> <Filename Value="..\latest_stable\umainform.lfm"/>
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<UsageCount Value="3"/> <UsageCount Value="2"/>
<DefaultSyntaxHighlighter Value="LFM"/> <DefaultSyntaxHighlighter Value="LFM"/>
</Unit13> </Unit13>
<Unit14> <Unit14>
@ -143,21 +143,21 @@
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="10"/> <TopLine Value="10"/>
<CursorPos X="57" Y="36"/> <CursorPos X="57" Y="36"/>
<UsageCount Value="3"/> <UsageCount Value="2"/>
</Unit14> </Unit14>
<Unit15> <Unit15>
<Filename Value="..\udataform.pas"/> <Filename Value="..\udataform.pas"/>
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="74"/> <TopLine Value="74"/>
<CursorPos Y="96"/> <CursorPos Y="96"/>
<UsageCount Value="11"/> <UsageCount Value="10"/>
</Unit15> </Unit15>
<Unit16> <Unit16>
<Filename Value="..\umainform.pas"/> <Filename Value="..\umainform.pas"/>
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="145"/> <TopLine Value="145"/>
<CursorPos X="81" Y="158"/> <CursorPos X="81" Y="158"/>
<UsageCount Value="39"/> <UsageCount Value="38"/>
</Unit16> </Unit16>
<Unit17> <Unit17>
<Filename Value="C:\trunklatest\lazarus\lcl\lclmessageglue.pas"/> <Filename Value="C:\trunklatest\lazarus\lcl\lclmessageglue.pas"/>
@ -165,26 +165,26 @@
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="93"/> <TopLine Value="93"/>
<CursorPos Y="114"/> <CursorPos Y="114"/>
<UsageCount Value="3"/> <UsageCount Value="2"/>
</Unit17> </Unit17>
<Unit18> <Unit18>
<Filename Value="..\ulogin.pas"/> <Filename Value="..\ulogin.pas"/>
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<CursorPos Y="108"/> <CursorPos Y="108"/>
<UsageCount Value="6"/> <UsageCount Value="5"/>
</Unit18> </Unit18>
<Unit19> <Unit19>
<Filename Value="..\..\..\components\cryptini\latest_stable\ucryptini.pas"/> <Filename Value="..\..\..\components\cryptini\latest_stable\ucryptini.pas"/>
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="906"/> <TopLine Value="906"/>
<CursorPos X="8" Y="939"/> <CursorPos X="8" Y="939"/>
<UsageCount Value="4"/> <UsageCount Value="3"/>
</Unit19> </Unit19>
<Unit20> <Unit20>
<Filename Value="..\backup\foobot_utility.pas"/> <Filename Value="..\backup\foobot_utility.pas"/>
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="7"/> <TopLine Value="7"/>
<UsageCount Value="3"/> <UsageCount Value="2"/>
</Unit20> </Unit20>
<Unit21> <Unit21>
<Filename Value="C:\trunklatest\lazarus\ide\lazarus.pp"/> <Filename Value="C:\trunklatest\lazarus\ide\lazarus.pp"/>
@ -192,7 +192,7 @@
<EditorIndex Value="5"/> <EditorIndex Value="5"/>
<TopLine Value="101"/> <TopLine Value="101"/>
<CursorPos Y="154"/> <CursorPos Y="154"/>
<UsageCount Value="41"/> <UsageCount Value="42"/>
<Loaded Value="True"/> <Loaded Value="True"/>
</Unit21> </Unit21>
<Unit22> <Unit22>
@ -200,35 +200,35 @@
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="11"/> <TopLine Value="11"/>
<CursorPos X="8" Y="33"/> <CursorPos X="8" Y="33"/>
<UsageCount Value="4"/> <UsageCount Value="3"/>
</Unit22> </Unit22>
<Unit23> <Unit23>
<Filename Value="D:\Lazarusprojects\healthmonitor\svn\healthanalysis\healthanalysis\umainform.pas"/> <Filename Value="D:\Lazarusprojects\healthmonitor\svn\healthanalysis\healthanalysis\umainform.pas"/>
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="540"/> <TopLine Value="540"/>
<CursorPos X="55" Y="593"/> <CursorPos X="55" Y="593"/>
<UsageCount Value="4"/> <UsageCount Value="3"/>
</Unit23> </Unit23>
<Unit24> <Unit24>
<Filename Value="C:\trunklatest\fpc\rtl\objpas\sysutils\datih.inc"/> <Filename Value="C:\trunklatest\fpc\rtl\objpas\sysutils\datih.inc"/>
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="109"/> <TopLine Value="109"/>
<CursorPos X="10" Y="128"/> <CursorPos X="10" Y="128"/>
<UsageCount Value="3"/> <UsageCount Value="2"/>
</Unit24> </Unit24>
<Unit25> <Unit25>
<Filename Value="C:\trunklatest\fpc\packages\rtl-objpas\src\inc\dateutil.inc"/> <Filename Value="C:\trunklatest\fpc\packages\rtl-objpas\src\inc\dateutil.inc"/>
<EditorIndex Value="10"/> <EditorIndex Value="10"/>
<TopLine Value="381"/> <TopLine Value="381"/>
<CursorPos X="13" Y="384"/> <CursorPos X="13" Y="384"/>
<UsageCount Value="59"/> <UsageCount Value="60"/>
<Loaded Value="True"/> <Loaded Value="True"/>
</Unit25> </Unit25>
<Unit26> <Unit26>
<Filename Value="..\latest_stable\udataform.pas"/> <Filename Value="..\latest_stable\udataform.pas"/>
<EditorIndex Value="6"/> <EditorIndex Value="6"/>
<TopLine Value="70"/> <TopLine Value="70"/>
<UsageCount Value="59"/> <UsageCount Value="60"/>
<Loaded Value="True"/> <Loaded Value="True"/>
</Unit26> </Unit26>
<Unit27> <Unit27>
@ -236,20 +236,20 @@
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="781"/> <TopLine Value="781"/>
<CursorPos X="28" Y="795"/> <CursorPos X="28" Y="795"/>
<UsageCount Value="18"/> <UsageCount Value="17"/>
</Unit27> </Unit27>
<Unit28> <Unit28>
<Filename Value="C:\trunklatest\fpc\packages\fcl-base\src\fileinfo.pp"/> <Filename Value="C:\trunklatest\fpc\packages\fcl-base\src\fileinfo.pp"/>
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="43"/> <TopLine Value="43"/>
<CursorPos X="19" Y="51"/> <CursorPos X="19" Y="51"/>
<UsageCount Value="7"/> <UsageCount Value="6"/>
</Unit28> </Unit28>
<Unit29> <Unit29>
<Filename Value="C:\trunklatest\lazarus\components\IndustrialStuff\industrial.pas"/> <Filename Value="C:\trunklatest\lazarus\components\IndustrialStuff\industrial.pas"/>
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<CursorPos X="18" Y="11"/> <CursorPos X="18" Y="11"/>
<UsageCount Value="5"/> <UsageCount Value="4"/>
</Unit29> </Unit29>
<Unit30> <Unit30>
<Filename Value="..\..\..\components\poweredby\latest_stable\upoweredby.pas"/> <Filename Value="..\..\..\components\poweredby\latest_stable\upoweredby.pas"/>
@ -257,14 +257,14 @@
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="190"/> <TopLine Value="190"/>
<CursorPos X="33" Y="205"/> <CursorPos X="33" Y="205"/>
<UsageCount Value="15"/> <UsageCount Value="14"/>
</Unit30> </Unit30>
<Unit31> <Unit31>
<Filename Value="C:\trunklatest\lazarus\lcl\include\customform.inc"/> <Filename Value="C:\trunklatest\lazarus\lcl\include\customform.inc"/>
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="2228"/> <TopLine Value="2228"/>
<CursorPos X="14" Y="2239"/> <CursorPos X="14" Y="2239"/>
<UsageCount Value="5"/> <UsageCount Value="4"/>
</Unit31> </Unit31>
<Unit32> <Unit32>
<Filename Value="C:\trunklatest\lazarus\lcl\graphics.pp"/> <Filename Value="C:\trunklatest\lazarus\lcl\graphics.pp"/>
@ -272,7 +272,7 @@
<EditorIndex Value="4"/> <EditorIndex Value="4"/>
<TopLine Value="1811"/> <TopLine Value="1811"/>
<CursorPos X="13" Y="1834"/> <CursorPos X="13" Y="1834"/>
<UsageCount Value="37"/> <UsageCount Value="38"/>
<Loaded Value="True"/> <Loaded Value="True"/>
</Unit32> </Unit32>
<Unit33> <Unit33>
@ -280,130 +280,130 @@
<EditorIndex Value="-1"/> <EditorIndex Value="-1"/>
<TopLine Value="119"/> <TopLine Value="119"/>
<CursorPos Y="151"/> <CursorPos Y="151"/>
<UsageCount Value="7"/> <UsageCount Value="6"/>
<DefaultSyntaxHighlighter Value="LFM"/> <DefaultSyntaxHighlighter Value="LFM"/>
</Unit33> </Unit33>
</Units> </Units>
<JumpHistory Count="30" HistoryIndex="29"> <JumpHistory Count="30" HistoryIndex="29">
<Position1> <Position1>
<Filename Value="utriggersform.pas"/> <Filename Value="utriggersform.pas"/>
<Caret Line="123" Column="8" TopLine="105"/> <Caret Line="153" Column="43" TopLine="134"/>
</Position1> </Position1>
<Position2> <Position2>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="279" Column="11" TopLine="261"/> <Caret Line="78" Column="9" TopLine="45"/>
</Position2> </Position2>
<Position3> <Position3>
<Filename Value="utriggersform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="153" Column="43" TopLine="134"/> <Caret Line="417" Column="39" TopLine="370"/>
</Position3> </Position3>
<Position4> <Position4>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="78" Column="9" TopLine="45"/> <Caret Line="419" Column="39" TopLine="372"/>
</Position4> </Position4>
<Position5> <Position5>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="417" Column="39" TopLine="370"/> <Caret Line="884" Column="32" TopLine="837"/>
</Position5> </Position5>
<Position6> <Position6>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="419" Column="39" TopLine="372"/> <Caret Line="1062" Column="28" TopLine="1015"/>
</Position6> </Position6>
<Position7> <Position7>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="884" Column="32" TopLine="837"/> <Caret Line="77" TopLine="51"/>
</Position7> </Position7>
<Position8> <Position8>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="1062" Column="28" TopLine="1015"/> <Caret Line="3" Column="7"/>
</Position8> </Position8>
<Position9> <Position9>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="77" TopLine="51"/> <Caret Line="30" Column="20" TopLine="28"/>
</Position9> </Position9>
<Position10> <Position10>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="3" Column="7"/> <Caret Line="883" Column="65" TopLine="852"/>
</Position10> </Position10>
<Position11> <Position11>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="30" Column="20" TopLine="28"/> <Caret Line="1080" Column="61" TopLine="1036"/>
</Position11> </Position11>
<Position12> <Position12>
<Filename Value="umainform.pas"/> <Filename Value="..\foobot_utility.pas"/>
<Caret Line="883" Column="65" TopLine="852"/> <Caret Line="277" TopLine="241"/>
</Position12> </Position12>
<Position13> <Position13>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="1080" Column="61" TopLine="1036"/> <Caret Line="476" Column="65" TopLine="457"/>
</Position13> </Position13>
<Position14> <Position14>
<Filename Value="..\foobot_utility.pas"/>
<Caret Line="277" TopLine="241"/>
</Position14>
<Position15>
<Filename Value="umainform.pas"/>
<Caret Line="476" Column="65" TopLine="457"/>
</Position15>
<Position16>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="448" Column="8" TopLine="445"/> <Caret Line="448" Column="8" TopLine="445"/>
</Position14>
<Position15>
<Filename Value="utriggersform.pas"/>
<Caret Line="171" Column="16" TopLine="135"/>
</Position15>
<Position16>
<Filename Value="utriggersform.pas"/>
<Caret Line="285" Column="79" TopLine="244"/>
</Position16> </Position16>
<Position17> <Position17>
<Filename Value="utriggersform.pas"/> <Filename Value="utriggersform.pas"/>
<Caret Line="171" Column="16" TopLine="135"/> <Caret Line="287" Column="88" TopLine="245"/>
</Position17> </Position17>
<Position18> <Position18>
<Filename Value="utriggersform.pas"/> <Filename Value="utriggersform.pas"/>
<Caret Line="285" Column="79" TopLine="244"/> <Caret Line="275" Column="17" TopLine="260"/>
</Position18> </Position18>
<Position19> <Position19>
<Filename Value="utriggersform.pas"/> <Filename Value="utriggersform.pas"/>
<Caret Line="287" Column="88" TopLine="245"/> <Caret Line="161" Column="22" TopLine="150"/>
</Position19> </Position19>
<Position20> <Position20>
<Filename Value="utriggersform.pas"/> <Filename Value="utriggersform.pas"/>
<Caret Line="275" Column="17" TopLine="260"/> <Caret Line="162" Column="16" TopLine="130"/>
</Position20> </Position20>
<Position21> <Position21>
<Filename Value="utriggersform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="161" Column="22" TopLine="150"/> <Caret Line="318" Column="46" TopLine="313"/>
</Position21> </Position21>
<Position22> <Position22>
<Filename Value="utriggersform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="162" Column="16" TopLine="130"/> <Caret Line="779" Column="58" TopLine="769"/>
</Position22> </Position22>
<Position23> <Position23>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="318" Column="46" TopLine="313"/> <Caret Line="786" TopLine="769"/>
</Position23> </Position23>
<Position24> <Position24>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="779" Column="58" TopLine="769"/> <Caret Line="1194" Column="27" TopLine="1184"/>
</Position24> </Position24>
<Position25> <Position25>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="786" TopLine="769"/> <Caret Line="400" Column="3" TopLine="392"/>
</Position25> </Position25>
<Position26> <Position26>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="1194" Column="27" TopLine="1184"/> <Caret Line="449" Column="27" TopLine="391"/>
</Position26> </Position26>
<Position27> <Position27>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="400" Column="3" TopLine="392"/> <Caret Line="742" Column="13" TopLine="738"/>
</Position27> </Position27>
<Position28> <Position28>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="449" Column="27" TopLine="391"/> <Caret Line="400" Column="3" TopLine="395"/>
</Position28> </Position28>
<Position29> <Position29>
<Filename Value="umainform.pas"/> <Filename Value="umainform.pas"/>
<Caret Line="742" Column="13" TopLine="738"/> <Caret Line="777" Column="42" TopLine="770"/>
</Position29> </Position29>
<Position30> <Position30>
<Filename Value="umainform.pas"/> <Filename Value="utriggersform.pas"/>
<Caret Line="400" Column="3" TopLine="395"/> <Caret Line="188" Column="46" TopLine="144"/>
</Position30> </Position30>
</JumpHistory> </JumpHistory>
</ProjectSession> </ProjectSession>

View File

@ -9,7 +9,7 @@
[Setup] [Setup]
AppName=Foobot Monitor AppName=Foobot Monitor
AppVersion=0.2.0.0 AppVersion=0.2.2.0
DefaultDirName={pf}\foobotmonitor DefaultDirName={pf}\foobotmonitor
DefaultGroupName=Foobot DefaultGroupName=Foobot
UninstallDisplayIcon={app}\foobotmonitor.exe UninstallDisplayIcon={app}\foobotmonitor.exe

View File

@ -851,9 +851,9 @@ object mainform: Tmainform
end end
object mnu_help: TMenuItem object mnu_help: TMenuItem
Caption = '&Help' Caption = '&Help'
object mnu_optionsOnlineHelp: TMenuItem object mnu_optionsHomePage: TMenuItem
Caption = 'Online Help' Caption = 'Home Page'
OnClick = mnu_optionsOnlineHelpClick OnClick = mnu_optionsHomePageClick
end end
object mnu_helpFoobotAPIPage: TMenuItem object mnu_helpFoobotAPIPage: TMenuItem
Caption = 'Foobot API page' Caption = 'Foobot API page'

View File

@ -28,6 +28,8 @@ V0.0.4.0: Graph added
V0.1.0.0: Save/Load Alltime High/Lows. Reset values from menu V0.1.0.0: Save/Load Alltime High/Lows. Reset values from menu
V0.1.1.0: Save/Load Colours, Min and Max values to cfg file V0.1.1.0: Save/Load Colours, Min and Max values to cfg file
V0.2.1.0: Triggers,Multiple Foobots V0.2.1.0: Triggers,Multiple Foobots
V0.2.2.0: Trigger config form, SaveLoad recommended values
V0.2.3.0: ??
} }
{$ifopt D+} {$ifopt D+}
// Debug mode does not load data from web // Debug mode does not load data from web
@ -145,7 +147,7 @@ type
mnu_optionsDisplayGuagesOnly: TMenuItem; mnu_optionsDisplayGuagesOnly: TMenuItem;
mnu_SampleEveryHalfHour: TMenuItem; mnu_SampleEveryHalfHour: TMenuItem;
mnu_optionsResetHighsLows: TMenuItem; mnu_optionsResetHighsLows: TMenuItem;
mnu_optionsOnlineHelp: TMenuItem; mnu_optionsHomePage: TMenuItem;
mnu_optionsSeperator1: TMenuItem; mnu_optionsSeperator1: TMenuItem;
mnu_helpAbout: TMenuItem; mnu_helpAbout: TMenuItem;
mnu_help: TMenuItem; mnu_help: TMenuItem;
@ -192,7 +194,7 @@ type
procedure mnu_optionsDisplayRedLinesClick(Sender: TObject); procedure mnu_optionsDisplayRedLinesClick(Sender: TObject);
procedure mnu_optionsDisplayYellowLinesClick(Sender: TObject); procedure mnu_optionsDisplayYellowLinesClick(Sender: TObject);
procedure mnu_optionsMinimiseToTrayClick(Sender: TObject); procedure mnu_optionsMinimiseToTrayClick(Sender: TObject);
procedure mnu_optionsOnlineHelpClick(Sender: TObject); procedure mnu_optionsHomePageClick(Sender: TObject);
procedure mnu_optionsResetHighsLowsClick(Sender: TObject); procedure mnu_optionsResetHighsLowsClick(Sender: TObject);
procedure mnu_optionsSaveHighLowsClick(Sender: TObject); procedure mnu_optionsSaveHighLowsClick(Sender: TObject);
procedure mnu_optionsTakeReadingNowClick(Sender: TObject); procedure mnu_optionsTakeReadingNowClick(Sender: TObject);
@ -711,7 +713,7 @@ begin
mainform.FormWindowStateChange(Self); mainform.FormWindowStateChange(Self);
end; end;
procedure Tmainform.mnu_optionsOnlineHelpClick(Sender: TObject); procedure Tmainform.mnu_optionsHomePageClick(Sender: TObject);
begin begin
OpenURL('http://wiki.freepascal.org/Foobot'); OpenURL('http://wiki.freepascal.org/Foobot');
end; end;

View File

@ -1,7 +1,7 @@
object triggersform: Ttriggersform object triggersform: Ttriggersform
Left = 2283 Left = 2007
Height = 565 Height = 565
Top = 82 Top = 405
Width = 794 Width = 794
ActiveControl = edt_newrec_pm ActiveControl = edt_newrec_pm
BorderIcons = [biSystemMenu] BorderIcons = [biSystemMenu]

View File

@ -1,5 +1,23 @@
unit utriggersform; unit utriggersform;
{ Foobot Monitor
Copyright (C)2016 Gordon Bamber minsadorada@charcodelvalle.com
This source is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free
Software Foundation; either version 2 of the License, or (at your option)
any later version.
This code is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
details.
A copy of the GNU General Public License is available on the World Wide Web
at <http://www.gnu.org/copyleft/gpl.html>. You can also obtain it by writing
to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
MA 02111-1307, USA.
}
{$mode objfpc}{$H+} {$mode objfpc}{$H+}
interface interface
@ -101,12 +119,12 @@ type
procedure OnlyNumericKeyPressFloat(Sender: TObject; var Key: char); procedure OnlyNumericKeyPressFloat(Sender: TObject; var Key: char);
procedure OnlyNumericKeyPressInteger(Sender: TObject; var Key: char); procedure OnlyNumericKeyPressInteger(Sender: TObject; var Key: char);
private private
ErrorList:TStrings; ErrorList: TStrings;
procedure DisplayCurrentValues; procedure DisplayCurrentValues;
procedure SetUpUnits; procedure SetUpUnits;
function AssignAndSaveTriggers:boolean; function AssignAndSaveTriggers: boolean;
function AssignAndSaveRecommendedLevels:boolean; function AssignAndSaveRecommendedLevels: boolean;
function AllInputsVerified:Boolean; function AllInputsVerified: boolean;
public public
end; end;
@ -125,7 +143,7 @@ uses umainform, foobot_utility;
procedure Ttriggersform.FormCreate(Sender: TObject); procedure Ttriggersform.FormCreate(Sender: TObject);
begin begin
Icon := Application.Icon; Icon := Application.Icon;
ErrorList:=TStringList.Create; ErrorList := TStringList.Create;
end; end;
procedure Ttriggersform.FormDestroy(Sender: TObject); procedure Ttriggersform.FormDestroy(Sender: TObject);
@ -137,10 +155,12 @@ procedure Ttriggersform.FormActivate(Sender: TObject);
begin begin
SetUpUnits; SetUpUnits;
end; end;
procedure Ttriggersform.FormShow(Sender: TObject); procedure Ttriggersform.FormShow(Sender: TObject);
begin begin
Caption := Application.Title + ' - Set Recommended values (for all Foobots) and Triggers (for ' + Caption := Application.Title +
FoobotIdentityObject.FoobotIdentityList[mainform.iCurrentFoobot].Name + ')'; ' - Set Recommended values (for all Foobots) and Triggers (for ' +
FoobotIdentityObject.FoobotIdentityList[mainform.iCurrentFoobot].Name + ')';
DisplayCurrentValues; DisplayCurrentValues;
ErrorList.Clear; ErrorList.Clear;
Update; Update;
@ -148,77 +168,142 @@ end;
// ***************************************************************************** // *****************************************************************************
procedure Ttriggersform.cmd_OKClick(Sender: TObject); procedure Ttriggersform.cmd_OKClick(Sender: TObject);
var
s: string;
iCount: integer;
begin begin
// VerifyEveryThing then Save to inifiles; // VerifyEveryThing then Save to inifiles;
IF AssignAndSaveTriggers if AllInputsVerified then
AND AssignAndSaveRecommendedLevels
AND AllInputsVerified then
begin begin
ModalResult:=mrClose; AssignAndSaveTriggers;
AssignAndSaveRecommendedLevels;
ModalResult := mrClose;
Close; Close;
end end
else else
begin begin
ModalResult:=mrNone; ModalResult := mrNone;
ShowMessage('Wont close'); s := '';
if (ErrorList.Count > 0) then
for iCount := 0 to Pred(ErrorList.Count) do
s := s + '* ' + ErrorList[iCount] + LineEnding;
MessageDlg('Problems listed below', s, mtError, [mbOK], 0);
end; end;
end; end;
procedure Ttriggersform.OnlyNumericKeyPressInteger(Sender: TObject; var Key: char); procedure Ttriggersform.OnlyNumericKeyPressInteger(Sender: TObject; var Key: char);
begin begin
if not (Key in ['0'..'9', #8, #9]) then Key := #0; if not (Key in ['0'..'9', #8, #9]) then
Key := #0;
end; end;
procedure Ttriggersform.OnlyNumericKeyPressFloat(Sender: TObject; var Key: char); procedure Ttriggersform.OnlyNumericKeyPressFloat(Sender: TObject; var Key: char);
begin begin
if not (Key in ['0'..'9', '.', #8, #9]) then Key := #0; if not (Key in ['0'..'9', '.', #8, #9]) then
Key := #0;
end; end;
function Ttriggersform.AllInputsVerified:Boolean; function Ttriggersform.AllInputsVerified: boolean;
begin begin
Result:=TRUE; ErrorList.Clear;
// Low triggers bigger than high triggers
If StrToFloat(edt_newlowtrigger_pm.Text) > StrToFloat(edt_newhightrigger_pm.Text) then
ErrorList.Add('Particulates low trigger is greater than the high trigger');
If StrToFloat(edt_newlowtrigger_tmp.Text) > StrToFloat(edt_newhightrigger_tmp.Text) then
ErrorList.Add('Temperature low trigger is greater than the high trigger');
If StrToFloat(edt_newlowtrigger_hum.Text) > StrToFloat(edt_newhightrigger_hum.Text) then
ErrorList.Add('Humidity low trigger is greater than the high trigger');
If StrToFloat(edt_newlowtrigger_co2.Text) > StrToFloat(edt_newhightrigger_co2.Text) then
ErrorList.Add('CO2 low trigger is greater than the high trigger');
If StrToFloat(edt_newlowtrigger_voc.Text) > StrToFloat(edt_newhightrigger_voc.Text) then
ErrorList.Add('Volatile compounds low trigger is greater than the high trigger');
If StrToFloat(edt_newlowtrigger_allpollu.Text) > StrToFloat(edt_newhightrigger_allpollu.Text) then
ErrorList.Add('All Pollution low trigger is greater than the high trigger');
// Recommended levels bigger than high triggers
If StrToFloat(edt_newrec_pm.Text) > StrToFloat(edt_newhightrigger_pm.Text) then
ErrorList.Add('Particulates recommended level is greater than the high trigger');
If StrToFloat(edt_newrec_tmp.Text) > StrToFloat(edt_newhightrigger_tmp.Text) then
ErrorList.Add('Temperature recommended level is greater than the high trigger');
If StrToFloat(edt_newrec_hum.Text) > StrToFloat(edt_newhightrigger_hum.Text) then
ErrorList.Add('Humidity recommended level is greater than the high trigger');
If StrToFloat(edt_newrec_co2.Text) > StrToFloat(edt_newhightrigger_co2.Text) then
ErrorList.Add('CO2 recommended level is greater than the high trigger');
If StrToFloat(edt_newrec_voc.Text) > StrToFloat(edt_newhightrigger_voc.Text) then
ErrorList.Add('Volatile compounds recommended level is greater than the high trigger');
If StrToFloat(edt_newrec_allpollu.Text) > StrToFloat(edt_newhightrigger_allpollu.Text) then
ErrorList.Add('All Pollution recommended level is greater than the high trigger');
// Recommended levels lower than low trigger
If StrToFloat(edt_newrec_pm.Text) < StrToFloat(edt_newlowtrigger_pm.Text) then
ErrorList.Add('Particulates recommended level is less than the low trigger');
If StrToFloat(edt_newrec_tmp.Text) < StrToFloat(edt_newlowtrigger_tmp.Text) then
ErrorList.Add('Temperature recommended level is less than the low trigger');
If StrToFloat(edt_newrec_hum.Text) < StrToFloat(edt_newlowtrigger_hum.Text) then
ErrorList.Add('Humidity recommended level is less than the low trigger');
If StrToFloat(edt_newrec_co2.Text) < StrToFloat(edt_newlowtrigger_co2.Text) then
ErrorList.Add('CO2 recommended level is less than the low trigger');
If StrToFloat(edt_newrec_voc.Text) < StrToFloat(edt_newlowtrigger_voc.Text) then
ErrorList.Add('Volatile compounds recommended level is less than the low trigger');
If StrToFloat(edt_newrec_allpollu.Text) < StrToFloat(edt_newlowtrigger_allpollu.Text) then
ErrorList.Add('All Pollution recommended level is less than the low trigger');
// CO2 and Voc lowtrigger or rec level lower than sensor minimum
If StrToFloat(edt_newlowtrigger_co2.Text) < 450 then
ErrorList.Add('CO2 low trigger cannot be below 450');
If StrToFloat(edt_newlowtrigger_voc.Text) < 125 then
ErrorList.Add('Volatile compounds low trigger cannot be below 125');
If StrToFloat(edt_newrec_co2.Text) < 450 then
ErrorList.Add('CO2 recommended level cannot be below 450');
If StrToFloat(edt_newrec_voc.Text) < 125 then
ErrorList.Add('Volatile compounds recommended level cannot be below 125');
If (ErrorList.Count > 0) then Result:=FALSE
else Result := True;
end; end;
function Ttriggersform.AssignAndSaveTriggers:boolean; function Ttriggersform.AssignAndSaveTriggers: boolean;
begin begin
Result:=FALSE; Result := False;
TRY try
FooBotTriggerArray[C_HIGH, C_PM]:=StrToFloat(edt_newhightrigger_pm.text); FooBotTriggerArray[C_HIGH, C_PM] := StrToFloat(edt_newhightrigger_pm.Text);
FooBotTriggerArray[C_LOW, C_PM]:=StrToFloat(edt_newlowtrigger_pm.text); FooBotTriggerArray[C_LOW, C_PM] := StrToFloat(edt_newlowtrigger_pm.Text);
FooBotTriggerArray[C_HIGH, C_TMP]:=StrToFloat(edt_newhightrigger_tmp.text); FooBotTriggerArray[C_HIGH, C_TMP] := StrToFloat(edt_newhightrigger_tmp.Text);
FooBotTriggerArray[C_LOW, C_TMP]:=StrToFloat(edt_newlowtrigger_tmp.text); FooBotTriggerArray[C_LOW, C_TMP] := StrToFloat(edt_newlowtrigger_tmp.Text);
FooBotTriggerArray[C_HIGH, C_HUM]:=StrToFloat(edt_newhightrigger_hum.text); FooBotTriggerArray[C_HIGH, C_HUM] := StrToFloat(edt_newhightrigger_hum.Text);
FooBotTriggerArray[C_LOW, C_HUM]:=StrToFloat(edt_newlowtrigger_hum.text); FooBotTriggerArray[C_LOW, C_HUM] := StrToFloat(edt_newlowtrigger_hum.Text);
FooBotTriggerArray[C_HIGH, C_CO2]:=StrToInt(edt_newhightrigger_co2.text); FooBotTriggerArray[C_HIGH, C_CO2] := StrToInt(edt_newhightrigger_co2.Text);
FooBotTriggerArray[C_LOW, C_CO2]:=StrToInt(edt_newlowtrigger_co2.text); FooBotTriggerArray[C_LOW, C_CO2] := StrToInt(edt_newlowtrigger_co2.Text);
FooBotTriggerArray[C_HIGH, C_VOC]:=StrToInt(edt_newhightrigger_voc.text); FooBotTriggerArray[C_HIGH, C_VOC] := StrToInt(edt_newhightrigger_voc.Text);
FooBotTriggerArray[C_LOW, C_VOC]:=StrToInt(edt_newlowtrigger_voc.text); FooBotTriggerArray[C_LOW, C_VOC] := StrToInt(edt_newlowtrigger_voc.Text);
FooBotTriggerArray[C_HIGH, C_ALLPOLLU]:=StrToFloat(edt_newhightrigger_allpollu.text); FooBotTriggerArray[C_HIGH, C_ALLPOLLU] := StrToFloat(edt_newhightrigger_allpollu.Text);
FooBotTriggerArray[C_LOW, C_ALLPOLLU]:=StrToFloat(edt_newlowtrigger_allpollu.text); FooBotTriggerArray[C_LOW, C_ALLPOLLU] := StrToFloat(edt_newlowtrigger_allpollu.Text);
except except
raise exception.create('Error in AssignAndSaveTriggers'); raise Exception.Create('Error in AssignAndSaveTriggers');
Exit; Exit;
end; end;
If NOT SaveTriggers then ErrorList.Add('Unable to save new triggers to disk') if not SaveTriggers then
else Result:=TRUE; ErrorList.Add('Unable to save new triggers to disk')
else
Result := True;
end; end;
function Ttriggersform.AssignAndSaveRecommendedLevels:boolean; function Ttriggersform.AssignAndSaveRecommendedLevels: boolean;
begin begin
Result:=FALSE; Result := False;
TRY try
RecommendedLevelsArray[C_PM]:=StrToFloat(edt_newrec_pm.Text); RecommendedLevelsArray[C_PM] := StrToFloat(edt_newrec_pm.Text);
RecommendedLevelsArray[C_TMP]:=StrToFloat(edt_newrec_tmp.Text); RecommendedLevelsArray[C_TMP] := StrToFloat(edt_newrec_tmp.Text);
RecommendedLevelsArray[C_HUM]:=StrToFloat(edt_newrec_hum.Text); RecommendedLevelsArray[C_HUM] := StrToFloat(edt_newrec_hum.Text);
RecommendedLevelsArray[C_CO2]:=StrToFloat(edt_newrec_co2.Text); RecommendedLevelsArray[C_CO2] := StrToFloat(edt_newrec_co2.Text);
RecommendedLevelsArray[C_VOC]:=StrToFloat(edt_newrec_voc.Text); RecommendedLevelsArray[C_VOC] := StrToFloat(edt_newrec_voc.Text);
RecommendedLevelsArray[C_ALLPOLLU]:=StrToFloat(edt_newrec_allpollu.Text); RecommendedLevelsArray[C_ALLPOLLU] := StrToFloat(edt_newrec_allpollu.Text);
except except
raise exception.create('Error in AssignAndSaveRecommendedLevels'); raise Exception.Create('Error in AssignAndSaveRecommendedLevels');
Exit; Exit;
end; end;
If NOT SaveRecommendedLevels then ErrorList.Add('Unable to save new recommended levels to disk') if not SaveRecommendedLevels then
else Result:=TRUE; ErrorList.Add('Unable to save new recommended levels to disk')
else
Result := True;
end; end;
procedure Ttriggersform.DisplayCurrentValues; procedure Ttriggersform.DisplayCurrentValues;
@ -228,20 +313,20 @@ begin
{$ENDIF} {$ENDIF}
// Recommended levels // Recommended levels
lbl_currentrec_pm.Caption := lbl_currentrec_pm.Caption :=
Format('Current recommended level: %.1f %s', [RecommendedLevelsArray[C_PM], Format('Current recommended level: %.1f %s',
FoobotDataObject.Units[C_PM]]); [RecommendedLevelsArray[C_PM], FoobotDataObject.Units[C_PM]]);
lbl_currentrec_tmp.Caption := lbl_currentrec_tmp.Caption :=
Format('Current recommended level: %.1f %s', [RecommendedLevelsArray[C_TMP], Format('Current recommended level: %.1f %s',
FoobotDataObject.Units[C_TMP]]); [RecommendedLevelsArray[C_TMP], FoobotDataObject.Units[C_TMP]]);
lbl_currentrec_hum.Caption := lbl_currentrec_hum.Caption :=
Format('Current recommended level: %.1f %s', [RecommendedLevelsArray[C_HUM], Format('Current recommended level: %.1f %s',
FoobotDataObject.Units[C_HUM]]); [RecommendedLevelsArray[C_HUM], FoobotDataObject.Units[C_HUM]]);
lbl_currentrec_co2.Caption := lbl_currentrec_co2.Caption :=
Format('Current recommended level: %.0f %s', [RecommendedLevelsArray[C_CO2], Format('Current recommended level: %.0f %s',
FoobotDataObject.Units[C_CO2]]); [RecommendedLevelsArray[C_CO2], FoobotDataObject.Units[C_CO2]]);
lbl_currentrec_voc.Caption := lbl_currentrec_voc.Caption :=
Format('Current recommended level: %.0f %s', [RecommendedLevelsArray[C_VOC], Format('Current recommended level: %.0f %s',
FoobotDataObject.Units[C_VOC]]); [RecommendedLevelsArray[C_VOC], FoobotDataObject.Units[C_VOC]]);
lbl_currentrec_allpollu.Caption := lbl_currentrec_allpollu.Caption :=
Format('Current recommended level: %.1f %s', Format('Current recommended level: %.1f %s',
[RecommendedLevelsArray[C_ALLPOLLU], FoobotDataObject.Units[C_ALLPOLLU]]); [RecommendedLevelsArray[C_ALLPOLLU], FoobotDataObject.Units[C_ALLPOLLU]]);
@ -287,26 +372,32 @@ begin
// Assign Edit control values // Assign Edit control values
// Recommended // Recommended
edt_newrec_pm.Text:=Format('%.1f', [RecommendedLevelsArray[C_PM]]); edt_newrec_pm.Text := Format('%.1f', [RecommendedLevelsArray[C_PM]]);
edt_newrec_tmp.Text:=Format('%.1f', [RecommendedLevelsArray[C_TMP]]); edt_newrec_tmp.Text := Format('%.1f', [RecommendedLevelsArray[C_TMP]]);
edt_newrec_hum.Text:=Format('%.1f', [RecommendedLevelsArray[C_HUM]]); edt_newrec_hum.Text := Format('%.1f', [RecommendedLevelsArray[C_HUM]]);
edt_newrec_co2.Text:=Format('%.0f', [RecommendedLevelsArray[C_CO2]]); edt_newrec_co2.Text := Format('%.0f', [RecommendedLevelsArray[C_CO2]]);
edt_newrec_voc.Text:=Format('%.0f', [RecommendedLevelsArray[C_VOC]]); edt_newrec_voc.Text := Format('%.0f', [RecommendedLevelsArray[C_VOC]]);
edt_newrec_allpollu.Text:=Format('%.1f', [RecommendedLevelsArray[C_ALLPOLLU]]); edt_newrec_allpollu.Text := Format('%.1f', [RecommendedLevelsArray[C_ALLPOLLU]]);
// HighTrigger // HighTrigger
edt_newhightrigger_pm.Text:=Format('%.1f',[double(FooBotTriggerArray[C_HIGH, C_PM])]); edt_newhightrigger_pm.Text := Format('%.1f', [double(FooBotTriggerArray[C_HIGH, C_PM])]);
edt_newhightrigger_tmp.Text:=Format('%.1f',[double(FooBotTriggerArray[C_HIGH, C_TMP])]); edt_newhightrigger_tmp.Text :=
edt_newhightrigger_hum.Text:=Format('%.1f',[double(FooBotTriggerArray[C_HIGH, C_HUM])]); Format('%.1f', [double(FooBotTriggerArray[C_HIGH, C_TMP])]);
edt_newhightrigger_co2.Text:=Format('%.0f',[double(FooBotTriggerArray[C_HIGH, C_CO2])]); edt_newhightrigger_hum.Text :=
edt_newhightrigger_voc.Text:=Format('%.0f',[double(FooBotTriggerArray[C_HIGH, C_VOC])]); Format('%.1f', [double(FooBotTriggerArray[C_HIGH, C_HUM])]);
edt_newhightrigger_allpollu.Text:=Format('%.1f',[double(FooBotTriggerArray[C_HIGH, C_ALLPOLLU])]); edt_newhightrigger_co2.Text :=
// LowTrigger Format('%.0f', [double(FooBotTriggerArray[C_HIGH, C_CO2])]);
edt_newlowtrigger_pm.Text:=Format('%.1f',[double(FooBotTriggerArray[C_LOW, C_PM])]); edt_newhightrigger_voc.Text :=
edt_newlowtrigger_tmp.Text:=Format('%.1f',[double(FooBotTriggerArray[C_LOW, C_TMP])]); Format('%.0f', [double(FooBotTriggerArray[C_HIGH, C_VOC])]);
edt_newlowtrigger_hum.Text:=Format('%.1f',[double(FooBotTriggerArray[C_LOW, C_HUM])]); edt_newhightrigger_allpollu.Text :=
edt_newlowtrigger_co2.Text:=Format('%.0f',[double(FooBotTriggerArray[C_LOW, C_CO2])]); Format('%.1f', [double(FooBotTriggerArray[C_HIGH, C_ALLPOLLU])]);
edt_newlowtrigger_voc.Text:=Format('%.0f',[double(FooBotTriggerArray[C_LOW, C_VOC])]); // LowTrigger
edt_newlowtrigger_allpollu.Text:=Format('%.1f',[double(FooBotTriggerArray[C_LOW, C_ALLPOLLU])]); edt_newlowtrigger_pm.Text := Format('%.1f', [double(FooBotTriggerArray[C_LOW, C_PM])]);
edt_newlowtrigger_tmp.Text := Format('%.1f', [double(FooBotTriggerArray[C_LOW, C_TMP])]);
edt_newlowtrigger_hum.Text := Format('%.1f', [double(FooBotTriggerArray[C_LOW, C_HUM])]);
edt_newlowtrigger_co2.Text := Format('%.0f', [double(FooBotTriggerArray[C_LOW, C_CO2])]);
edt_newlowtrigger_voc.Text := Format('%.0f', [double(FooBotTriggerArray[C_LOW, C_VOC])]);
edt_newlowtrigger_allpollu.Text :=
Format('%.1f', [double(FooBotTriggerArray[C_LOW, C_ALLPOLLU])]);
end; end;