04-25-2011 02:16 PM
I installed the SMI (smart motor interface) software that comes with the motor. That works well enough, as soon as I start the software and plug in motor I can type in the SMI's ASCII command:
EIGN(2) 'Remove motion Limit
EIGN(3) 'Remove motion Limit
ZS 'Clear Errors
ADT=100 'Acceleration Limit
VT=450000 'Velocity Limit
PT=300000 'Position Destination
G 'GO
I want to use LabView to command the motor. My assumption was to make a VI that did serial communication and send the same ASCII syntax commands via serial write, etc. See attached VI.
I get no reponse, I have no idea what is going on, OR what I am really doing for that matter...
Is this possible and the right direction? Can I not use SMI and instead just use LabView serial write/read commands to communicate with it? Or is the SMI software doing other tricks behind the scene I am unaware of?
I'm a novice.
04-26-2011 05:48 PM
Hey krenik22,
The first thing that we should check would be to make sure that you have the VISA driver downloaded.
Depending on your version of LabVIEW, you can get the driver here.
The LabVIEW compatibility sheet for the VISA driver can be found here.
If you do indeed have that downloaded, then the next thing to check would be to make sure you are using the correct termination characters for your device. You will be able to find this in the manual for your Smartmotor. The SMI software most likely knows that termination characters to use.
Also, there is an example already created in LabVIEW that will do serial reads and writes. You can find it by going to Help >> Find Examples... >> Hardware Input and Output >> Serial >> Basic Serial Write and Read.VI.
I hope this helps!
Kim W.
04-28-2011 12:47 PM
Hi krenik22,
You can also get free serial sniffer download and use that to verify the ASCII string command sent out of the serial port.
Minh
Animatics
Sr. Applications Engineer
04-28-2011 01:53 PM
Duplicate post, solution here:
http://forums.ni.com/t5/LabVIEW/Animatics-Smartmotor-Novice-Needs-Help/td-p/1537312
Please refrain from duplicate posting or at least provide a link to them.
-AK2DM