Current location - Plastic Surgery and Aesthetics Network - Plastic surgery and beauty - Does Broadcom need high-low bit conversion when accepting messages?
Does Broadcom need high-low bit conversion when accepting messages?
Does Broadcom need high-low bit conversion when accepting messages?

The data read at this time is incorrect, and it can only be displayed normally after the high and low words are exchanged.

The following summarizes several methods of exchanging high and low words or bytes for your reference.

On the way to TIA, a floating-point data REAL occupies 4 bytes, which is DWORD.

Take the exchange of high and low words in DWORD as an example to illustrate (the same is true of high and low bytes in WORD):

First, through indirect addressing and fragmented access.

As shown in the figure below, create a new FC block, and the interface variables of the block are shown in the figure below. As shown in the figure below, SCL program assigns the high-order word of input variable to the low-order word of output variable, and assigns the low-order word of input variable to the high-order word of output variable.

Add two variables inputData and outputData to the data block, and the data type is real floating point.