03-12-2014 01:37 PM
I have a small program (attached) that seems to be reading data sometimes. I have a lens controller attached to the program through an RS232-USB adapter. When the lens controller boots up, it will give it's name and model number and some other information, and all of that stuff is read properly to the program. I am also able to send information to the controller with the write buffer box and Boolean button (to send). The lens controller responds to my commands by moving motors. When I send a command to ask "where are you," I don't get the answer back. I do the same thing in UCON and it works, so I know the controller is speaking. Anybody see something I am missing?
03-12-2014 01:52 PM
Your reading and writing is acting in parallel. You should send the command requesting the status, wait so long for the unit to respond, and then read the status. I also see that you are setup to use the termination character. With that on, you don't need the Bytes At Port property node in there. Just tell the VISA read to read some huge number of bytes. The read will stop when the termination character is read.