使用说明
继续软件描述“04(0x04)读取输入寄存器”请求有效寄存器起始地址0有效寄存器数量1响应字节计数2值寄存器输入状态位0..3“03(0x03)读取保持寄存器”请求无效寄存器起始地址0..1或66有效寄存器数量2或1响应功能码、字节计数、,寄存器值寄存器0:值寄存器1:值寄存器66通信监控的时间常数。寄存器值=0(0x0000)没有通信监视,所有其他值用于通信监控,解决方案为10 ms。0x0000至0xFFFF=>0至655.35秒=10.9分钟位信息0 0=状态继电器1关闭1=状态继电器2关闭1=通过总线1切换的状态继电器2 0=通过手动控制切换的继电器1 0=通过总线2切换的继电器2位信息0 0=重置后的初始状态或通信控制继电器1关闭1=重置后初始状态或通讯控制继电器1 1 0=重置或通讯控制中继2关闭1=复位后初始状态,或通信控制中继2在继续软件描述“06(0x06)写入单寄存器”请求寄存器地址0或1或66寄存器值位0–1根据表或以上请求“16(0x10)写入多个寄存器”请求有效寄存器起始地址0或1有效寄存器数量1.2字节计数2 x寄存器数量寄存器值数量x 2字节位0–3根据表响应功能代码、寄存器起始地址
寄存器数量9.2使用Modbus命令奇偶校验和比特率设置的比特率与通过地址开关设置时的值相同。如果奇偶校验或位的值为0,则不进行设置或存储。寄存器内容存储在EEPROM中。“06(0x06)写入单个寄存器”请求有效寄存器地址0x41(65)有效寄存器值2字节位15-8:幻数0x53=83,以防意外写入。仅使用此编号对命令进行进一步分析。帧请求示例的响应回声:从地址0x12旋转开关的设置(18)功能0x06写入单寄存器地址Hi 0x00寄存器地址Lo 0x41比特率和奇偶校验(65)寄存器内容Hi 0x53幻数寄存器内容Lo 0x15奇偶校验偶校验,19200波特所有设备都可以与广播命令(从地址0x00)同时切换,建议不要这样做,因为这可能会导致问题:-其他制造商的设备可能在此地址下有一个用于不同目的的寄存器,然后会以错误的方式操作。-没有来自各个设备的反馈。因此,控制不能立即识别命令是否被正确接收。
instructions
Continue the software description "04 (0x04) Read input register" Request valid register start address 0 Number of valid registers 1 Response byte count 2 Value register input status bit 0.. 3 "03 (0x03) Read holding register" Request invalid register start address 0.. 1 or 66 Number of valid registers 2 or 1 Response function code, byte count, register value register 0: value register 1: value register 66 Time constant for communication monitoring. The register value=0 (0x0000) has no communication monitoring. All other values are used for communication monitoring. The solution is 10 ms. 0x0000 to 0xFFFF=>0 to 655.35 seconds=10.9 minutes bit information 0 0=state relay 1 closed 1=state relay 2 closed 1=state relay 2 switched through bus 1 0=relay 1 switched through manual control 0=relay 2 bit information switched through bus 2 0=initial state after reset or communication control relay 1 closed 1=initial state after reset or communication control relay 1 1 0=reset or communication control relay 2 closed 1=initial state after reset, Or the communication control relay 2 requests the register address 0 or 1 or 66 register value bits 0 – 1 according to the table or the above request "16 (0x10) writing multiple registers" to request the valid register starting address 0 or 1. The number of valid registers is 1.2 bytes count 2 x the number of register values x 2 bytes bits 0 – 3 according to the table to respond to the function code, register starting address
Number of registers 9.2 The bit rate set using the Modbus command parity sum bit rate is the same as the value set through the address switch. If the value of parity or bit is 0, it is not set or stored. The register contents are stored in EEPROM. "06 (0x06) Write to Single Register" requests valid register address 0x41 (65) valid register value 2 byte bits 15-8: magic number 0x53=83 to prevent accidental writing. Use this number only for further analysis of the command. Echo response of frame request example: write single register address Hi 0x00 register address Lo 0x41 bit rate and parity (65) register content Hi 0x53 magic number register content Lo 0x15 parity check from the setting (18) function 0x06 of rotary switch at address 0x12, Because this may cause problems: - Other manufacturers' devices may have a register under this address for different purposes, and then operate in the wrong way- No feedback from each device. Therefore, the control cannot immediately identify whether the command was received correctly.