User Manual

Table Of Contents
Runtime Queries
Advanced Digital Motor Controller User Manual 225
Syntax Scripting: result = getvalue(_FM, cc)
result = getvalue(_MOTFLAG, cc)
Reply:
FM = f1 + f2*2 + f3*4 + ... + fn*2n-1
Type: Unsigned 16-bit Min: 0 Max: 255
Where:
cc = Motor channel
f1 = Amps Limit currently active
f2 = Motor stalled
f3 = Loop Error detected
f4 = Safety Stop active
f5 = Forward Limit triggered
f6 = Reverse Limit triggered
f7 = Amps Trigger activated
Example:
Q: ?FM 1
R: FM=6 : Motor 1 is stalled and loop error detected
Note:
f2, f3 and f4 are cleared when the motor command is making the motor idle (e.g. 0 in
closed loop speed). When f5 or f6 are on, the motor can only be commanded to go in the
reverse direction.
FS - Read Status Flags
Alias: STFLAG HexCode: 14 CANOpen id: 0x2111
Description:
Report the state of status flags used by the controller to indicate a number of internal
conditions during normal operation. The response to this query is the single number for all
status flags. The status of individual flags is read by converting this number to binary and
look at various bits of that number.
Syntax Serial: ?FS
Argument: None
Syntax Scripting: result = getvalue(_FS, 1)
result = getvalue(_STFLAG, 1)
Reply:
FS = f1 + f2*2 + f3*4 + ... + fn*2^n-1 Type: Unsigned 16-bit Min: 0 Max: 65535
Where:
f1 = Serial mode