Skip to content

set parameter oplet

JamesNewton edited this page Jun 4, 2019 · 102 revisions

High level Parameters in the Dexter Firmware are set with the "S" Oplet. For direct control of low level FPGA parameters, see the "w" Oplet

# Name Default / Range DDE / Socket Units Socket Type Description
0 MaxSpeed 30 / 0.001-45 deg/s / nbits integer Maximum velocity of next move in "nbits"1. Default is 250000. See also StartSpeed below.
1 Acceleration 0.0001 / 0.0001 - 0.1 deg/s2 / nbits integer Maximum acceleration of next move in "nbits"1. Default is 3.
2 J1Force How hard each joint tries to return to commanded position in force protect modes
3 J3Force
4 J2Force
5 J4Force
6 J5Force
7 J1Friction 5 / 0-50 unitless fixed point? 2 The friction felt during FollowMe mode
8 J3Friction 5 / 0-50 unitless fixed point?
9 J2Friction 5 / 0-50 unitless fixed point?
10 J4Friction 15 / 0-150 unitless fixed point?
11 J5Friction 15 / 0-150 unitless fixed point?
12 J1BoundryHigh 180 / -180-180 deg / arcsec integer Set all Boundaries at once with "B" Oplet
13 J1BoundryLow 180 / -180-180 deg / arcsec integer
14 J3BoundryHigh 180 / -180-180 deg / arcsec integer
15 J3BoundryLow 180 / -180-180 deg / arcsec integer
16 J2BoundryHigh 180 / -180-180 deg / arcsec integer
17 J2BoundryLow 180 / -180-180 deg / arcsec integer
18 J4BoundryHigh 180 / -180-180 deg / arcsec integer
19 J4BoundryLow 180 / -180-180 deg / arcsec integer
20 J5BoundryHigh 180 / -180-180 deg / arcsec integer
21 J5BoundryLow 180 / -180-180 deg / arcsec integer
22 GripperMotor 0/0-1, 0/0-12000, 0/0-12000 ON/OFF, ON_PWM, OFF_PWM bool, int, int Set PWM output on J19 1st parameter starts PWM with 1, stop with 0. After 2019/05/23: 2nd parameter is PWM on time, 3rd is off time. See W commands 73 - 74.
23 EERoll 512 / 0~1023 deg / 0.29*deg 6th axis position / Tool Interface Roll (was standard servo, May 29,2018 changed to Dynamixel)
24 EESpan 0 / 0~1023 deg / 0.29*deg 7th axis position / End Effector actuation (was standard servo, May 29,2018 changed to Dynamixel)
25 StartSpeed Velocity at start (and currently, the end as well) of the next move in "nbits"1
26 EndSpeed (not implemented) Currently StartSpeed is the speed for both the start and end of each move.
27 ServoSet2X Address, Register, Value (as of 2018/05/29 was "End") see: Servo
28 ServoSet
29 RebootServo 2018/05/29
30 RunFile FilePathName 2018/10/12 If it exists, the file will be opened and all instructions from it parsed and executed. By convention, files end with .make_ins extension. Each line should be one instruction just like any sent over the socket connection (the job, instruction, start, and end time values are NOT included; start with the oplet). A sample line might be
S J1_PID_P 0.2 ; set base drive
Anything after a ';' is ignored allowing comments.
Was 2018/08/24 "Ctrl" parms/values for compact setting of values related to operational mode but this was depreciated and replaced with RunFile.
31 J1_PID_P 0.2 / 0 - 1 unitless float Float Oct 12, 2018 Set Joint PID P with a floating point number. Helps with Issue #33
32 J2_PID_P 0.2 / 0 - 1 unitless float
33 J3_PID_P 2 / 0 - 4 unitless float
34 J4_PID_P 0.1 / 0 - 0.5 unitless float
35 J5_PID_P 0.1 / 0 - 0.5 unitless float
36 AngularSpeed 30 / 1 - 45 deg/s / arcsec/s integer Speed to ramp up to at given acceleration. Same as MaxSpeed but with human readable units.
37 AngularSpeedStartAndEnd 0.1 / 0 - 45 deg/s / arcsec/s integer Speed to ramp up from and down to. Same as StartSpeed but with human readable units.
38 AngularAcceleration 0.1 / 0.0003 - 0.1 deg/s2 integer
39 CartesianSpeed 300000 / 10000 - 500000 micron/s integer
40 CartesianSpeedStart 0 / 0 - 500000 micron/s integer
41 CartesianSpeedEnd 0 / 0 - 500000 micron/s integer
42 CartesianAcceleration 1000000 / 0 - 500000 micron/s2 integer
43 CartesianStepSize 10 / 1 - 10000 micron integer
44 CartesianPivotSpeed 108000 / 1 - 360000 arcsec/s integer
45 CartesianPivotSpeedStart 0 / 1 - 360000 arcsec/s integer
46 CartesianPivotSpeedEnd 0 / 1 - 360000 arcsec/s integer
47 CartesianPivotAcceleration 10800000 / 1 - 10800000 arcsec/s2 integer
48 CartesianPivotStepSize ? / ? arcsec integer
49 EyeNumbers 0/-200 to +200 5 integers Sets the index for which Eye Dexter thinks it is at. Where it is within an eye is calculated with encoder measurements and effectively cannot be set. Takes 5 signed integer arguments where 0 is the circle that contains 0 degrees. See read_from_robot, #EyeNumbers.
50 CommandedAngles arcsec / arcsec 5 integers Sets where Dexter thinks it is without actually moving the robot. Takes 5 angles in integer arcseconds. These are the same values that are returned in the robot status under *_AT.
51 LinkLengths 228600, 320676, 330201, 50801, 82551 microns 5 integers Sets the lengths of each link in the arm for the onboard kinematics.
Link 1: Base mount to Joint 2 pivot.
Link 2: Joint 2 pivot to Joint 3 pivot.
Link 3: Joint 3 pivot to Joint 4 pivot.
Link 4: Joint 4 pivot to axis of tool interface.
Link 5: Axis of Joint 4 to end effector (note: this depends on the end effector)
52 RawEncoderErrorLimits 3600 / 0-1296000 arcsec 5 integers 2019/04/22 The largest error allowed between the raw encoder reading of position and the expected position for each joint. Part of the status monitor. Will inject a returned error status on the next command and write out and entry with more information to /srv/samba/share/errors.log
53 RawVelocityLimits 3600 / 0-1296000 arcsec 5 integers 2019/04/22 The largest velocity allowed between subsequent readings of the raw encoder position. Part of the status monitor. Will inject a returned error status on the next command and write out and entry with more information to /srv/samba/share/errors.log

