how to configure com_mod_master to read a holding register?
I'm a student and i have a seneca sensor [s230 ta] to measure current and voltage on 3 phases. It's connected over modbus rtu to an abb pm564 at com1. I've already programmed as in the documentation and i can't see anything. I get 0 (zero).
I want to get registers 40135-40140 but not success, i also tried only with register 40001 which is a single word and has device id and firmware "bit [15:8] contain the module’s id: 41. Bit [7:0] contain the firmware's external revision" but no chance. I've checked several documents and videos without success, so i'll appreciate your help.
I assume that your values are real types. First check that the parameters in modbus configuration are OK (address, operation mode, baudrate etc.). Also check cable's pinouts. When i had communication between panel and AC500 PLC, I addressed like this: 40000 = %MD0.1, 40002 = %MD0.2, 40004 = %MD0.3...(for REAL)
Before starting to program a controller as a master, it is always a good practice to verify communication of the MODBUS rtu (seneca sensor) over MODBUS via a 3rd party MODBUS master application such as modscan (modscan has a free to download demo version) or modbuspoll. In case you are getting the required values in the right registers on the above mentioned apps, it indicates that both the master and the slave device are in sync w.r.t communication parameters, such as baud rate, parity, stop bits etc.
Also, make sure that both the controller and the slave device have identical communication settings and that the controller MODBUS COM-1 port is set as CLIENT/MASTER in its configuration window.
Next, refer to the uploaded image to build your program. Since you want to read registers 40135-40140,set ADDR i/p to 34 ,NB i/p to 6 and set the other remaining parameters as per screen shot.
ABB systems engineer