03-14-2023 04:26 AM
Hi all,
I am trying to read the data off a Tektronix MSO4 series oscilloscope using SCPI commands and i am always coming up with different error codes. The two I get are -1073807331, and -1073807399. I believe these codes are relating to timeout/ communication issues with the scope.
Also along with the read area the write commands are only working some of the time, I am ensuring the visa session is closed after each run through.
I have attached the VI below, let me know if you need any more info.
Cheers
Solved! Go to Solution.
03-15-2023 09:15 AM
Hi apowell17,
Both first and second errors have proper solution articles. I have attached them below, try to go through that articles to solve this issue.
Regards)
03-15-2023 11:56 AM
You're using "Bytes at port" property nodes which are supposed to be only for Serial communications when you're using a USB device address.
Even if you were using a Serial device, 99% of the time you shouldn't use "Bytes at port". If you don't know what to wire to the "Bytes to read" input, just try a large number (1000). You may need to set up VISA to use a termination character, in this case an LF.
Also you're using a "VISA Clear" when you probably want to use "Flush buffer"
The MSO4 series should have an Ethernet port with LXI, can you use that instead of USB? I find it much more reliable.
Have you tried or looked at the premade drivers?:
Even if they are missing a function you need, using them can prove that communication works and will give you a template of sorts you can follow to create your own, working, VIs.
03-15-2023 07:41 PM
The MSO4 series should have an Ethernet port with LXI, can you use that instead of USB? I find it much more reliable.
I can't agree more about this point. the communication seems always stop when connected with USB while LXI is ok.
03-16-2023 03:12 AM
Hi all,
Thank you very much for your help. Will try a few of these solutions today and let you know how i get on.
Cheers
Alex
03-16-2023 07:14 AM
@yeah wrote:
The MSO4 series should have an Ethernet port with LXI, can you use that instead of USB? I find it much more reliable.
I can't agree more about this point. the communication seems always stop when connected with USB while LXI is ok.
I have a general rule of avoiding USB whenever possible. My order of preference for instrument communications is Ethernet (ie LXI), Serial (RS-232 or RS-422), GPIB (mostly due to cost), and finally USB. If I do have to use USB, I'm using a commercial grade externally powered USB hub. I do not trust USB hubs on motherboards.
03-16-2023 07:59 AM
So the issue is now fixed, since i removed the 'bytes at port' for a constant and removing the 'visa clear' it is seeming to solve the issue and i am not getting any more errors
At the moment i am still using USB, but am looking to use ethernet instead after the advice from everyone, as i have had a few reliability issues with usb cross multiple instruments.
03-16-2023 12:13 PM
@apowell17 wrote:
At the moment i am still using USB, but am looking to use ethernet instead after the advice from everyone, as i have had a few reliability issues with usb cross multiple instruments.
Some advice for when using TCP:
1. Have a private network dedicated to instruments.
2. If you need internet access on your computer, use a second NIC.
3. Use a good Ethernet switch. No real need for a full up router, but you still don't want a cheap switch/hub.
4. Used fixed IP addresses. This just helps sooo much for setting up and debugging, especially if you standardize your IP addresses across programs.
03-16-2023 01:44 PM
@crossrulz wrote:
3. Use a good Ethernet switch. No real need for a full up router, but you still don't want a cheap switch/hub.
Got any specific recommendations for what constitutes a good switch, or which ones you prefer?
03-16-2023 02:06 PM
At my company we've found that the best "switch" is no switch at all, but rather we just add on extra Ethernet ports to the PC and connect all of the equipment to the PC directly.
There are some drawbacks, i.e. you have to know which PC port connects to which device, you have to manage the IP settings for all the ports, but overall it works great for us.