From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Control Newport XPS Q8 linear translation stage

Hello all!!

 

I am trying to control the XPS Q8 linear translation stage (300mm) through labview 11. I constructed a VI which communicates my translation stage and moves according to target position which I set.  For your reference I have attached my VI.

 

Present VI runs the translation stage towards the target position continuosly. Once it reaches the target position, the program will end.

 

Now I need to modify my VI such that stage should moves towards the target position with some time interval instead of running continously.

 

for example, my target position is to reach 100 mm and I need to stop the stage at every 5 mm for 5 sec.

 

1 to 5mm with velocity 1 mm/s and stay at 5mm for 5 sec,

Again 5 to 10 mm with velocity 1 mm/s and stay at 10 mm for 5 sec.

Again 10 to 15 mm with velocity 1mm /s and saty at 15mm for 5 sec.......like this.

 

could you please help to modify my VI.

0 Kudos
Message 1 of 11
(5,129 Views)

Hi,

I used this Control. To know if stage move is finished, I used the VI "Single Axis Group Motion Status Get" and analyse the out value of motion.status.

You must read the documention about this VI.

1. Set Speed 1 mm/s

2.Start relative Move of 5 mm

2 Get and Analyse the Status until Status value is Ready

3 Waiting user time

4. Last move  Yes :Goto point 2 No : goto ppoint 5

5. End

 

Use the State Machine Framework to code this.

 

Best regards.

Message 2 of 11
(5,111 Views)

Thank you for your reply sir

 

In relative move, what is the value i should give in " target displacement"? Target position value( 100 mm) or interval value (5mm).

 

then how to give waiting time??

0 Kudos
Message 3 of 11
(5,103 Views)

Hi,

Yoiu can also make an absolute move.

Iterate in a loop

1. initial position 0mm

2; Counter = 1

3. Move absolute to Counter * 5

4. Wait standby using Get axis Status

5 Wait 5 seconds

6 Increment counter

6 Counter* 5  > 100 ? Yes : Goto point 7 NO : Goto point 3

7: End

 

I recommend again to use the State Machine Framework to code this.

Best regards.

 

Message 4 of 11
(5,094 Views)

Sir, could you please explain me about state machine framework. I am not aware of that.

0 Kudos
Message 5 of 11
(5,089 Views)

You can find help on NI Forum.

To start you can create a new LV project using the template of standard State machine.

tutorial at this link : http://www.ni.com/tutorial/7595/en/

In other case you can use a simple while loop,

 

Best regards.

 

0 Kudos
Message 6 of 11
(5,083 Views)

I could not find " get axis status". Is it " group status get"?

 

 

0 Kudos
Message 7 of 11
(5,078 Views)

I use  "Single Axis Group Motion Status Get"

and that analyze the motion status value: See documentation about the value.

Best regards.

0 Kudos
Message 8 of 11
(5,071 Views)
Sir, i am confused. Could you demonstrate using block diagram.
0 Kudos
Message 9 of 11
(5,067 Views)

Sorry ,

I have no time acutally to do this.

I recommend you to read the manual at first ( Single axis section),

For my code I used Classes to wrap all necesary VIs to do my functions.

 

Start to code A VI with absolute move and then a while lopp with GetGroup Status to see the value.

 

Sorry again best regards.

0 Kudos
Message 10 of 11
(5,061 Views)