Digital I/O

cancel
Showing results for 
Search instead for 
Did you mean: 

transceiver control during boot

Is there a way to configure the NI USB 485 single port USB converter to retain  2-wire auto tranceiver control during boot?  This is sometimes refered to as "Tri-state" on boot by other serial interface vendors. 

When ever the host PC with the USB converter preforms a cold boot, all the other slaves on the network are reset breifly. 

This does not occure during a warm boot. 

I susspect the reset is caused when the OS loads the driver, changing the transceiver control from its default value to 2-wire auto mode. 

Thanks in advance for you help!

  

0 Kudos
Message 1 of 9
(4,020 Views)

Tgog,

 

I'll have to research into this issue a bit before I can provide you with an adequate response.

 

Also, just a question on nomenclature, when you say cold boot, is this referring to when you manually turn off your PC without going through any shutdown procedure, and when you say warm boot I'm assuming that's when you go through Windows (or whatever OS you're using) to shutdown? Thanks

Justin E
National Instruments R&D
0 Kudos
Message 2 of 9
(3,995 Views)

Hello Justin_E,

Thanks for looking in to this for me.

 

A hard reboot (also known as a cold reboot, cold boot or cold start) is when power to a computer is cycled (turned off and then on).

 

A soft reboot (also known as a warm reboot) is restarting a computer under software control, without removing  the power.

 

Hopefully these definition will clear up my wording.  

 

 

 

 

0 Kudos
Message 3 of 9
(3,982 Views)

Hey Tgog,

 

I have a couple questions for you regarding this issue. Is the USB-485 device the master device in the system? How exactly is your network set up? When your machine reboots and you check the device in Device Manager, does it still show up as 2-wire auto? Are the slaves resetting a major issue for your system?

 

Also, do you have any other RS-485 cables/devices you can test this with, or even a different USB-485? What version of NI-Serial do you have on your machine? I know I'm throwing a lot of questions at you, but there could be a variety of things going on with this device.

Justin E
National Instruments R&D
0 Kudos
Message 4 of 9
(3,971 Views)
Hello Justin_EHere are my answers to your questions on this, again thanks for taking the time to help me out with this.    The USB device is set up as a slave in our application.  The 485 network is in our case wired as 4-wire multi drop full duplex.   I know what you are thinking, I am getting the transceiver controls mixed up. I am using 2-wire mode in a 4-wire topology.  I have tried using 4-wire mode on the USB without success.  I think in 4-wire mode the USB device is assumed to be a master device.  If I am not correct with this assumption is there a way to configure the USB as a slave in 4-wire mode?  I have found by experimenting, that this device wired as a slave in a 4-wire full duplex multi-drop network, and setting the transceiver control to 2-wire auto works fine with exception to this issue in our network.       Our network may contain up to 3 additional slave nodes with one of the nodes being a receipt printer.  So yes, having the USB slave reset or interrupt the network can cause a major issue for me.  When windows starts we can check the port status in device manager and it will show 2-wire auto mode.  What I suspect is this, the firmware on the NI USB interface defaults to some other transmission mode.  This mode gets set to 2-wire mode once the windows driver (NI serial core version 3.4) takes control of the port.   Again my question is can the NI USB be configured to retain 2-wire auto as the default mode?   Can the firmware on the USB device be flashed to make this mode the default?      We have used several other PCI/PCI express RS-485 devices in this network with out problems.  My goal is to migrate to a smaller from factor PC chassis by using the NI USB interface.  I am planning on purchasing 450+ of these units in the near future if I can get this problem sorted out.  Hopefully you can help me out.   
0 Kudos
Message 5 of 9
(3,948 Views)

Hey Tgog,

 

I'd like you to try something for me. Can you unplug the USB-485 and plug it back in while the computer is running, and see if the same behavior is exhibited?

 

I think that the firmware for the USB-485 is downloaded to the device upon detection. What you're saying could be true where the USB-485 defaults to some mode before the device is detected by the driver and the firmware is loaded to the device. I'd like to see what happens though when the device is unplugged and plugged back in to the machine.

Justin E
National Instruments R&D
0 Kudos
Message 6 of 9
(3,936 Views)

Hey Justin_E

I tried unplugging the USB-485, then plugging it back in.  I can see in windows device manager the port disappears then reappears once its plugged back in.  It is Interesting, the same behavior is not exhibited when a hard boot is preformed.  Although my application does not re-detect the port once its plugged back in.  I can restart my app and it will connect to the port again. 

 

So the USB-485 must retain its configured mode even through a power cycle?

 

good call! 

 

I guess I need to look at how windows loads the port different on a hard boot?   

 

 

0 Kudos
Message 7 of 9
(3,929 Views)

Tgog,

 

It looks like it's either an issue with how Windows loads the port like you said, or how Windows loads the driver, or possibly even a combination of both. 

Justin E
National Instruments R&D
0 Kudos
Message 8 of 9
(3,912 Views)
Thanks for your help with this Justin_E.
0 Kudos
Message 9 of 9
(3,910 Views)