{"payload":{"meta":{"Graph":{"@Type":"81297157","@Value":{"Guid":"(Guid)926948d2-5209-479c-ac9f-2bcbaa168f97","ParentGuid":"(Guid)74ccca2f-50e3-4d5a-9d7a-9fd420284f83","Name":"(string)atInlet","Properties":{"@Type":"2c41fa04:IDictionary","@Value":[{"@Key":"(Guid)24568a24-c491-472c-a21f-ee5d33859fab","@Value":{"@Type":"24568a24","@Value":{"MemoryReserveForOnlineChange":"(int)0","ExcludeFromBuild":"(bool)True","External":"(bool)False","EnableSystemCall":"(bool)False","CompilerDefines":"(string)","LinkAlways":"(bool)False","Undefines":{"@Type":"[string]","@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)ca9f5e32-36a8-4726-82c3-a6db760e9258"}]}}}}]},"TypeGuid":"(Guid)6f9dac99-8de1-4efc-8465-68ac443b7d08","EmbeddedTypeGuids":{"@Type":"[Guid]","@Value":["(Guid)a9ed5b7e-75c5-4651-af16-d2c27e98cb94","(Guid)3b83b776-fb25-43b8-99f2-3c507c9143fc"]}}},"TypeInfos":{"24568a24":"{24568a24-c491-472c-a21f-ee5d33859fab}","2c41fa04":"{2c41fa04-1834-41c1-816e-303c7aa2c05b}","81297157":"{81297157-7ec9-45ce-845e-84cab2b88ade}","829a18f2":"{829a18f2-c514-4f6e-9634-1df173429203}","bool":"System.Boolean","fa2ee218":"{fa2ee218-a39b-4b6d-b249-49dbddbd168a}","Guid":"System.Guid","int":"System.Int32","string":"System.String"}},"object":{"Graph":{"@Type":"6f9dac99","@Value":{"SpecialFunc":{"@Type":"0db3d7bb:Enum","@Value":"None"},"Implementation":{"@Type":"3b83b776","@Value":{"TextDocument":{"@Type":"f3878285","@Value":{"TextBlobForSerialisation":"(string)//Update position\nPosPerUnfilt := (((i.Pos - sp.PosMin) * (100)) / (sp.PosMax - sp.PosMin));\n\n//Filter position\nPosFilterFB(cv := PosPerUnfilt, tau := sp.PosFilter);\ni.PosPer := PosFilterFB.filt;\n\nPulseOnTime := INT_TO_TIME(sp.PulseOnTime * 1000);\nPulseOffTime := INT_TO_TIME(sp.PulseOffTime * 1000);\n\n//Update full open and full close\ni.FullOpen := i.PosPer >= 100;\ni.FullClose := i.PosPer <= 0;\n\n//Calibration\nIF i.CalMinCmd THEN\n\tsp.PosMin := i.Pos;\nEND_IF;\nIF i.CalMaxCmd THEN\n\tsp.PosMax := i.Pos;\nEND_IF;\n\n//Fault Handling\nIF (i.Control = -999) THEN\n\tIF sp.Auto THEN\n\t\ti.OpenDmd := FALSE;\n\t\ti.CloseDmd := FALSE;\n\tEND_IF;\nELSE\n\t//Open\n\tOpenEn := i.Control > (sp.SP + (sp.Deadband / 2));\n\tPulseOpen (Ontime := PulseOnTime, Offtime := PulseOffTime, EN := OpenEn);\n\tIF sp.Auto THEN\n\t\tIF (PulseOnTime > T#0S) THEN\n\t\t\ti.OpenDmd := PulseOpen.Out AND NOT i.CloseDmd;\n\t\tELSE\n\t\t\ti.OpenDmd := OpenEn AND NOT i.CloseDmd;\n\t\tEND_IF;\n\t\tIF i.FullOpen THEN\n\t\t\ti.OpenDmd := FALSE;\n\t\tEND_IF;\n\tEND_IF;\n\n\t//Close\n\tCloseEn := i.Control < (sp.SP - (sp.Deadband / 2));\n\tPulseClose (OnTime := PulseOnTime, OffTIme := PulseOffTime, EN := CloseEn);\n\tIF sp.Auto THEN\n\t\tIF (PulseOnTime > T#0S) THEN\n\t\t\ti.CloseDmd := PulseClose.Out AND NOT i.OpenDmd;\n\t\tELSE\n\t\t\ti.CloseDmd := CloseEn AND NOT i.OpenDmd;\n\t\tEND_IF\n\t\tIF i.FullClose THEN\n\t\t\ti.CloseDmd := FALSE;\n\t\tEND_IF;\n\tEND_IF;\n\nEND_IF","LineInfoPersistence":"(string)926948d2-5209-479c-ac9f-2bcbaa168f97_Impl_LineIds"}}}},"Interface":{"@Type":"a9ed5b7e","@Value":{"TextDocument":{"@Type":"f3878285","@Value":{"TextBlobForSerialisation":"(string)FUNCTION_BLOCK atInlet\nVAR\n\tOpenEn: BOOL;\n\tCloseEn: BOOL;\n\tPulseOpen: atPulseCon;\n\tPulseClose: atPulseCon;\nEND_VAR\nVAR_IN_OUT\n\ti: atInletData;\n\tsp: atInletSP;\nEND_VAR\nVAR\n\tPulseOnTime: TIME;\n\tPulseOffTime: TIME;\n\tPosFilterFB: atFilter;\n\tPosPerUnfilt: REAL;\nEND_VAR\n","LineInfoPersistence":"(string)926948d2-5209-479c-ac9f-2bcbaa168f97_Decl_LineIds"}}}},"UniqueIdGenerator":"(string)1661","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"}