03-13-2013 09:15 AM
Hi,
I'm having problems communicating with a Pollux box controlling a stepper motor (both from Micos). The Pollux box has an RS232/485 connection to the computer.
I have tried adaptations of LV's Basic Serial Read and Write example. Even for the basic example there has never been any bytes at the serial port after the write.
I have attached some sample code for LV 10.0.1(64bit) and the OS is Windows Server Enterprise 2008.
The Visa drivers have just been installed.
After some research I have added a 'Set I/O buffer size' as advised by http://digital.ni.com/public.nsf/allkb/60DDFED7EFEFE7188625705700750821?OpenDocument
The time-out is set to 10s, I have a wait of 1s before read and 0.5s between each write (the characters are written individually incase that was the problem).
The write command getaxisno_ should reply with the default axis no which is 1. However, there is never any reply.
The termination character for Venus2 is a space for transmitting commands and ASCII CR LF at the end of received data.
I'm not sure what else could be wrong. According to MAX the device is working properly. Although, when I try to open a Visa test panel in MAX the program crashes. I'm not sure if this is a related problem.
I'd be really grateful for any advice, have been trying to fix this for a few days now.
Thanks in advance!
Ciara
03-13-2013 09:18 AM
03-13-2013 09:29 AM
Unfortunately Windows Server 2008 doesn't seem to have Hyperterminal and I can't seem to find an equivalent.
03-13-2013 09:32 AM
Do a search for Putty and see if that will install. There are so many things that could be wrong - com settings, wrong cable, and perhaps the termination character is wrong. Explain exactly what you mean by 'the program crashes'.
03-13-2013 09:32 AM
03-13-2013 09:38 AM
Thanks, I'll search those now.
When I click the test panel button, the Max window disappears and the program is closed. Next time I open it an Unexpected Error box opens with a message saying there was an unexpected error and I should search Info Code MAXKnownException.
'The exception occurred in the NIMax process in the function (Unknown).'
I have searched this and the info advised me to send a report with log files etc to NI which I have done. Just waiting on the reply.
I copied the Visa resource name from MAX and the termination character is the same as what a previous owner of the equipment used in Visual Basic.
03-13-2013 09:58 AM
ZOC is a powerful terminal program that allows to set any kind of parameter set and terminal emulations for serial connections. I think not the current but older versions are free. Look at:
http://www.emtec.com/download.html?what=zoc#zocfiles
Cheers
Edgar
03-21-2013 02:49 PM
Just to update - I tried using Hyperterminal and couldn't communicate. Turned out the wire was faulty! Labview now working fine with the device.
Many thanks for all your advice. 🙂
Ciara