Download User_Manual_Ethernet..
Transcript
7.2 Commissioning If an error is detected in the received request an exception frame is returned. | - MBAP Header - | - Function Code - | - Exception code - | The returned function code, in case of an exception, is the transmitted function code with bit 7 set (that means that 0x03 Î 0x83, and 0x10 Î 0x90). Exception codes 0x01 Function code not supported 0x02 Not allowed register no. 0x03 Too many registers or uneven no. of registers, as every register in motor/module is 32 bit and requires 2 x 16 bit modbus registers. (0x03) Read Holding Registers Read of registers. Max. 124 x 16bit registers at a time (=62 x 32bit registers). Only even no. of 16bit registers is supported. The response time is increased slightly for every register added. See Minimum poll time, page 149 for minimum poll time. Request: 7 bytes 1 byte 2 bytes MBAP header Modbus Cmd. (0x03) Motor register no. x 2 or module Register count register no. x 2 + 0x8000 2 bytes Response: 7 bytes 1 byte 1 byte 2 bytes MBAP header Modbus Cmd. (0x03) Data byte count Register value low 16bit 2 bytes Register value high 16bit Example, read of module register 3 (= IP address = 192.168.100.1 = 0xC0.0xA8.0x64.0x01): Request |0x00|0x01|0x00|0x00|0x00|0x06|0x01|0x03|0x80|0x06|0x00|0x02| Response – (Note the byte order!) |0x00|0x01|0x00|0x00|0x00|0x07|0x01|0x03|0x04|0x64|0x01|0xC0|0xA8| Possibly exception responses: 0x02, 0x03. For further documentation see “Modbus_Application_Protocol_V1_1b.pdf” and “Modbus_Messaging_Implementation_Guide_V1_0b.pdf” found on www.modbus.org. ! 148 Please notice: Even though all registers is transmitted as 32 bit, some of them originally derive from 16 bit in the case of MAC050-141. In those situations it is necessary to interpret them as 16 bit to get the sign correct. JVL Industri Elektronik A/S - User Manual - Ethernet expansion modules for MAC motors