WAMPU        Set and wait event when the slave’s motor absolute position is equal or under a 32-bit value or the value of a long variable

Syntax                        

WAMPU (Slave), value32

Wait for slave’s Absolute Motor Position Under value32

WAMPU (Slave), VAR32

Wait for slave’s Absolute Motor Position Under VAR32

 

OperandsSlave: slave axis monitored for event occurrence

VAR32: long variable

value32: 32-bit long immediate value

PlaceTMLOnline

Binary code

WAMPU

DescriptionSets the event condition and halts the execution of the TML program from motion controller until the slave’s motor absolute position becomes equal or under the specified value or the value of the specified variable. After you have programmed an event, you can do the following actions:
Change the motion mode and/or the parameters when the event occurs, with command UPD!
Stop the motion of slave axes when the event occurs, with command STOP.

The programmed event is automatically erased when the event occurs or if the timeout for wait expires.

 

ExecutionActivates the monitoring of the event on the slave axis, when motor absolute position <= value32, respectively VAR32. The motion controller application remains in a loop until the event on the slave axis occurs or it timeouts. This operation erases a previous programmed event that has occurred.

 

Example        

//Stop slave B and C when the motor position <= -3 rev on slave A

//Position feedback: 500 lines encoder (2000 counts/rev)

// Wait for event : When axis A motor absolute position is

// equal or under value -3 rot

WAMPU (A), -6000L;

(B,C) {

   STOP; // Stop motion with acceleration / deceleration set

}