4MELFA-BASIC IV
Detailed explanation of Robot Status Variable
4-280
M_Fbd
[Function]
Returns the difference between the command position and the feedback position.
[Format]
[Terminology]
<Numeric Variable>
Specifies the numerical variable to assign.
<Mechanism Number>
Specify the mechanism number 1 to 3. The default value is 1.
[Reference Program]
1 Def Act 1,M_Fbd>10 GoTo *SUB1,S
' Generate an interrupt when the difference between the
command position and the feedback position reaches 10
mm or more.
2 Act 1=1
' An interrupt takes effect.
3 Torq 3,10
' Set the torque limit of the three axes to 10% or less using
the torque instruction.
4 Mvs P1
' Moves.
5 End
;
10 *SUB1
11 Mov P_Fbc
' Align the command position with the feedback position.
12 M_Out(10)=1
' Signal No. 10 output
13 Hlt
' Stop when a difference occurs.
[Explanation]
(1) This function returns the difference between the command position specified by the operation instruction
and the feedback position from the motor. When using the torque instruction, use this in combination
with a Def Act instruction to prevent the occurrences of excessive errors (960, 970, etc.).
(2) This variable only reads the data.
[Reference]
Example) <Numeric Variable>=M_Fbd[(<Mechanism Number>)]