CTRE Phoenix 6 C++ 26.0.0-beta-1
Loading...
Searching...
No Matches
DynamicMotionMagicDutyCycle.hpp
Go to the documentation of this file.
1/*
2 * Copyright (C) Cross The Road Electronics.  All rights reserved.
3 * License information can be found in CTRE_LICENSE.txt
4 * For support and suggestions contact support@ctr-electronics.com or file
5 * an issue tracker at https://github.com/CrossTheRoadElec/Phoenix-Releases
6 */
7#pragma once
8
10#include <units/frequency.h>
11#include <units/time.h>
12#include <units/angle.h>
13#include <units/angular_velocity.h>
14#include <units/angular_acceleration.h>
15#include <units/angular_jerk.h>
16#include <units/dimensionless.h>
17
18namespace ctre {
19namespace phoenix6 {
20namespace controls {
21
22/**
23 * Requires Phoenix Pro and CANivore;
24 * Requests Motion Magic® to target a final position using a motion profile.
25 * This dynamic request allows runtime changes to Cruise Velocity, Acceleration,
26 * and (optional) Jerk. Users can optionally provide a duty cycle feedforward.
27 *
28 * Motion Magic® produces a motion profile in real-time while attempting to honor the specified Cruise
29 * Velocity, Acceleration, and (optional) Jerk. This control mode does not use the Expo_kV or Expo_kA
30 * configs.
31 *
32 * Target position can be changed on-the-fly and Motion Magic® will do its best to adjust the profile. This
33 * control mode is duty cycle based, so relevant closed-loop gains will use fractional duty cycle for the
34 * numerator: +1.0 represents full forward output.
35 */
37 ctre::phoenix::StatusCode SendRequest(const char *network, uint32_t deviceHash, std::shared_ptr<ControlRequest> &req) const override;
38
39public:
40 /**
41 * \brief Position to drive toward in rotations.
42 *
43 * - Units: rotations
44 *
45 */
46 units::angle::turn_t Position;
47 /**
48 * \brief Cruise velocity for profiling. The signage does not matter as the
49 * device will use the absolute value for profile generation.
50 *
51 * - Units: rotations per second
52 *
53 */
54 units::angular_velocity::turns_per_second_t Velocity;
55 /**
56 * \brief Acceleration for profiling. The signage does not matter as the device
57 * will use the absolute value for profile generation
58 *
59 * - Units: rotations per second²
60 *
61 */
62 units::angular_acceleration::turns_per_second_squared_t Acceleration;
63 /**
64 * \brief Jerk for profiling. The signage does not matter as the device will
65 * use the absolute value for profile generation.
66 *
67 * Jerk is optional; if this is set to zero, then Motion Magic® will not apply a
68 * Jerk limit.
69 *
70 * - Units: rotations per second³
71 *
72 */
73 units::angular_jerk::turns_per_second_cubed_t Jerk = 0.0_tr_per_s_cu;
74 /**
75 * \brief Set to true to use FOC commutation (requires Phoenix Pro), which
76 * increases peak power by ~15% on supported devices (see
77 * hardware#traits#SupportsFOC). Set to false to use trapezoidal commutation.
78 *
79 * FOC improves motor performance by leveraging torque (current) control.
80 * However, this may be inconvenient for applications that require specifying
81 * duty cycle or voltage. CTR-Electronics has developed a hybrid method that
82 * combines the performances gains of FOC while still allowing applications to
83 * provide duty cycle or voltage demand. This not to be confused with simple
84 * sinusoidal control or phase voltage control which lacks the performance
85 * gains.
86 */
87 bool EnableFOC = true;
88 /**
89 * \brief Feedforward to apply in fractional units between -1 and +1. This is
90 * added to the output of the onboard feedforward terms.
91 *
92 * - Units: fractional
93 *
94 */
95 units::dimensionless::scalar_t FeedForward = 0.0;
96 /**
97 * \brief Select which gains are applied by selecting the slot. Use the
98 * configuration api to set the gain values for the selected slot before
99 * enabling this feature. Slot must be within [0,2].
100 */
101 int Slot = 0;
102 /**
103 * \brief Set to true to static-brake the rotor when output is zero (or within
104 * deadband). Set to false to use the NeutralMode configuration setting
105 * (default). This flag exists to provide the fundamental behavior of this
106 * control when output is zero, which is to provide 0V to the motor.
107 */
109 /**
110 * \brief Set to true to force forward limiting. This allows users to use other
111 * limit switch sensors connected to robot controller. This also allows use of
112 * active sensors that require external power.
113 */
114 bool LimitForwardMotion = false;
115 /**
116 * \brief Set to true to force reverse limiting. This allows users to use other
117 * limit switch sensors connected to robot controller. This also allows use of
118 * active sensors that require external power.
119 */
120 bool LimitReverseMotion = false;
121 /**
122 * \brief Set to true to ignore hardware limit switches and the
123 * LimitForwardMotion and LimitReverseMotion parameters, instead allowing
124 * motion.
125 *
126 * This can be useful on mechanisms such as an intake/feeder, where a limit
127 * switch stops motion while intaking but should be ignored when feeding to a
128 * shooter.
129 *
130 * The hardware limit faults and Forward/ReverseLimit signals will still report
131 * the values of the limit switches regardless of this parameter.
132 */
134 /**
135 * \brief Set to true to ignore software limits, instead allowing motion.
136 *
137 * This can be useful when calibrating the zero point of a mechanism such as an
138 * elevator.
139 *
140 * The software limit faults will still report the values of the software limits
141 * regardless of this parameter.
142 */
144 /**
145 * \brief Set to true to delay applying this control request until a timesync
146 * boundary (requires Phoenix Pro and CANivore). This eliminates the impact of
147 * nondeterministic network delays in exchange for a larger but deterministic
148 * control latency.
149 *
150 * This requires setting the ControlTimesyncFreqHz config in MotorOutputConfigs.
151 * Additionally, when this is enabled, the UpdateFreqHz of this request should
152 * be set to 0 Hz.
153 */
154 bool UseTimesync = false;
155
156 /**
157 * \brief The frequency at which this control will update.
158 * This is designated in Hertz, with a minimum of 20 Hz
159 * (every 50 ms) and a maximum of 1000 Hz (every 1 ms).
160 * Some update frequencies are not supported and will be
161 * promoted up to the next highest supported frequency.
162 *
163 * If this field is set to 0 Hz, the control request will
164 * be sent immediately as a one-shot frame. This may be useful
165 * for advanced applications that require outputs to be
166 * synchronized with data acquisition. In this case, we
167 * recommend not exceeding 50 ms between control calls.
168 */
169 units::frequency::hertz_t UpdateFreqHz{100_Hz};
170
171 /**
172 * \brief Requires Phoenix Pro and CANivore;
173 * Requests Motion Magic® to target a final position using a motion
174 * profile. This dynamic request allows runtime changes to Cruise
175 * Velocity, Acceleration, and (optional) Jerk. Users can optionally
176 * provide a duty cycle feedforward.
177 *
178 * \details Motion Magic® produces a motion profile in real-time while
179 * attempting to honor the specified Cruise Velocity, Acceleration, and
180 * (optional) Jerk. This control mode does not use the Expo_kV or
181 * Expo_kA configs.
182 *
183 * Target position can be changed on-the-fly and Motion Magic® will do
184 * its best to adjust the profile. This control mode is duty cycle
185 * based, so relevant closed-loop gains will use fractional duty cycle
186 * for the numerator: +1.0 represents full forward output.
187 *
188 * \param Position Position to drive toward in rotations.
189 * \param Velocity Cruise velocity for profiling. The signage does not matter
190 * as the device will use the absolute value for profile
191 * generation.
192 * \param Acceleration Acceleration for profiling. The signage does not matter
193 * as the device will use the absolute value for profile
194 * generation
195 */
196 constexpr DynamicMotionMagicDutyCycle(units::angle::turn_t Position, units::angular_velocity::turns_per_second_t Velocity, units::angular_acceleration::turns_per_second_squared_t Acceleration) : ControlRequest{},
197 Position{std::move(Position)},
198 Velocity{std::move(Velocity)},
199 Acceleration{std::move(Acceleration)}
200 {}
201
202 constexpr ~DynamicMotionMagicDutyCycle() override {}
203
204 /**
205 * \brief Gets the name of this control request.
206 *
207 * \returns Name of the control request
208 */
209 constexpr std::string_view GetName() const override
210 {
211 return "DynamicMotionMagicDutyCycle";
212 }
213
214 /**
215 * \brief Modifies this Control Request's Position parameter and returns itself for
216 * method-chaining and easier to use request API.
217 *
218 * Position to drive toward in rotations.
219 *
220 * - Units: rotations
221 *
222 *
223 * \param newPosition Parameter to modify
224 * \returns Itself
225 */
226 constexpr DynamicMotionMagicDutyCycle &WithPosition(units::angle::turn_t newPosition)
227 {
228 Position = std::move(newPosition);
229 return *this;
230 }
231
232 /**
233 * \brief Modifies this Control Request's Velocity parameter and returns itself for
234 * method-chaining and easier to use request API.
235 *
236 * Cruise velocity for profiling. The signage does not matter as the device
237 * will use the absolute value for profile generation.
238 *
239 * - Units: rotations per second
240 *
241 *
242 * \param newVelocity Parameter to modify
243 * \returns Itself
244 */
245 constexpr DynamicMotionMagicDutyCycle &WithVelocity(units::angular_velocity::turns_per_second_t newVelocity)
246 {
247 Velocity = std::move(newVelocity);
248 return *this;
249 }
250
251 /**
252 * \brief Modifies this Control Request's Acceleration parameter and returns itself for
253 * method-chaining and easier to use request API.
254 *
255 * Acceleration for profiling. The signage does not matter as the device will
256 * use the absolute value for profile generation
257 *
258 * - Units: rotations per second²
259 *
260 *
261 * \param newAcceleration Parameter to modify
262 * \returns Itself
263 */
264 constexpr DynamicMotionMagicDutyCycle &WithAcceleration(units::angular_acceleration::turns_per_second_squared_t newAcceleration)
265 {
266 Acceleration = std::move(newAcceleration);
267 return *this;
268 }
269
270 /**
271 * \brief Modifies this Control Request's Jerk parameter and returns itself for
272 * method-chaining and easier to use request API.
273 *
274 * Jerk for profiling. The signage does not matter as the device will use the
275 * absolute value for profile generation.
276 *
277 * Jerk is optional; if this is set to zero, then Motion Magic® will not apply a
278 * Jerk limit.
279 *
280 * - Units: rotations per second³
281 *
282 *
283 * \param newJerk Parameter to modify
284 * \returns Itself
285 */
286 constexpr DynamicMotionMagicDutyCycle &WithJerk(units::angular_jerk::turns_per_second_cubed_t newJerk)
287 {
288 Jerk = std::move(newJerk);
289 return *this;
290 }
291
292 /**
293 * \brief Modifies this Control Request's EnableFOC parameter and returns itself for
294 * method-chaining and easier to use request API.
295 *
296 * Set to true to use FOC commutation (requires Phoenix Pro), which increases
297 * peak power by ~15% on supported devices (see hardware#traits#SupportsFOC).
298 * Set to false to use trapezoidal commutation.
299 *
300 * FOC improves motor performance by leveraging torque (current) control.
301 * However, this may be inconvenient for applications that require specifying
302 * duty cycle or voltage. CTR-Electronics has developed a hybrid method that
303 * combines the performances gains of FOC while still allowing applications to
304 * provide duty cycle or voltage demand. This not to be confused with simple
305 * sinusoidal control or phase voltage control which lacks the performance
306 * gains.
307 *
308 * \param newEnableFOC Parameter to modify
309 * \returns Itself
310 */
311 constexpr DynamicMotionMagicDutyCycle &WithEnableFOC(bool newEnableFOC)
312 {
313 EnableFOC = std::move(newEnableFOC);
314 return *this;
315 }
316
317 /**
318 * \brief Modifies this Control Request's FeedForward parameter and returns itself for
319 * method-chaining and easier to use request API.
320 *
321 * Feedforward to apply in fractional units between -1 and +1. This is added to
322 * the output of the onboard feedforward terms.
323 *
324 * - Units: fractional
325 *
326 *
327 * \param newFeedForward Parameter to modify
328 * \returns Itself
329 */
330 constexpr DynamicMotionMagicDutyCycle &WithFeedForward(units::dimensionless::scalar_t newFeedForward)
331 {
332 FeedForward = std::move(newFeedForward);
333 return *this;
334 }
335
336 /**
337 * \brief Modifies this Control Request's Slot parameter and returns itself for
338 * method-chaining and easier to use request API.
339 *
340 * Select which gains are applied by selecting the slot. Use the configuration
341 * api to set the gain values for the selected slot before enabling this
342 * feature. Slot must be within [0,2].
343 *
344 * \param newSlot Parameter to modify
345 * \returns Itself
346 */
347 constexpr DynamicMotionMagicDutyCycle &WithSlot(int newSlot)
348 {
349 Slot = std::move(newSlot);
350 return *this;
351 }
352
353 /**
354 * \brief Modifies this Control Request's OverrideBrakeDurNeutral parameter and returns itself for
355 * method-chaining and easier to use request API.
356 *
357 * Set to true to static-brake the rotor when output is zero (or within
358 * deadband). Set to false to use the NeutralMode configuration setting
359 * (default). This flag exists to provide the fundamental behavior of this
360 * control when output is zero, which is to provide 0V to the motor.
361 *
362 * \param newOverrideBrakeDurNeutral Parameter to modify
363 * \returns Itself
364 */
365 constexpr DynamicMotionMagicDutyCycle &WithOverrideBrakeDurNeutral(bool newOverrideBrakeDurNeutral)
366 {
367 OverrideBrakeDurNeutral = std::move(newOverrideBrakeDurNeutral);
368 return *this;
369 }
370
371 /**
372 * \brief Modifies this Control Request's LimitForwardMotion parameter and returns itself for
373 * method-chaining and easier to use request API.
374 *
375 * Set to true to force forward limiting. This allows users to use other limit
376 * switch sensors connected to robot controller. This also allows use of active
377 * sensors that require external power.
378 *
379 * \param newLimitForwardMotion Parameter to modify
380 * \returns Itself
381 */
382 constexpr DynamicMotionMagicDutyCycle &WithLimitForwardMotion(bool newLimitForwardMotion)
383 {
384 LimitForwardMotion = std::move(newLimitForwardMotion);
385 return *this;
386 }
387
388 /**
389 * \brief Modifies this Control Request's LimitReverseMotion parameter and returns itself for
390 * method-chaining and easier to use request API.
391 *
392 * Set to true to force reverse limiting. This allows users to use other limit
393 * switch sensors connected to robot controller. This also allows use of active
394 * sensors that require external power.
395 *
396 * \param newLimitReverseMotion Parameter to modify
397 * \returns Itself
398 */
399 constexpr DynamicMotionMagicDutyCycle &WithLimitReverseMotion(bool newLimitReverseMotion)
400 {
401 LimitReverseMotion = std::move(newLimitReverseMotion);
402 return *this;
403 }
404
405 /**
406 * \brief Modifies this Control Request's IgnoreHardwareLimits parameter and returns itself for
407 * method-chaining and easier to use request API.
408 *
409 * Set to true to ignore hardware limit switches and the LimitForwardMotion and
410 * LimitReverseMotion parameters, instead allowing motion.
411 *
412 * This can be useful on mechanisms such as an intake/feeder, where a limit
413 * switch stops motion while intaking but should be ignored when feeding to a
414 * shooter.
415 *
416 * The hardware limit faults and Forward/ReverseLimit signals will still report
417 * the values of the limit switches regardless of this parameter.
418 *
419 * \param newIgnoreHardwareLimits Parameter to modify
420 * \returns Itself
421 */
422 constexpr DynamicMotionMagicDutyCycle &WithIgnoreHardwareLimits(bool newIgnoreHardwareLimits)
423 {
424 IgnoreHardwareLimits = std::move(newIgnoreHardwareLimits);
425 return *this;
426 }
427
428 /**
429 * \brief Modifies this Control Request's IgnoreSoftwareLimits parameter and returns itself for
430 * method-chaining and easier to use request API.
431 *
432 * Set to true to ignore software limits, instead allowing motion.
433 *
434 * This can be useful when calibrating the zero point of a mechanism such as an
435 * elevator.
436 *
437 * The software limit faults will still report the values of the software limits
438 * regardless of this parameter.
439 *
440 * \param newIgnoreSoftwareLimits Parameter to modify
441 * \returns Itself
442 */
443 constexpr DynamicMotionMagicDutyCycle &WithIgnoreSoftwareLimits(bool newIgnoreSoftwareLimits)
444 {
445 IgnoreSoftwareLimits = std::move(newIgnoreSoftwareLimits);
446 return *this;
447 }
448
449 /**
450 * \brief Modifies this Control Request's UseTimesync parameter and returns itself for
451 * method-chaining and easier to use request API.
452 *
453 * Set to true to delay applying this control request until a timesync boundary
454 * (requires Phoenix Pro and CANivore). This eliminates the impact of
455 * nondeterministic network delays in exchange for a larger but deterministic
456 * control latency.
457 *
458 * This requires setting the ControlTimesyncFreqHz config in MotorOutputConfigs.
459 * Additionally, when this is enabled, the UpdateFreqHz of this request should
460 * be set to 0 Hz.
461 *
462 * \param newUseTimesync Parameter to modify
463 * \returns Itself
464 */
465 constexpr DynamicMotionMagicDutyCycle &WithUseTimesync(bool newUseTimesync)
466 {
467 UseTimesync = std::move(newUseTimesync);
468 return *this;
469 }
470
471 /**
472 * \brief Sets the frequency at which this control will update.
473 * This is designated in Hertz, with a minimum of 20 Hz
474 * (every 50 ms) and a maximum of 1000 Hz (every 1 ms).
475 * Some update frequencies are not supported and will be
476 * promoted up to the next highest supported frequency.
477 *
478 * If this field is set to 0 Hz, the control request will
479 * be sent immediately as a one-shot frame. This may be useful
480 * for advanced applications that require outputs to be
481 * synchronized with data acquisition. In this case, we
482 * recommend not exceeding 50 ms between control calls.
483 *
484 * \param newUpdateFreqHz Parameter to modify
485 * \returns Itself
486 */
487 constexpr DynamicMotionMagicDutyCycle &WithUpdateFreqHz(units::frequency::hertz_t newUpdateFreqHz)
488 {
489 UpdateFreqHz = newUpdateFreqHz;
490 return *this;
491 }
492
493 /**
494 * \brief Returns a string representation of the object.
495 *
496 * \returns a string representation of the object.
497 */
498 std::string ToString() const override;
499
500 /**
501 * \brief Gets information about this control request.
502 *
503 * \returns Map of control parameter names and corresponding applied values
504 */
505 std::map<std::string, std::string> GetControlInfo() const override;
506};
507
508}
509}
510}
511
Common interface implemented by all control requests.
Definition ControlRequest.hpp:27
Requires Phoenix Pro and CANivore; Requests Motion Magic® to target a final position using a motion p...
Definition DynamicMotionMagicDutyCycle.hpp:36
std::string ToString() const override
Returns a string representation of the object.
constexpr DynamicMotionMagicDutyCycle(units::angle::turn_t Position, units::angular_velocity::turns_per_second_t Velocity, units::angular_acceleration::turns_per_second_squared_t Acceleration)
Requires Phoenix Pro and CANivore; Requests Motion Magic® to target a final position using a motion p...
Definition DynamicMotionMagicDutyCycle.hpp:196
constexpr DynamicMotionMagicDutyCycle & WithUseTimesync(bool newUseTimesync)
Modifies this Control Request's UseTimesync parameter and returns itself for method-chaining and easi...
Definition DynamicMotionMagicDutyCycle.hpp:465
units::angular_velocity::turns_per_second_t Velocity
Cruise velocity for profiling.
Definition DynamicMotionMagicDutyCycle.hpp:54
constexpr DynamicMotionMagicDutyCycle & WithUpdateFreqHz(units::frequency::hertz_t newUpdateFreqHz)
Sets the frequency at which this control will update.
Definition DynamicMotionMagicDutyCycle.hpp:487
constexpr DynamicMotionMagicDutyCycle & WithJerk(units::angular_jerk::turns_per_second_cubed_t newJerk)
Modifies this Control Request's Jerk parameter and returns itself for method-chaining and easier to u...
Definition DynamicMotionMagicDutyCycle.hpp:286
units::angular_acceleration::turns_per_second_squared_t Acceleration
Acceleration for profiling.
Definition DynamicMotionMagicDutyCycle.hpp:62
bool OverrideBrakeDurNeutral
Set to true to static-brake the rotor when output is zero (or within deadband).
Definition DynamicMotionMagicDutyCycle.hpp:108
units::frequency::hertz_t UpdateFreqHz
The frequency at which this control will update.
Definition DynamicMotionMagicDutyCycle.hpp:169
bool EnableFOC
Set to true to use FOC commutation (requires Phoenix Pro), which increases peak power by ~15% on supp...
Definition DynamicMotionMagicDutyCycle.hpp:87
units::angular_jerk::turns_per_second_cubed_t Jerk
Jerk for profiling.
Definition DynamicMotionMagicDutyCycle.hpp:73
constexpr DynamicMotionMagicDutyCycle & WithPosition(units::angle::turn_t newPosition)
Modifies this Control Request's Position parameter and returns itself for method-chaining and easier ...
Definition DynamicMotionMagicDutyCycle.hpp:226
bool LimitForwardMotion
Set to true to force forward limiting.
Definition DynamicMotionMagicDutyCycle.hpp:114
constexpr ~DynamicMotionMagicDutyCycle() override
Definition DynamicMotionMagicDutyCycle.hpp:202
bool IgnoreHardwareLimits
Set to true to ignore hardware limit switches and the LimitForwardMotion and LimitReverseMotion param...
Definition DynamicMotionMagicDutyCycle.hpp:133
constexpr DynamicMotionMagicDutyCycle & WithLimitForwardMotion(bool newLimitForwardMotion)
Modifies this Control Request's LimitForwardMotion parameter and returns itself for method-chaining a...
Definition DynamicMotionMagicDutyCycle.hpp:382
constexpr DynamicMotionMagicDutyCycle & WithIgnoreHardwareLimits(bool newIgnoreHardwareLimits)
Modifies this Control Request's IgnoreHardwareLimits parameter and returns itself for method-chaining...
Definition DynamicMotionMagicDutyCycle.hpp:422
constexpr DynamicMotionMagicDutyCycle & WithVelocity(units::angular_velocity::turns_per_second_t newVelocity)
Modifies this Control Request's Velocity parameter and returns itself for method-chaining and easier ...
Definition DynamicMotionMagicDutyCycle.hpp:245
bool LimitReverseMotion
Set to true to force reverse limiting.
Definition DynamicMotionMagicDutyCycle.hpp:120
constexpr DynamicMotionMagicDutyCycle & WithLimitReverseMotion(bool newLimitReverseMotion)
Modifies this Control Request's LimitReverseMotion parameter and returns itself for method-chaining a...
Definition DynamicMotionMagicDutyCycle.hpp:399
bool IgnoreSoftwareLimits
Set to true to ignore software limits, instead allowing motion.
Definition DynamicMotionMagicDutyCycle.hpp:143
std::map< std::string, std::string > GetControlInfo() const override
Gets information about this control request.
constexpr DynamicMotionMagicDutyCycle & WithIgnoreSoftwareLimits(bool newIgnoreSoftwareLimits)
Modifies this Control Request's IgnoreSoftwareLimits parameter and returns itself for method-chaining...
Definition DynamicMotionMagicDutyCycle.hpp:443
constexpr DynamicMotionMagicDutyCycle & WithSlot(int newSlot)
Modifies this Control Request's Slot parameter and returns itself for method-chaining and easier to u...
Definition DynamicMotionMagicDutyCycle.hpp:347
constexpr std::string_view GetName() const override
Gets the name of this control request.
Definition DynamicMotionMagicDutyCycle.hpp:209
units::angle::turn_t Position
Position to drive toward in rotations.
Definition DynamicMotionMagicDutyCycle.hpp:46
int Slot
Select which gains are applied by selecting the slot.
Definition DynamicMotionMagicDutyCycle.hpp:101
constexpr DynamicMotionMagicDutyCycle & WithAcceleration(units::angular_acceleration::turns_per_second_squared_t newAcceleration)
Modifies this Control Request's Acceleration parameter and returns itself for method-chaining and eas...
Definition DynamicMotionMagicDutyCycle.hpp:264
bool UseTimesync
Set to true to delay applying this control request until a timesync boundary (requires Phoenix Pro an...
Definition DynamicMotionMagicDutyCycle.hpp:154
constexpr DynamicMotionMagicDutyCycle & WithOverrideBrakeDurNeutral(bool newOverrideBrakeDurNeutral)
Modifies this Control Request's OverrideBrakeDurNeutral parameter and returns itself for method-chain...
Definition DynamicMotionMagicDutyCycle.hpp:365
constexpr DynamicMotionMagicDutyCycle & WithFeedForward(units::dimensionless::scalar_t newFeedForward)
Modifies this Control Request's FeedForward parameter and returns itself for method-chaining and easi...
Definition DynamicMotionMagicDutyCycle.hpp:330
constexpr DynamicMotionMagicDutyCycle & WithEnableFOC(bool newEnableFOC)
Modifies this Control Request's EnableFOC parameter and returns itself for method-chaining and easier...
Definition DynamicMotionMagicDutyCycle.hpp:311
units::dimensionless::scalar_t FeedForward
Feedforward to apply in fractional units between -1 and +1.
Definition DynamicMotionMagicDutyCycle.hpp:95
Status codes reported by APIs, including OK, warnings, and errors.
Definition StatusCodes.h:28
Definition motor_constants.h:14