09-21-2007 11:36 AM
09-21-2007 11:45 AM
What is commport.dll and where did you get it? And why aren't you using the LabVIEW functions to write to a com port?
You also didn't include the HexStr2BinStr subVI so no one can run the VI.
09-21-2007 11:58 AM
I got the commport.dll from someone in the lab. I assumed it was from NI - it does give me some sort of nag screen about registering. I attached it.
Where are the NI comm port routines? I didn't see any when I bring up vi's on the sidebar - just the normal stuff with structures, numeric, boolean, etc.
I think I attached all the sub-vi's. Somebody else wrote this thing. If there are more, let me know what they are called and I'll track them down. But for now the attachment window limits me to three attachments (GRRRR!)
09-21-2007 12:21 PM
09-21-2007 01:32 PM
OK - I am trying the NI drivers. Unfortunately, I'm not getting much of anywhere. I got this error:
-1073807298
The hardware is all hooked up properly, I know it is capable of communication.
09-21-2007 01:40 PM
You just can't drop a VISA Write into the middle of your other code. For one, the os only allows one process to access a port. That means you can't have your comport.dll process access it along with VISA. You could not have Hyperterminal running at the same time as comport.dll (unless it is comport.dll that Hyperterminal is using) either. You also need to wire a VISA Resource Name control or constant to a VISA write. This is what tells VISA which port to use.. You also have to have something actually wired to the write buffer input of VISA Write.
Open the example finder and do a search for serial. You will find both a basic and advanced example. Please note that the examples are designed to send ASCII characters. It's not clear to me if that is what you really need to do. The missing subVIs might explain that. If you need to send hex, what you should do with the basic example is right click on the string control for the data to write, and select Hex Display.
09-21-2007 01:53 PM
I attached a Visa resource name - it is COM5: on my system. I opened the basic serial read / write example on your site - but it is not writing to COM5: for some reason. No bits toggle on the interface when I run it.
I have a bit of a problem with the basic read /write example anyway - in its serial port setup routine it assumes standard RS-232 stuff. For example - stop bits of 1, 1.5, and 2. I am trying to control a proprietary interface that has write bit - low, followed by a mode bit, low, then an 8 bit address followed by 16 bits of data, then four dummy bits. For read, I set the first bit low, then a mode bit low, 8 bits of address, 4 dummy bits, then 16 bits of read data coming back from the device. Nothing standard about it at all. So I need something that can bang those bits, just as I want them, to the serial port and then read the bits coming back on a read. If I leave out that RS-232 setup block on the example, can I accomplish what I want to do? And why am I not seeing any bits toggling at all when I use the basic serial port write / read example? I would at least expect it to send bits out to COM5: once I select the port, even if the bits aren't what I want - they should still be toggling.
09-21-2007 01:55 PM
Additional info - I get this error:
Error -1073807298 occurred at VISA Write in Basic Serial Write and Read.vi
09-21-2007 02:14 PM
09-21-2007 02:33 PM
You can add the TI TUSB3410 to the list of incompatible devices. Unfortunately, changing devices is NOT an option for me - as the TI device is soldered down on the board I am trying to test. Changing devices would entail buying a retail product (Not easy in the corporate environment here) - taking it apart, and jumpering data lines from that device to our board. Not impossible - but if possible -
Is there a software workaround that will purge the buffer - a .vi or something that I can drop in to make this thing work?