© All rights with Robert Bosch GmbH, also for the case of protected rights applications
EN_User_documentation_Instructions_for_controlling_the_Logamatic_5000_controller_series_via_Modbus_TCP_I
P_20210203.docx | 10.02.2021
6. Additional information for setting or reading
single bits in a Modbus Register
If you do not have the possibility to set single bits in a register, you may alternatively
enter an integer corresponding to the desired bit pattern into the Modbus register.
You can also read out a complete register as an integer and interpret it as a bit pat-
tern.
A Modbus register (2 bytes) consists of 16 bits (Bit
0
to Bit
15
). Big-endian (Most Sig-
nificant Bit First (MSB)) is used as byte order. If you now want to set individual bits
in a Modbus register, you can determine the required integer (≙ bit pattern) using
the following table:
Note: For reasons of presentation, the values of all bits have not been specified.
The significance of a bit can be determined using the following formula:
Example for calculating the Valence
You want to determine the value of Bit
15
:
Note:
The following examples use the Modbus data point list from version 1.3.X.
However, the described procedure can be transferred to any Modbus regis-
ter and thus also to the old data point list.
The conversion of integers to bit patterns and vice versa can also be calcu-
lated using a calculator with programming mode.
The setting and reading of bits can also be done via corresponding bit opera-
tions.
Numbers with a b are specified in binary format and numbers with a d in dec-
imal format.
6.1 Setting individual bits in the Modbus Register
Sie möchten die temperaturgeführte Wärmeanforderung über Modbus TCP/IP ver-
wenden. Hierfür müssen Sie das Bit
2
im Holding-Register 405 aktivieren. Die Ta-
belle würde in diesem Fall wie folgt aussehen: