Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 1 | include "frc971/control_loops/control_loops.fbs"; |
| 2 | |
| 3 | namespace frc971.control_loops; |
| 4 | |
| 5 | table ProfiledJointStatus { |
| 6 | // Is the subsystem zeroed? |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 7 | zeroed:bool (id: 0); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 8 | |
| 9 | // The state of the subsystem, if applicable. -1 otherwise. |
| 10 | // TODO(alex): replace with enum. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 11 | state:int (id: 1); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 12 | |
| 13 | // If true, we have aborted. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 14 | estopped:bool (id: 2); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 15 | |
| 16 | // Position of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 17 | position:float (id: 3); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 18 | // Velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 19 | velocity:float (id: 4); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 20 | // Profiled goal position of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 21 | goal_position:float (id: 5); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 22 | // Profiled goal velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 23 | goal_velocity:float (id: 6); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 24 | // Unprofiled goal position from absoulte zero of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 25 | unprofiled_goal_position:float (id: 7); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 26 | // Unprofiled goal velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 27 | unprofiled_goal_velocity:float (id: 8); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 28 | |
| 29 | // The estimated voltage error. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 30 | voltage_error:float (id: 9); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 31 | |
| 32 | // The calculated velocity with delta x/delta t |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 33 | calculated_velocity:float (id: 10); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 34 | |
| 35 | // Components of the control loop output |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 36 | position_power:float (id: 11); |
| 37 | velocity_power:float (id: 12); |
| 38 | feedforwards_power:float (id: 13); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 39 | |
| 40 | // State of the estimator. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 41 | estimator_state:frc971.EstimatorState (id: 14); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 42 | } |
| 43 | |
| 44 | table HallProfiledJointStatus { |
| 45 | // Is the subsystem zeroed? |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 46 | zeroed:bool (id: 0); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 47 | |
| 48 | // The state of the subsystem, if applicable. -1 otherwise. |
| 49 | // TODO(alex): replace with enum. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 50 | state:int (id: 1); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 51 | |
| 52 | // If true, we have aborted. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 53 | estopped:bool (id: 2); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 54 | |
| 55 | // Position of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 56 | position:float (id: 3); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 57 | // Velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 58 | velocity:float (id: 4); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 59 | // Profiled goal position of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 60 | goal_position:float (id: 5); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 61 | // Profiled goal velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 62 | goal_velocity:float (id: 6); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 63 | // Unprofiled goal position from absoulte zero of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 64 | unprofiled_goal_position:float (id: 7); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 65 | // Unprofiled goal velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 66 | unprofiled_goal_velocity:float (id: 8); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 67 | |
| 68 | // The estimated voltage error. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 69 | voltage_error:float (id: 9); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 70 | |
| 71 | // The calculated velocity with delta x/delta t |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 72 | calculated_velocity:float (id: 10); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 73 | |
| 74 | // Components of the control loop output |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 75 | position_power:float (id: 11); |
| 76 | velocity_power:float (id: 12); |
| 77 | feedforwards_power:float (id: 13); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 78 | |
| 79 | // State of the estimator. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 80 | estimator_state:frc971.HallEffectAndPositionEstimatorState (id: 14); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 81 | } |
| 82 | |
| 83 | table PotAndAbsoluteEncoderProfiledJointStatus { |
| 84 | // Is the subsystem zeroed? |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 85 | zeroed:bool (id: 0); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 86 | |
| 87 | // The state of the subsystem, if applicable. -1 otherwise. |
| 88 | // TODO(alex): replace with enum. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 89 | state:int (id: 1); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 90 | |
| 91 | // If true, we have aborted. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 92 | estopped:bool (id: 2); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 93 | |
| 94 | // Position of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 95 | position:float (id: 3); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 96 | // Velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 97 | velocity:float (id: 4); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 98 | // Profiled goal position of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 99 | goal_position:float (id: 5); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 100 | // Profiled goal velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 101 | goal_velocity:float (id: 6); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 102 | // Unprofiled goal position from absoulte zero of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 103 | unprofiled_goal_position:float (id: 7); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 104 | // Unprofiled goal velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 105 | unprofiled_goal_velocity:float (id: 8); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 106 | |
| 107 | // The estimated voltage error. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 108 | voltage_error:float (id: 9); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 109 | |
| 110 | // The calculated velocity with delta x/delta t |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 111 | calculated_velocity:float (id: 10); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 112 | |
| 113 | // Components of the control loop output |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 114 | position_power:float (id: 11); |
| 115 | velocity_power:float (id: 12); |
| 116 | feedforwards_power:float (id: 13); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 117 | |
| 118 | // State of the estimator. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 119 | estimator_state:frc971.PotAndAbsoluteEncoderEstimatorState (id: 14); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 120 | } |
| 121 | |
| 122 | table IndexProfiledJointStatus { |
| 123 | // Is the subsystem zeroed? |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 124 | zeroed:bool (id: 0); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 125 | |
| 126 | // The state of the subsystem, if applicable. -1 otherwise. |
| 127 | // TODO(alex): replace with enum. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 128 | state:int (id: 1); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 129 | |
| 130 | // If true, we have aborted. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 131 | estopped:bool (id: 2); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 132 | |
| 133 | // Position of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 134 | position:float (id: 3); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 135 | // Velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 136 | velocity:float (id: 4); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 137 | // Profiled goal position of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 138 | goal_position:float (id: 5); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 139 | // Profiled goal velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 140 | goal_velocity:float (id: 6); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 141 | // Unprofiled goal position from absoulte zero of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 142 | unprofiled_goal_position:float (id: 7); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 143 | // Unprofiled goal velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 144 | unprofiled_goal_velocity:float (id: 8); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 145 | |
| 146 | // The estimated voltage error. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 147 | voltage_error:float (id: 9); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 148 | |
| 149 | // The calculated velocity with delta x/delta t |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 150 | calculated_velocity:float (id: 10); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 151 | |
| 152 | // Components of the control loop output |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 153 | position_power:float (id: 11); |
| 154 | velocity_power:float (id: 12); |
| 155 | feedforwards_power:float (id: 13); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 156 | |
| 157 | // State of the estimator. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 158 | estimator_state:frc971.IndexEstimatorState (id: 14); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 159 | } |
| 160 | |
| 161 | table AbsoluteEncoderProfiledJointStatus { |
| 162 | // Is the subsystem zeroed? |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 163 | zeroed:bool (id: 0); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 164 | |
| 165 | // The state of the subsystem, if applicable. -1 otherwise. |
| 166 | // TODO(alex): replace with enum. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 167 | state:int (id: 1); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 168 | |
| 169 | // If true, we have aborted. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 170 | estopped:bool (id: 2); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 171 | |
| 172 | // Position of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 173 | position:float (id: 3); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 174 | // Velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 175 | velocity:float (id: 4); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 176 | // Profiled goal position of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 177 | goal_position:float (id: 5); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 178 | // Profiled goal velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 179 | goal_velocity:float (id: 6); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 180 | // Unprofiled goal position from absoulte zero of the joint. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 181 | unprofiled_goal_position:float (id: 7); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 182 | // Unprofiled goal velocity of the joint in units/second. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 183 | unprofiled_goal_velocity:float (id: 8); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 184 | |
| 185 | // The estimated voltage error. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 186 | voltage_error:float (id: 9); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 187 | |
| 188 | // The calculated velocity with delta x/delta t |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 189 | calculated_velocity:float (id: 10); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 190 | |
| 191 | // Components of the control loop output |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 192 | position_power:float (id: 11); |
| 193 | velocity_power:float (id: 12); |
| 194 | feedforwards_power:float (id: 13); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 195 | |
| 196 | // State of the estimator. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 197 | estimator_state:frc971.AbsoluteEncoderEstimatorState (id: 14); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 198 | } |
| 199 | |
Ravago Jones | 937587c | 2020-12-26 17:21:09 -0800 | [diff] [blame] | 200 | table AbsoluteAndAbsoluteEncoderProfiledJointStatus { |
| 201 | // Is the subsystem zeroed? |
| 202 | zeroed:bool (id: 0); |
| 203 | |
| 204 | // The state of the subsystem, if applicable. -1 otherwise. |
| 205 | // TODO(alex): replace with enum. |
| 206 | state:int (id: 1); |
| 207 | |
| 208 | // If true, we have aborted. |
| 209 | estopped:bool (id: 2); |
| 210 | |
| 211 | // Position of the joint. |
| 212 | position:float (id: 3); |
| 213 | // Velocity of the joint in units/second. |
| 214 | velocity:float (id: 4); |
| 215 | // Profiled goal position of the joint. |
| 216 | goal_position:float (id: 5); |
| 217 | // Profiled goal velocity of the joint in units/second. |
| 218 | goal_velocity:float (id: 6); |
| 219 | // Unprofiled goal position from absoulte zero of the joint. |
| 220 | unprofiled_goal_position:float (id: 7); |
| 221 | // Unprofiled goal velocity of the joint in units/second. |
| 222 | unprofiled_goal_velocity:float (id: 8); |
| 223 | |
| 224 | // The estimated voltage error. |
| 225 | voltage_error:float (id: 9); |
| 226 | |
| 227 | // The calculated velocity with delta x/delta t |
| 228 | calculated_velocity:float (id: 10); |
| 229 | |
| 230 | // Components of the control loop output |
| 231 | position_power:float (id: 11); |
| 232 | velocity_power:float (id: 12); |
| 233 | feedforwards_power:float (id: 13); |
| 234 | |
| 235 | // State of the estimator. |
| 236 | estimator_state:frc971.AbsoluteAndAbsoluteEncoderEstimatorState (id: 14); |
| 237 | } |
| 238 | |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 239 | table RelativeEncoderProfiledJointStatus { |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 240 | // Is the subsystem zeroed? |
| 241 | zeroed:bool (id: 0); |
| 242 | |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 243 | // The state of the subsystem, if applicable. -1 otherwise. |
| 244 | // TODO(alex): replace with enum. |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 245 | state:int (id: 1); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 246 | |
| 247 | // If true, we have aborted. |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 248 | estopped:bool (id: 2); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 249 | |
| 250 | // Position of the joint. |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 251 | position:float (id: 3); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 252 | // Velocity of the joint in units/second. |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 253 | velocity:float (id: 4); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 254 | // Profiled goal position of the joint. |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 255 | goal_position:float (id: 5); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 256 | // Profiled goal velocity of the joint in units/second. |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 257 | goal_velocity:float (id: 6); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 258 | // Unprofiled goal position from absoulte zero of the joint. |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 259 | unprofiled_goal_position:float (id: 7); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 260 | // Unprofiled goal velocity of the joint in units/second. |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 261 | unprofiled_goal_velocity:float (id: 8); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 262 | |
| 263 | // The estimated voltage error. |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 264 | voltage_error:float (id: 9); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 265 | |
| 266 | // The calculated velocity with delta x/delta t |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 267 | calculated_velocity:float (id: 10); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 268 | |
| 269 | // Components of the control loop output |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 270 | position_power:float (id: 11); |
| 271 | velocity_power:float (id: 12); |
| 272 | feedforwards_power:float (id: 13); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 273 | |
| 274 | // State of the estimator. |
Siddhant Kanwar | 0e37f59 | 2022-02-21 19:26:50 -0800 | [diff] [blame] | 275 | estimator_state:frc971.RelativeEncoderEstimatorState (id: 14); |
Tyler Chatow | 3c47f3c | 2020-01-29 20:45:23 -0800 | [diff] [blame] | 276 | } |
| 277 | |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 278 | table StaticZeroingSingleDOFProfiledSubsystemGoal { |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 279 | unsafe_goal:double (id: 0); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 280 | |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 281 | profile_params:frc971.ProfileParameters (id: 1); |
James Kuszmaul | 4fb2976 | 2020-02-20 19:37:41 -0800 | [diff] [blame] | 282 | |
| 283 | // Sets the goal velocity of the subsystem. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 284 | goal_velocity:double (id: 2); |
James Kuszmaul | 4fb2976 | 2020-02-20 19:37:41 -0800 | [diff] [blame] | 285 | |
| 286 | // If set to true, then we will ignore the profiling on this joint and pass |
| 287 | // the goal + goal velocity directly to the control loop. |
Ravago Jones | fb6a7a5 | 2020-11-14 13:47:46 -0800 | [diff] [blame] | 288 | ignore_profile:bool (id: 3); |
Alex Perry | cb7da4b | 2019-08-28 19:35:56 -0700 | [diff] [blame] | 289 | } |