scottmurphy
Member
- Join Date
- Oct 2004
- Posts
- 363
Does anyone out there have any experience with trio motion for servo controllers. I have an application that I want to modify, but want to get some decent background before I proceed.
start:
WAIT UNTIL IN(1)=0
WAIT UNTIL IN(1)=1 'look for the leading edge of the position reference
MOVELINK(15,30,30,0,1,1) 'ramp up to match speed
MOVELINK(175,175,0,0,1) 'match speed for the remainder of the move
WAIT LOADED 'when second MOVELINK is loaded, this means that we are 'at speed'
OP(9,ON) 'turn on an output to indicate axes are synchronized
MOVELINK(15,30,0,30,1) 'decelerate to the end of the move
WAIT LOADED 'when the decel MOVELINK is loaded, this means we are decelerating
OP(9,OFF) 'turn off output
WAIT IDLE 'wait until motion is done
WA(100) 'wait a bit more
SPEED=500 'set return speed
ACCEL=3000 'set return accel
DECEL=3000 'set return decel
MOVE(-205) 'move to starting position
WAIT IDLE 'wait until starting position is reached
GOTO start 'return
With the idle mode bit off, the servo still runs at line speed.Replace IF READ_BIT(idlemode,digitalinputs) = 1 THEN
With IF READ_BIT(idlemode,digitalinputs) = 1 AND IN(x)=1 THEN
How do I know that VP_SPEED is read only, is this becauseNotice that VP_SPEED is 'read only'
No, because it states it in the manual...scottmurphy said:How do I know that VP_SPEED is read only, is this because
of the IF statement, it is only looking at this variable?
The commands above the wait_input are only processed on the first scan. So now the CONNECT command is examined based on conditions instead of always executing.SERVO = ON
CLUTCH_RATE = 200
CONNECT (connect_ratio,1) 'Th
PRINT connect_ratio
wait_input:
shadeidle = VR(idlespeed) / 16.68
IF READ_BIT(9,digitalinputs) = 1 THEN
CONNECT (shadeidle,1)
ELSE
CONNECT (connect_ratio,1)
PRINT connect_ratio
ENDIF