AlfredoQuintero
Lifetime Supporting Member
To Codesys and TwinCAT experts, if you could spare some time to help this newbie, I will be so very grateful, just please promise not to laugh too raucously at my ignorance.
Months ago I managed to write a simple Codesys program that measures the time the PLC program has been up and running using the RTC (Real Time Clock) function, but what a head scratch I have hit when trying to do the same with TwinCAT. I use a first scan bit to get an initial time in the TwinCAT, but even though the EN bit is FALSE, this RTC is executed every scan, thus I have no initial time to subtract. After much head banging I have swallowed my pride and herewith cry for help.
Months ago I managed to write a simple Codesys program that measures the time the PLC program has been up and running using the RTC (Real Time Clock) function, but what a head scratch I have hit when trying to do the same with TwinCAT. I use a first scan bit to get an initial time in the TwinCAT, but even though the EN bit is FALSE, this RTC is executed every scan, thus I have no initial time to subtract. After much head banging I have swallowed my pride and herewith cry for help.