08-11-2008 10:23 PM
08-12-2008 02:39 PM
08-12-2008 11:46 PM
Hi
I have had another look at the program today (changing it slightly) and have found that it will write and read to the motor twice (with and without a time delay) but the problem seems to be writing the string that was read back to the motors.
What happens is the string is read from the motor, the first integer in the string is then changed to a "O" and this is written to the motor and errors occur. If instead a constant or even a control is attached to the second write the program will work fine.
Is there some "trick" I need to use to feed the string from one to the other?
Thanks
Nicola
08-14-2008 01:34 PM
Hi Nicola,
Please take an NI-Spy capture, as suggested in the previous post. It will help us determine what communication is happening and let us be able to troubleshoot more efficiently.
Also, as your VI has custom subVIs that I do not have access to, posting your code does not help.
Thank you,
Meghan R
Applications Engineer
National Instruments
08-14-2008 10:33 PM
Hi
I have attached two NI-spy catures. The first is the program running when the output from the first read is connected to the second write and is when the error occurs. The second is when a constant is input to the second write and no error occurs. It seems that in the first case the number of bytes constantly increases.
The second code that I posted contains no custom subVIs and was a simplification of the first.
Thanks
Nicola
08-15-2008 03:51 PM
Hi Nicola,
It looks like your code is working exactly the way you've written it to work. Either your "replace substing" subVI works differerntly than you expect it to, or your motor is returning information you're not expecting. Contacting your motor manufacturer should be your next step to verify the operation of the motor.
If you need further help, please contact National Instruments support by going to ni.com/ask and talk to an Applications Engineer. Make sure you reference this discussion forum thread.
Thanks!
Meghan R
Applications Engineer
National Instruments