s7-1500 time and date display in Citect via OPCua

Hello Everyone,

I would like to display the recorded date and time in my plc on a Citect popup. 

My PLC variable is LDT datatype, how do i communicate this correctly to Citect via OPCua. I know I will have to make some conversions, but which datatype do i need in the PLC and which datatype do i need in Citect ? Could you please help me with this. I can't find any good documentation about this.

Thank you very much in advance. 

Parents
  • As i define a UDINT in the PLC and a ULONG in Citect, and my date is for example LDT#1970-01-01-00:00:01. So 1 second from 1970...
    My UDINT value in the PLC is 1_000_000_000 then my ULONG value in Citect is 1000000000. So it's the same. However when I use the TimeToStr() function in Citect, is shows 2001-09-09 03:46:40. Why is this, is this because of a byte swap?
Reply
  • As i define a UDINT in the PLC and a ULONG in Citect, and my date is for example LDT#1970-01-01-00:00:01. So 1 second from 1970...
    My UDINT value in the PLC is 1_000_000_000 then my ULONG value in Citect is 1000000000. So it's the same. However when I use the TimeToStr() function in Citect, is shows 2001-09-09 03:46:40. Why is this, is this because of a byte swap?
Children
No Data