WLSP Set and wait event when the slave’s positive limit switch (LSP) goes low or high |
Syntax
Binary code
The programmed event is automatically erased when the event occurs or if the timeout for the wait expires.
Example //Reverse slave C when positive limit switch is reached //Position feedback: 500 lines encoder (2000 counts/rev) (C) CACC = 0.0637; //acceleration rate = 200[rad/s^2] CSPD = 16.6667; //jog speed = 500[rpm] MODE SP; UPD; //execute immediate } // Wait for event : When axis C positive limit switch goes low->high WLSP1 (C); // Wait for event : When motion is completed on axis (C) WMC (C); //limit switch is active -> quick stop mode active // wait until the motor stops because only then the // new motion commands are accepted (C) CSPD = -40; //jog speed = -1200[rpm] MODE SP; //after quick stop set again the motion mode UPD; //execute immediate }
|