Lounarok / nmodbus

Automatically exported from code.google.com/p/nmodbus
0 stars 0 forks source link

ReadHoldingRegisters problem #15

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

I'm trying to read registers from a device using serial RTU.
I can write register fine, but am having trouble reading them.

my read code is:

ushort[] ReadValueTmp = _ModbusMaster.ReadHoldingRegisters(0x02, 0x0003, 
0x0001);

What is the expected output? What do you see instead?
I get the exception:
"Function code 116 not supported."

What version of the product are you using? On what operating system?
I've been using 1.1.0.0
I also just tried it with 1.2 beta and got the same result.
XP SP2

Please provide any additional information below.

I don't know if it is something that I am doing wrong or if it is a 
problem with the device I am communicating with.  I am trying to read 
registers on an Automation Direct GS2 Frequency Motor Drive.

Thank you.  nmodbus like an awfully good component.  I'm just excited to 
get it up and running.

Ryan

Original issue reported on code.google.com by rher...@hotmail.com on 14 Jun 2007 at 5:53

GoogleCodeExporter commented 9 years ago
Here's the log for the problem I am having:

INFO  Modbus.IO.ModbusTransport Write - TX: 2, 3, 0, 3, 0, 1, 116, 57
INFO  Modbus.IO.ModbusRtuTransport ReadResponse - RX: 2, 3, 0, 3, 0
ERROR Modbus.IO.ModbusTransport CreateResponse - Checksums failed to match 2, 
3, 0 !
= 2, 3, 0, 3, 0
ERROR Modbus.IO.ModbusTransport UnicastMessage - IO Exception, 3 retries 
remaining - 
Checksums failed to match 2, 3, 0 != 2, 3, 0, 3, 0
INFO  Modbus.IO.ModbusTransport Write - TX: 2, 3, 0, 3, 0, 1, 116, 57
ERROR Modbus.IO.ModbusRtuTransport ResponseBytesToRead - Function code 116 not 
supported.

Original comment by rher...@hotmail.com on 14 Jun 2007 at 6:57

GoogleCodeExporter commented 9 years ago
Fixed it... I wasn't using my 232->485 converter properly.  Sorry if I wasted 
anybody's time.

Ryan

Original comment by rher...@hotmail.com on 18 Jun 2007 at 6:56

GoogleCodeExporter commented 9 years ago

Original comment by sja...@gmail.com on 2 Dec 2007 at 1:36