LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

animatics smartmotor

I have a couple of animatics smartmotors (sm23165d) daisy-chained.

 

I successfully connected them to Labview using an RS232 serial port connection with the help of this forum ! Thank you 🙂

 

I can write commands to the motor in realtime using labview now. But my major problem is reading the position of the motor !

I got to know that there has to be some delay between the 'read' command and actually reading the value..........i tried to do it using a simple and a little complex way (attached)

 

I have the following problems:

1) How can I read position in realtime ?

2) When I give the read command in 'visa write' and then after a delay, I use 'visa read' to read, I get all my commands sent back through the buffer and then, at the end, there's the value of position. What do I do to get only the position in the buffer ? I tried using the ECHO_OFF but that didn't help; instead, as soon as I wrote ECHO_OFF just before RPA to read position, my daisy chaini stopped working i.e. motor 2 on the chain stopped getting commands even when addressed properly (I dont know a lot about ECHO, what iit means, how it's meant to be used, where in the code are you supposed to write it etc.)

 

These forums have been to the point and really helpful until now.

It would be great if someone could please help me with this.

 

Thanks.

Download All
0 Kudos
Message 1 of 2
(2,935 Views)

Hi dssiitb,

 

I have a couple of suggstions:

 

1) Try to find LabVIEW drivers for the animatics motors you have and use those in your code.

2) Use the "Query" command in VISA as it writes and reads so might reduce the delay. 

0 Kudos
Message 2 of 2
(2,802 Views)