Motion Control and Motor Drives

cancel
Showing results for 
Search instead for 
Did you mean: 

To control motorized worm drive rotation stage using TDC001 controller using ActiveX

Hi.,

  

  I need to control two servo motors using thorlab's tdc001 controller with xy stage under certain conditions using ActiveX in labview

 

1. syncronize two motors (execute @ the same time).

Case: 1

     To move the motors in the same direction and reverse back, [if i give 5degree (0 to 5) and (5 to 0) ] and the process goes on continuously(loop).

Case: 2

      To move in the opposite direction.[5degree means: one is (0 to 5) and the another is (0 to -5)]

Case 3:

     To move the motors in the same direction but one is extra distance from the other for every iteration (for stretching purpose)and  it's also in a loop

 

Here i attached  an image for controlling the single motor without any conditions but i need is two motors with the above conditions

0 Kudos
Message 1 of 3
(4,118 Views)

Hi pranav8991,

 

Thanks for posting here about using your Thorlab's TDC001 controller with LabVIEW! At first glance it looks like you have a good start on getting up and running with LabVIEW, but seeing as this isn't an NI product, would you mind posting the user manual for it? I'm looking at the property nodes you're calling and not positive on what each of the methods does.

 

I looked at the VI you posted over at http://forums.ni.com/t5/LabVIEW/Hi-I-m-using-TDC001-controller-with-CR1-M-Z7-motor/m-p/3275557 and I see generally what you're doing, but I would also need the Return Code Insertion Vi to see the details of your move commands. Can you post that here?

 

As far as larger architectural questions, the current structure you have of starting control and then entering a while loop and sending commands via the Invoke nodes. I would recommend grabbing the reference to each motor (with two different controls) and initializing them separately, as well as homing them outside of the while loop. Then, you can send both references into the while loop and use invoke nodes in parallel to move motors whatever directions you want. I would recommend using a producer consumer architecture or a state machine (examples below) to accomplish this.

 

https://www.ni.com/en/support/documentation/supplemental/16/simple-state-machine-template-documentat...

https://www.ni.com/en/support/documentation/supplemental/21/producer-consumer-architecture-in-labvie...

 

Hope this helps!

Austin H.
Product Manager
NI Test Software
0 Kudos
Message 2 of 3
(4,058 Views)

Thanks for your kind response.

Using those manuals i created the vi-s...

0 Kudos
Message 3 of 3
(4,045 Views)