Add actuator and sensor delays. Fixes #1004
PiperOrigin-RevId: 866478839 Change-Id: Id21a6da0f98454c8fa39ea5af8a5e213d6eae497
This commit is contained in:
committed by
Copybara-Service
parent
84fa527723
commit
6419534bad
+13
-11
@@ -29,20 +29,21 @@ typedef enum mjtState_ { // state elements
|
||||
mjSTATE_QPOS = 1<<1, // position
|
||||
mjSTATE_QVEL = 1<<2, // velocity
|
||||
mjSTATE_ACT = 1<<3, // actuator activation
|
||||
mjSTATE_WARMSTART = 1<<4, // acceleration used for warmstart
|
||||
mjSTATE_CTRL = 1<<5, // control
|
||||
mjSTATE_QFRC_APPLIED = 1<<6, // applied generalized force
|
||||
mjSTATE_XFRC_APPLIED = 1<<7, // applied Cartesian force/torque
|
||||
mjSTATE_EQ_ACTIVE = 1<<8, // enable/disable constraints
|
||||
mjSTATE_MOCAP_POS = 1<<9, // positions of mocap bodies
|
||||
mjSTATE_MOCAP_QUAT = 1<<10, // orientations of mocap bodies
|
||||
mjSTATE_USERDATA = 1<<11, // user data
|
||||
mjSTATE_PLUGIN = 1<<12, // plugin state
|
||||
mjSTATE_HISTORY = 1<<4, // history buffers (control, sensor)
|
||||
mjSTATE_WARMSTART = 1<<5, // acceleration used for warmstart
|
||||
mjSTATE_CTRL = 1<<6, // control
|
||||
mjSTATE_QFRC_APPLIED = 1<<7, // applied generalized force
|
||||
mjSTATE_XFRC_APPLIED = 1<<8, // applied Cartesian force/torque
|
||||
mjSTATE_EQ_ACTIVE = 1<<9, // enable/disable constraints
|
||||
mjSTATE_MOCAP_POS = 1<<10, // positions of mocap bodies
|
||||
mjSTATE_MOCAP_QUAT = 1<<11, // orientations of mocap bodies
|
||||
mjSTATE_USERDATA = 1<<12, // user data
|
||||
mjSTATE_PLUGIN = 1<<13, // plugin state
|
||||
|
||||
mjNSTATE = 13, // number of state elements
|
||||
mjNSTATE = 14, // number of state elements
|
||||
|
||||
// convenience values for commonly used state specifications
|
||||
mjSTATE_PHYSICS = mjSTATE_QPOS | mjSTATE_QVEL | mjSTATE_ACT,
|
||||
mjSTATE_PHYSICS = mjSTATE_QPOS | mjSTATE_QVEL | mjSTATE_ACT | mjSTATE_HISTORY,
|
||||
mjSTATE_FULLPHYSICS = mjSTATE_TIME | mjSTATE_PHYSICS | mjSTATE_PLUGIN,
|
||||
mjSTATE_USER = mjSTATE_CTRL | mjSTATE_QFRC_APPLIED | mjSTATE_XFRC_APPLIED |
|
||||
mjSTATE_EQ_ACTIVE | mjSTATE_MOCAP_POS | mjSTATE_MOCAP_QUAT |
|
||||
@@ -255,6 +256,7 @@ struct mjData_ {
|
||||
mjtNum* qpos; // position (nq x 1)
|
||||
mjtNum* qvel; // velocity (nv x 1)
|
||||
mjtNum* act; // actuator activation (na x 1)
|
||||
mjtNum* history; // history buffer (nhistory x 1)
|
||||
mjtNum* qacc_warmstart; // acceleration used for warmstart (nv x 1)
|
||||
mjtNum* plugin_state; // plugin state (npluginstate x 1)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user