{"payload":{"meta":{"Graph":{"@Type":"81297157","@Value":{"Guid":"(Guid)6d8050de-036d-458d-952a-cf9433be7bb5","ParentGuid":"(Guid)74ccca2f-50e3-4d5a-9d7a-9fd420284f83","Name":"(string)atPulse","Properties":{"@Type":"2c41fa04:IDictionary","@Value":[{"@Key":"(Guid)829a18f2-c514-4f6e-9634-1df173429203","@Value":{"@Type":"829a18f2","@Value":{"ParentObjects":{"@Type":"fa2ee218:IDictionary","@Value":[{"@Key":"(Guid)d9b2b2cc-ea99-4c3b-aa42-1e5c49e65b84","@Value":"(Guid)995b2022-2e3b-4577-8ec9-cf70ad461a07"}]}}}}]},"TypeGuid":"(Guid)6f9dac99-8de1-4efc-8465-68ac443b7d08","EmbeddedTypeGuids":{"@Type":"[Guid]","@Value":["(Guid)a9ed5b7e-75c5-4651-af16-d2c27e98cb94","(Guid)3b83b776-fb25-43b8-99f2-3c507c9143fc"]}}},"TypeInfos":{"2c41fa04":"{2c41fa04-1834-41c1-816e-303c7aa2c05b}","81297157":"{81297157-7ec9-45ce-845e-84cab2b88ade}","829a18f2":"{829a18f2-c514-4f6e-9634-1df173429203}","fa2ee218":"{fa2ee218-a39b-4b6d-b249-49dbddbd168a}","Guid":"System.Guid","string":"System.String"}},"object":{"Graph":{"@Type":"6f9dac99","@Value":{"SpecialFunc":{"@Type":"0db3d7bb:Enum","@Value":"None"},"Implementation":{"@Type":"3b83b776","@Value":{"TextDocument":{"@Type":"f3878285","@Value":{"TextBlobForSerialisation":"(string)//Generate system time pulses - not tied to RTC, uses system time since startup\n//2024-02-08 CWD Initial create\n//2024-10-04 CWD Add RTC pulses\n\n// ===== System time pulses =====\n//Get time since start\nSysTimeGetUs(TSSus);\n\n//Pulses\nT_100ms_pulse := (TSSus / 1000) MOD 100 < 50;\nT_sec_pulse := (TSSus / 10000) MOD 100 < 50;\n\n//One Shots\n_100ms_trig(CLK := T_100ms_pulse);\nT_100ms_OS := _100ms_trig.Q;\n\nsec_trig(CLK := T_sec_pulse);\nT_Sec_OS := sec_trig.Q;\n\n// ===== RTC Pulses =====\n//Generate pulses using RTC\nSysTimeRtcHighResGet(dateTimeULINT);\nSysTimeRtcConvertHighResToLocal(pTimeStamp:=dateTimeULINT,pDate:= tim);\n//1 second pulse\nRTC_secOS:=FALSE;\nIF lastSecond <> tim.wSecond THEN //Don't pulse on first pass\n\tIF lastSecond <> 65535 THEN\n\t\tRTC_secOS:= TRUE;\n\tEND_IF\n\tlastSecond := tim.wSecond;\nEND_IF\n\n//1 hour pulse\nRTC_hourOS:= FALSE;\nIF lastHour <> tim.wHour THEN\n\tIF lastHour <> 65535 THEN //don't do this on first pass\n\t\tRTC_hourOS:= TRUE;\t\t\n\tEND_IF\n\tlastHour := tim.wHour;\nEND_IF","LineInfoPersistence":"(string)6d8050de-036d-458d-952a-cf9433be7bb5_Impl_LineIds"}}}},"Interface":{"@Type":"a9ed5b7e","@Value":{"TextDocument":{"@Type":"f3878285","@Value":{"TextBlobForSerialisation":"(string){attribute 'symbol' := 'none'}\nFUNCTION_BLOCK atPulse\nVAR_OUTPUT\n\t// System 100ms pulse\n\tT_100ms_pulse: BOOL;\n\t// System 100ms one shot\n\tT_100ms_OS: BOOL;\n\t// System 1 second pulse\n\tT_Sec_pulse: BOOL;\n\t// System 1 second one shot\n\tT_Sec_OS: BOOL;\n\t// RTC 1 second one shot\n\tRTC_secOS: BOOL;\n\t// RTC 1 hour one shot\n\tRTC_hourOS: BOOL;\nEND_VAR\nVAR\n\tTSSus: SYSTIME;\n\t_100ms_trig: R_TRIG;\n\tsec_trig: R_TRIG;\n\tdateTimeULINT: ULINT;\n\ttim: SYSTIMEDATE;\n\tlastSecond: UINT := 65535;\n\tlastHour: UINT := 65535;\nEND_VAR\n\n","LineInfoPersistence":"(string)6d8050de-036d-458d-952a-cf9433be7bb5_Decl_LineIds"}}}},"UniqueIdGenerator":"(string)854","POULevel":{"@Type":"8e575c5b:Enum","@Value":"Standard"},"ChildObjectGuids":{"@Type":"ArrayList:IList","@Value":[]},"AddAttributeSubsequent":"(bool)False"}},"TypeInfos":{"0db3d7bb":"{0db3d7bb-cde0-4416-9a7b-ce49a0124323}","3b83b776":"{3b83b776-fb25-43b8-99f2-3c507c9143fc}","6f9dac99":"{6f9dac99-8de1-4efc-8465-68ac443b7d08}","8e575c5b":"{8e575c5b-1d37-49c6-941b-5c0ec7874787}","a9ed5b7e":"{a9ed5b7e-75c5-4651-af16-d2c27e98cb94}","ArrayList":"System.Collections.ArrayList","bool":"System.Boolean","f3878285":"{f3878285-8e4f-490b-bb1b-9acbb7eb04db}","string":"System.String"}}},"FormatVersion":"1.0"}