06-25-2018 07:19 AM
Hello,
Our program has been running on a cRIO for a while, reading data using Modbus RTU (Modbus VIs from DSC Module / Real-Time Module).
Suddenly all modbus instruments stopped giving data. I'm getting a timeout on all read calls.
Tried restarting, etc., reading only from one instrument, but nothing helps.
Open MAX and try "Open Visa test panel" on the device, but this gives a message:
Error opening resource: visa://123.234.345.123/ASRL3::INSTR VISA: (Hex 0xBFFF00A7) The remote machine does not exist or is not accepting any connections.
If the NI-VISA server is installed and running on the remote machine,
it might have an incompatible version or might be listening on a different port.
This tells me it's probably not the code, or the physical instruments (since none of them are working now), but something with VISA in general ?
LabVIEW 16, with corresponding VISA 16. Note that this worked well until recently.
Any advice how to proceed with solving this VISA problem?
Solved! Go to Solution.
06-25-2018 09:47 AM
If the software has not changed it is most likely hardware. Did you do any updates or program changes lately?
Do you have a program from the manufacturer that you could use to try and communicate with the devices without using LabVIEW or MAX? Of course, more information would be very helpful. But if you can connect directly to the instrument with the manufacturers program and it works, then you need to find the issue between there and the cRIO causing the issue. It could be a broken wire or a loose connection, but since we know nothing about your setup it is hard to say.
06-25-2018 11:59 AM
The last time I saw that problem it was the port number.
Another process had grabbed the port and since it was not running Modbus, it refused the connection.
Ben
06-27-2018 04:21 AM
Hello Oksavik,
Try reinstalling NI-VISA server on remote device (cRIO)
06-29-2018 04:42 AM - edited 06-29-2018 04:44 AM
@Ben@Ben wrote:
The last time I saw that problem it was the port number.
Another process had grabbed the port and since it was not running Modbus, it refused the connection.
Ben
Hello, and thank you for the reply.
Do you mean the serial port? With Modbus RTU I connect to the instruments "Unit ID" on the "VISA resource" (ASRL3). When you say port it makes me think of an TCP port being occupied.
I can restart the cRIO and have the same issue. Could something occupy ASRL3 on startup, and not be released?
Also it's during the first "Read" I'm getting the error. The "Create Master Instance" is not giving an error. I would assume that opening the connection to the serial device would give an error if it was already in use?
06-29-2018 04:46 AM
@_Bryan wrote:
If the software has not changed it is most likely hardware. Did you do any updates or program changes lately?
Do you have a program from the manufacturer that you could use to try and communicate with the devices without using LabVIEW or MAX? Of course, more information would be very helpful. But if you can connect directly to the instrument with the manufacturers program and it works, then you need to find the issue between there and the cRIO causing the issue. It could be a broken wire or a loose connection, but since we know nothing about your setup it is hard to say.
Thank you for your reply.
This is a good idea, if I'm not able to make any progress I will see if we can communicate with them using a manufacturers program. Not sure what exists.
Not certain about any changes, there are many parties working on different parts of the system, and I'm not always up to date. 🙂
06-29-2018 04:48 AM
@kartiknattar wrote:
Hello Oksavik,
Try reinstalling NI-VISA server on remote device (cRIO)
Thank you. This will be my last resort, and I expect it would fix the issue.
Still, I would like to know why it occurred, and if it could be avoided in the future.
07-16-2018 05:51 AM
Hello again,
I'm not making any progress on this problem.
In the end I decided to stop wasting time, formatted the cRIO and installed software again.
To my surprise the problem remains.
I will have to investigate the different instruments, to determine if one of them is causing problems.
These are multiple instruments connected using RS485, and I guess if one is malfunctioning maybe it affects the others.
07-16-2018 06:22 AM - edited 07-16-2018 06:24 AM
If multiple instruments are connected then make sure that each instrument have a unique slave id. First start with just one instrument and then try to increase the device. Make sure the polarity is of the device is properly assigned to the terminals.
07-17-2018 01:54 AM
@Oksavik wrote:Error opening resource: visa://123.234.345.123/ASRL3::INSTR
Just to be sure: You changed the host address shown here to a random IP, right?