Set Port 1 ACIA
Set the communication properties of Port 1 in an M552 transducer.
Arrange a 32 bit
floating point number as below:
fT = Baudrate/10 * 32;
fT += Parity * 8;
fT += StopBits * 4;
fT += Endian;
Convert to floating point number and transmit to the M552
Example:
Baud 38000/10 * 32 = 122880
Parity (even)
* 8 = 8
Stop Bits (1) * 4 = 4
Endian (0-3) = 0
Change 122892 to floating point IEEE754 format:
47F00600
Sample Coding
Slave Address = 1
Writing To 4X Registers - code 16 (10 hex)
Set Port1 to 38400 baud,
even parity, 1 stop bit and Big Endian (47 F0 06 00)
Message Packet To SLAVE
01 10 00 66 00 02 04 02 47 F0 06 00 62 8A
Response Packet From SLAVE SLAVE
01 10 00 66 00 02 A1 D7