11-25-2012 11:34 PM
recently,i try to communicate between PC and NEC based on modbus protocol.
at the help of the NI engineer,i began to use the modbus library from the forums.and when i run the programs ,the property of visa resource error out.and the following program didn't work as it was supposed to happen.
as a newbie,i am confused.and any advice is appreciated.
thank you very much.
ps:my program is as follows.
Solved! Go to Solution.
11-26-2012 02:08 AM
Hi,
It would help if you tell us what the error code you get.
What interface are you using ?
Kees
11-26-2012 02:15 AM
yeah,i describe a wrong error.the error is error-1073807253.and nearly all the VIS i used is from modbus library.
the interface is serial port by rs-485.
thanks a lot
11-26-2012 04:38 AM
Hi,
The error you get is a Framing error'
This means that there must be something wrong with your interface and/or settings.
Are you absolutely sure that your settings (baudrate, parity) are OK ?
Describe you RS-485 connection. Number of wires, terminators, 0V connection, length, etc.
Kees
11-26-2012 06:51 PM
i'm sure all the parameter that are correct.did you see the program i uploaded?
well,thank you all the same.i'll check it again.
11-27-2012 02:36 AM
Hi,
OK, now you have to know if your connection is OK.
Try the attached program with the data mentioned in the block diagram.
You can use the loopback command to make sure that your hardware link is OK.
If this works other ModBus communication, like your program, should also work.
Kees
11-28-2012 12:31 AM
thanks a lot.it does work now.
11-28-2012 02:09 AM
Hi,
Can you share the solution with us. Many others have the same problem and most of them would like to learn from the solutions.
Kees
12-03-2012 01:36 AM
yeah,i'd like to share it.in the end,i find it that it's a hardware problem,my rs-485 didn't work as it was supposed to .then caused the error.in a words,my program is ok.thanks a lot.
from this debug,i learn a lot,when you meet a question again,not panic,just keep calm.and overcome the question carefully from the software to the hardware,cause as long as one slight question occurs,it'll don't work well.