10-14-2013 03:08 PM
DWS23 and S1ack, thanks for sorting that out. That is an unfortunate legacy limitation of Modbus. It is worth noting two things. First, the master code is written such that it will request exactly what you tell it to--the error is not thrown by the master, but by the slave. Thus, if your slave supports 500 register reads, the master will not stop you. Second, the reason you got a disconnect is that my error handling is very stupid . Any error in the example will result in a disconnect. However during normal operation you would not need to disconnect just because of that error.
Hi India,
I am unfamiliar with that error code and I cannot find any record of it. Can you post back with some additional information? Where does the error occur? What VI throws it? What is the error message?
Thanks,
Daniel
10-15-2013 12:21 AM
Hi Daniel,
The 6101 seems to be a generic error code . Refer http://forums.ni.com/t5/LabVIEW/Timeout-error-code-6101-for-acquisition-from-MODBUS-instrument/td-p/... .
I suggested the customer to use the following MODBUS Library https://decibel.ni.com/content/docs/DOC-30140 . However each time he runs the code, he doesn;t get the values from the register he is trying to read. The VIs timeout. However when the customer uses MODSCAN 32 application to access the register, he is successfully able to do so. He faces the issue only with the labview library. Let me know if you have any leads on this
Thanks
Pranav
AE
(India)
10-15-2013 11:50 AM
Hi Pranav,
If you note the KB linked in that post, the error code is generated by the old modbus library, not the one the customer referenced. However you are correct that 6101 is thrown by that library in the timeout case.
As far as support goes, there is not much I can do with the information you provided. If the error occurs with both the old library and the new library, which were both written more-or-less independently, I have only a few thoughts and suggestions:
Thanks,
Daniel
10-15-2013 06:15 PM
Hey Daniel,
On a cRIO 9082, in order to use 2 wire RS485, we need to change the physical wiring, but also configure the Serial property, Wire Node to have the enum value: RS485/Wire2-Auto.
Is there an easy way to do this with the Modbus API? Which subVI's do I need to modify?
Thanks,
Joey (AE)
10-23-2013 08:05 PM
Okay, so I understand what you were talking about here now. There is no way to set that at present, but you can set it on the visa resource you wire in without much difficulty. Its feedback that I'll pass along, though.
10-23-2013 08:08 PM
Known Issue [Serial slave only]:
I've received feedback that there is a performance issue with the serial slave version of the library. Specifically, the background daemon rails the CPU while waiting on messages.
Update:
1.0.10 is now posted and fixes this issue.
10-28-2013 02:38 AM
Hello,
I used Modbus API library to realize a Modbus serial master in LV2013. The master can transmit the command to the server and the server response. I also used oscilloscope to check the serial line, no error. But labview receive no data. What is the reason? Thanks.
10-28-2013 07:10 AM
Going to need more information to help you.
What is the server?
What commands did you send from the LV client?
You state 'the server response' do you mean that is does indeed respond?
If it does respond, and no exceptions from modbus function blocks, do you have the response frame in bytes?
You could try to poll the server with modbus poll and capture the byte traffic on the wire. Then plug the poll and response into a modbus protocol analyser and verify the poll and response are properly formatted.
10-28-2013 10:03 AM
Thank you for your reply.
I use arm cotex-M0 mcu as Modbus server. The Modbus poll sent read holding register command to the mcu. It can received the response from mcu. All data is correct. But when I sent data with LV used Modbus API library, mcu response. But no data received. I put a probe at the subVI register output.
10-28-2013 12:41 PM
Can you post the actual data from the line? You said you saw the mcu respond with the correct information. What does that data look like? What does labview send?