Example for SINUMERIK 828D with SENTRON PAC3200
Swap over the byte sequence of the total active power in ID144:
For the total active power, the numerical value of 18.4 is supplied from SENTRON. This
corresponds to a hexadecimal value of 0x41933334, which is located just like this in the double
word ID144. To be further processed by the PLC, the sequence of these four bytes must be
swapped over: 0x34339341.
Also the values for the active energy import tariff 1 and active energy export tariff 1 must be
handled in this way.
Figure 3-5 SWAP_DW subroutine
Figure 3-6 Byte sequence
You can find the SWAP_DW subroutine on the Toolbox-CD under Examples\PLC
Ctrl-E Analysis
3.3 Commissioning the PLC for Ctrl-E Analysis
Ctrl-Energy
System Manual, 01/2015, 6FC5397-0EP40-5BA2 35