Note 1 nbits are a value added to a register every clock cycle for a 128Khz clock such that once it overflows, an action will be taken. Converted automatically by DDE in the socket communications code for the "MaxSpeed", "StartSpeed", and "Acceleration" parameters. The global constant "_nbits_cf" is 7754.73550222 and the values given are multiplied by that constant. This converts degrees / second (or degrees / second / second in the case of Acceleration) into nbits. Setting these values too low with effectively lockup the FPGA as it will take far too long to complete a movement.

Note 2 Frictions can be fractional, but are limited to a range of +-(256 + 1/256). E.g. 1.1 becomes 1 plus a fractional value of 25/256

Test for new table format:

#, Name
(use either)
min|initial|max
in DDE units
min|initial|max
in Dexter units
Description
0, MaxSpeed 0.001 | 30 | 45
deg/s
8 | 250000 | 348963
integer nbits
Maximum velocity of next move in "nbits"1. See also StartSpeed below.
1, Acceleration 0.0001 | 0.0001 | 0.1
deg/s2
1 | 3 | 775
integer nbits
Maximum acceleration of next move in "nbits"1.
2, J1Force How hard each joint tries to return to commanded position in force protect modes
3, J3Force
4, J2Force
5, J4Force
6, J5Force
7, J1Friction 5 unitless 0-50 fixed point 8.8 2 The friction felt during FollowMe mode
8, J3Friction 5 unitless 0-50 fixed point 8.8
9, J2Friction 5 unitless 0-50 fixed point 8.8
10, J4Friction 15 unitless 0-150 fixed point 8.8
11, J5Friction 15 unitless 0-150 fixed point 8.8
12, J1BoundryHigh -180 | 150 | 180 deg -648000 | 540000 | 648000 integer arcsec Set all Boundaries at once with "B" Oplet
13, J1BoundryLow -180 \| -150 \| 180 deg -648000 \| -540000 \| 648000 integer arcsec
14, J3BoundryHigh -180 | 150 | 180 deg -648000 | 540000 | 648000 integer arcsec (note order: Joint 3 and 2 are swapped here)
15, J3BoundryLow -180 | -150 | 180 deg -648000 | -540000 | 648000 integer arcsec
16, J2BoundryHigh -180 | 90 | 180 deg -648000 | 324000 | 648000 integer arcsec
17, J2BoundryLow -180 | -90 | 180 deg -648000 | -324000 | 648000 integer arcsec
18, J4BoundryHigh -180 | 90 | 180 deg -648000 | 324000 | 648000 integer arcsec
19, J4BoundryLow -180 | -90 | 180 deg -648000 | -324000 | 648000 integer arcsec
20, J5BoundryHigh -180 | 90 | 180 deg -648000 | 324000 | 648000 integer arcsec
21, J5BoundryLow -180 | -90 | 180 deg -648000 | -324000 | 648000 integer arcsec
22, GripperMotor 0|0|1(ON/OFF), 0|0|12000(ON_PWM), 0|0|12000(OFF_PWM) bool, int, int Set PWM output on J19 1st parameter starts PWM with 1, stop with 0. After 2019/05/23: 2nd parameter is PWM on time, 3rd is off time. See W commands 73 - 74.
23, EERoll 0-300 deg 0|512|~1023 0.29*deg 6th axis position / Tool Interface Roll (was standard servo, May 29,2018 changed to Dynamixel)
24, EESpan 0-300 deg 0\|0\|~1023 0.29*deg 7th axis position / End Effector actuation (was standard servo, May 29,2018 changed to Dynamixel)
25, StartSpeed 0.0001|1|? 1|7754|? nbits Velocity at start (and currently, the end as well) of the next move in "nbits"1
26, EndSpeed (not implemented) Currently StartSpeed is the speed for both the start and end of each move.
27, ServoSet2X Address, Register, Value (as of 2018/05/29 was "End") see: Servo
28, ServoSet Address, Register, String 2018/05/29. Needs work see Issue 32 Needed for Screen
29, RebootServo n/a n/a 2018/05/29
30, RunFile FilePathName 2018/10/12 If it exists, the file will be opened and all instructions from it parsed and executed. By convention, files end with `.make_ins` extension. Each line should be one instruction just like any sent over the socket connection (the job, instruction, start, and end time values are NOT included; start with the oplet). A sample line might be
`S J1_PID_P 0.2 ; set base drive`
Anything after a ';' is ignored allowing comments.
Was 2018/08/24 `"Ctrl" parms/values` for compact setting of values related to operational mode but this was depreciated and replaced with RunFile.

Clone this wiki locally