4/2/2022 1:37 AM | |
Joined: 9/27/2006 Last visit: 10/28/2024 Posts: 12292 Rating: (2690)
|
Hello insmaelillo; Have a look at the following FAQ, dscussing how to read a S5TIME value in WinCC: https://support.industry.siemens.com/cs/ww/en/view/22531788 As you can see, it requires a bit of VB programming knowhow to do so. Doing the conversion in the PLC requires less of a hastle, there exist basic conversion instructions you can use in Step 7: https://support.industry.siemens.com/cs/ww/en/view/1851190 On the other hand, you would find it much easier to modify your PLC program slighty,, using an IEC timer (such as SFB4 "TON") instead of a S5 timer. The IEC Timers use a variable datatype TIME, which is a DINT value representing milliseconds. Conversion would be a lot simpler then, divide the TIME value coming from SFB4 by 1000 to show seconds in the HMI, multiply the HMI tag value back to milliseconds in the PLC by multiplying by 1000. Look at #dp's post in this discussion, for example: Hope this helps, Daniel Chartier |
Follow us on