CTRE Phoenix 6 C++ 26.1.3
Loading...
Searching...
No Matches
CoreTalonFX.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
133#include <units/angle.h>
134#include <units/angular_acceleration.h>
135#include <units/angular_velocity.h>
136#include <units/current.h>
137#include <units/dimensionless.h>
138#include <units/temperature.h>
139#include <units/voltage.h>
140
141namespace ctre {
142namespace phoenix6 {
143
144namespace hardware {
145namespace core {
146 class CoreTalonFX;
147}
148}
149
150namespace configs {
151
152/**
153 * Class description for the Talon FX integrated motor controller.
154 *
155 * This defines all configurations for the hardware#TalonFX.
156 */
158{
159public:
160 constexpr TalonFXConfiguration() = default;
161
162 /**
163 * \brief True if we should factory default newer unsupported configs,
164 * false to leave newer unsupported configs alone.
165 *
166 * \details This flag addresses a corner case where the device may have
167 * firmware with newer configs that didn't exist when this
168 * version of the API was built. If this occurs and this
169 * flag is true, unsupported new configs will be factory
170 * defaulted to avoid unexpected behavior.
171 *
172 * This is also the behavior in Phoenix 5, so this flag
173 * is defaulted to true to match.
174 */
176
177
178 /**
179 * \brief Configs that directly affect motor output.
180 *
181 * \details Includes motor invert, neutral mode, and other features
182 * related to motor output.
183 *
184 * Parameter list:
185 *
186 * - MotorOutputConfigs#Inverted
187 * - MotorOutputConfigs#NeutralMode
188 * - MotorOutputConfigs#DutyCycleNeutralDeadband
189 * - MotorOutputConfigs#PeakForwardDutyCycle
190 * - MotorOutputConfigs#PeakReverseDutyCycle
191 * - MotorOutputConfigs#ControlTimesyncFreqHz
192 *
193 */
195
196 /**
197 * \brief Configs that directly affect current limiting features.
198 *
199 * \details Contains the supply/stator current limit thresholds and
200 * whether to enable them.
201 *
202 * Parameter list:
203 *
204 * - CurrentLimitsConfigs#StatorCurrentLimit
205 * - CurrentLimitsConfigs#StatorCurrentLimitEnable
206 * - CurrentLimitsConfigs#SupplyCurrentLimit
207 * - CurrentLimitsConfigs#SupplyCurrentLimitEnable
208 * - CurrentLimitsConfigs#SupplyCurrentLowerLimit
209 * - CurrentLimitsConfigs#SupplyCurrentLowerTime
210 *
211 */
213
214 /**
215 * \brief Configs that affect Voltage control types.
216 *
217 * \details Includes peak output voltages and other configs affecting
218 * voltage measurements.
219 *
220 * Parameter list:
221 *
222 * - VoltageConfigs#SupplyVoltageTimeConstant
223 * - VoltageConfigs#PeakForwardVoltage
224 * - VoltageConfigs#PeakReverseVoltage
225 *
226 */
228
229 /**
230 * \brief Configs that affect Torque Current control types.
231 *
232 * \details Includes the maximum and minimum applied torque output and
233 * the neutral deadband used during TorqueCurrentFOC
234 * requests.
235 *
236 * Parameter list:
237 *
238 * - TorqueCurrentConfigs#PeakForwardTorqueCurrent
239 * - TorqueCurrentConfigs#PeakReverseTorqueCurrent
240 * - TorqueCurrentConfigs#TorqueNeutralDeadband
241 *
242 */
244
245 /**
246 * \brief Configs that affect the feedback of this motor controller.
247 *
248 * \details Includes feedback sensor source, any offsets for the
249 * feedback sensor, and various ratios to describe the
250 * relationship between the sensor and the mechanism for
251 * closed looping.
252 *
253 * Parameter list:
254 *
255 * - FeedbackConfigs#FeedbackRotorOffset
256 * - FeedbackConfigs#SensorToMechanismRatio
257 * - FeedbackConfigs#RotorToSensorRatio
258 * - FeedbackConfigs#FeedbackSensorSource
259 * - FeedbackConfigs#FeedbackRemoteSensorID
260 * - FeedbackConfigs#VelocityFilterTimeConstant
261 *
262 */
264
265 /**
266 * \brief Configs related to sensors used for differential control of
267 * a mechanism.
268 *
269 * \details Includes the differential sensor sources and IDs.
270 *
271 * Parameter list:
272 *
273 * - DifferentialSensorsConfigs#DifferentialSensorSource
274 * - DifferentialSensorsConfigs#DifferentialTalonFXSensorID
275 * - DifferentialSensorsConfigs#DifferentialRemoteSensorID
276 * - DifferentialSensorsConfigs#SensorToDifferentialRatio
277 *
278 */
280
281 /**
282 * \brief Configs related to constants used for differential control
283 * of a mechanism.
284 *
285 * \details Includes the differential peak outputs.
286 *
287 * Parameter list:
288 *
289 * - DifferentialConstantsConfigs#PeakDifferentialDutyCycle
290 * - DifferentialConstantsConfigs#PeakDifferentialVoltage
291 * - DifferentialConstantsConfigs#PeakDifferentialTorqueCurrent
292 *
293 */
295
296 /**
297 * \brief Configs that affect the open-loop control of this motor
298 * controller.
299 *
300 * \details Open-loop ramp rates for the various control types.
301 *
302 * Parameter list:
303 *
304 * - OpenLoopRampsConfigs#DutyCycleOpenLoopRampPeriod
305 * - OpenLoopRampsConfigs#VoltageOpenLoopRampPeriod
306 * - OpenLoopRampsConfigs#TorqueOpenLoopRampPeriod
307 *
308 */
310
311 /**
312 * \brief Configs that affect the closed-loop control of this motor
313 * controller.
314 *
315 * \details Closed-loop ramp rates for the various control types.
316 *
317 * Parameter list:
318 *
319 * - ClosedLoopRampsConfigs#DutyCycleClosedLoopRampPeriod
320 * - ClosedLoopRampsConfigs#VoltageClosedLoopRampPeriod
321 * - ClosedLoopRampsConfigs#TorqueClosedLoopRampPeriod
322 *
323 */
325
326 /**
327 * \brief Configs that change how the motor controller behaves under
328 * different limit switch states.
329 *
330 * \details Includes configs such as enabling limit switches,
331 * configuring the remote sensor ID, the source, and the
332 * position to set on limit.
333 *
334 * Parameter list:
335 *
336 * - HardwareLimitSwitchConfigs#ForwardLimitType
337 * - HardwareLimitSwitchConfigs#ForwardLimitAutosetPositionEnable
338 * - HardwareLimitSwitchConfigs#ForwardLimitAutosetPositionValue
339 * - HardwareLimitSwitchConfigs#ForwardLimitEnable
340 * - HardwareLimitSwitchConfigs#ForwardLimitSource
341 * - HardwareLimitSwitchConfigs#ForwardLimitRemoteSensorID
342 * - HardwareLimitSwitchConfigs#ReverseLimitType
343 * - HardwareLimitSwitchConfigs#ReverseLimitAutosetPositionEnable
344 * - HardwareLimitSwitchConfigs#ReverseLimitAutosetPositionValue
345 * - HardwareLimitSwitchConfigs#ReverseLimitEnable
346 * - HardwareLimitSwitchConfigs#ReverseLimitSource
347 * - HardwareLimitSwitchConfigs#ReverseLimitRemoteSensorID
348 *
349 */
351
352 /**
353 * \brief Configs that affect audible components of the device.
354 *
355 * \details Includes configuration for the beep on boot.
356 *
357 * Parameter list:
358 *
359 * - AudioConfigs#BeepOnBoot
360 * - AudioConfigs#BeepOnConfig
361 * - AudioConfigs#AllowMusicDurDisable
362 *
363 */
365
366 /**
367 * \brief Configs that affect how software-limit switches behave.
368 *
369 * \details Includes enabling software-limit switches and the
370 * threshold at which they are tripped.
371 *
372 * Parameter list:
373 *
374 * - SoftwareLimitSwitchConfigs#ForwardSoftLimitEnable
375 * - SoftwareLimitSwitchConfigs#ReverseSoftLimitEnable
376 * - SoftwareLimitSwitchConfigs#ForwardSoftLimitThreshold
377 * - SoftwareLimitSwitchConfigs#ReverseSoftLimitThreshold
378 *
379 */
381
382 /**
383 * \brief Configs for Motion Magic®.
384 *
385 * \details Includes Velocity, Acceleration, Jerk, and Expo
386 * parameters.
387 *
388 * Parameter list:
389 *
390 * - MotionMagicConfigs#MotionMagicCruiseVelocity
391 * - MotionMagicConfigs#MotionMagicAcceleration
392 * - MotionMagicConfigs#MotionMagicJerk
393 * - MotionMagicConfigs#MotionMagicExpo_kV
394 * - MotionMagicConfigs#MotionMagicExpo_kA
395 *
396 */
398
399 /**
400 * \brief Custom Params.
401 *
402 * \details Custom paramaters that have no real impact on controller.
403 *
404 * Parameter list:
405 *
406 * - CustomParamsConfigs#CustomParam0
407 * - CustomParamsConfigs#CustomParam1
408 *
409 */
411
412 /**
413 * \brief Configs that affect general behavior during closed-looping.
414 *
415 * \details Includes Continuous Wrap features.
416 *
417 * Parameter list:
418 *
419 * - ClosedLoopGeneralConfigs#ContinuousWrap
420 * - ClosedLoopGeneralConfigs#DifferentialContinuousWrap
421 * - ClosedLoopGeneralConfigs#GainSchedErrorThreshold
422 * - ClosedLoopGeneralConfigs#GainSchedKpBehavior
423 *
424 */
426
427 /**
428 * \brief Gains for the specified slot.
429 *
430 * \details If this slot is selected, these gains are used in closed
431 * loop control requests.
432 *
433 * Parameter list:
434 *
435 * - Slot0Configs#kP
436 * - Slot0Configs#kI
437 * - Slot0Configs#kD
438 * - Slot0Configs#kS
439 * - Slot0Configs#kV
440 * - Slot0Configs#kA
441 * - Slot0Configs#kG
442 * - Slot0Configs#GravityType
443 * - Slot0Configs#StaticFeedforwardSign
444 * - Slot0Configs#GravityArmPositionOffset
445 * - Slot0Configs#GainSchedBehavior
446 *
447 */
449
450 /**
451 * \brief Gains for the specified slot.
452 *
453 * \details If this slot is selected, these gains are used in closed
454 * loop control requests.
455 *
456 * Parameter list:
457 *
458 * - Slot1Configs#kP
459 * - Slot1Configs#kI
460 * - Slot1Configs#kD
461 * - Slot1Configs#kS
462 * - Slot1Configs#kV
463 * - Slot1Configs#kA
464 * - Slot1Configs#kG
465 * - Slot1Configs#GravityType
466 * - Slot1Configs#StaticFeedforwardSign
467 * - Slot1Configs#GravityArmPositionOffset
468 * - Slot1Configs#GainSchedBehavior
469 *
470 */
472
473 /**
474 * \brief Gains for the specified slot.
475 *
476 * \details If this slot is selected, these gains are used in closed
477 * loop control requests.
478 *
479 * Parameter list:
480 *
481 * - Slot2Configs#kP
482 * - Slot2Configs#kI
483 * - Slot2Configs#kD
484 * - Slot2Configs#kS
485 * - Slot2Configs#kV
486 * - Slot2Configs#kA
487 * - Slot2Configs#kG
488 * - Slot2Configs#GravityType
489 * - Slot2Configs#StaticFeedforwardSign
490 * - Slot2Configs#GravityArmPositionOffset
491 * - Slot2Configs#GainSchedBehavior
492 *
493 */
495
496 /**
497 * \brief Modifies this configuration's MotorOutput parameter and returns itself for
498 * method-chaining and easier to use config API.
499 *
500 * Configs that directly affect motor output.
501 *
502 * \details Includes motor invert, neutral mode, and other features
503 * related to motor output.
504 *
505 * Parameter list:
506 *
507 * - MotorOutputConfigs#Inverted
508 * - MotorOutputConfigs#NeutralMode
509 * - MotorOutputConfigs#DutyCycleNeutralDeadband
510 * - MotorOutputConfigs#PeakForwardDutyCycle
511 * - MotorOutputConfigs#PeakReverseDutyCycle
512 * - MotorOutputConfigs#ControlTimesyncFreqHz
513 *
514 *
515 * \param newMotorOutput Parameter to modify
516 * \returns Itself
517 */
519 {
520 MotorOutput = std::move(newMotorOutput);
521 return *this;
522 }
523
524 /**
525 * \brief Modifies this configuration's CurrentLimits parameter and returns itself for
526 * method-chaining and easier to use config API.
527 *
528 * Configs that directly affect current limiting features.
529 *
530 * \details Contains the supply/stator current limit thresholds and
531 * whether to enable them.
532 *
533 * Parameter list:
534 *
535 * - CurrentLimitsConfigs#StatorCurrentLimit
536 * - CurrentLimitsConfigs#StatorCurrentLimitEnable
537 * - CurrentLimitsConfigs#SupplyCurrentLimit
538 * - CurrentLimitsConfigs#SupplyCurrentLimitEnable
539 * - CurrentLimitsConfigs#SupplyCurrentLowerLimit
540 * - CurrentLimitsConfigs#SupplyCurrentLowerTime
541 *
542 *
543 * \param newCurrentLimits Parameter to modify
544 * \returns Itself
545 */
547 {
548 CurrentLimits = std::move(newCurrentLimits);
549 return *this;
550 }
551
552 /**
553 * \brief Modifies this configuration's Voltage parameter and returns itself for
554 * method-chaining and easier to use config API.
555 *
556 * Configs that affect Voltage control types.
557 *
558 * \details Includes peak output voltages and other configs affecting
559 * voltage measurements.
560 *
561 * Parameter list:
562 *
563 * - VoltageConfigs#SupplyVoltageTimeConstant
564 * - VoltageConfigs#PeakForwardVoltage
565 * - VoltageConfigs#PeakReverseVoltage
566 *
567 *
568 * \param newVoltage Parameter to modify
569 * \returns Itself
570 */
572 {
573 Voltage = std::move(newVoltage);
574 return *this;
575 }
576
577 /**
578 * \brief Modifies this configuration's TorqueCurrent parameter and returns itself for
579 * method-chaining and easier to use config API.
580 *
581 * Configs that affect Torque Current control types.
582 *
583 * \details Includes the maximum and minimum applied torque output and
584 * the neutral deadband used during TorqueCurrentFOC
585 * requests.
586 *
587 * Parameter list:
588 *
589 * - TorqueCurrentConfigs#PeakForwardTorqueCurrent
590 * - TorqueCurrentConfigs#PeakReverseTorqueCurrent
591 * - TorqueCurrentConfigs#TorqueNeutralDeadband
592 *
593 *
594 * \param newTorqueCurrent Parameter to modify
595 * \returns Itself
596 */
598 {
599 TorqueCurrent = std::move(newTorqueCurrent);
600 return *this;
601 }
602
603 /**
604 * \brief Modifies this configuration's Feedback parameter and returns itself for
605 * method-chaining and easier to use config API.
606 *
607 * Configs that affect the feedback of this motor controller.
608 *
609 * \details Includes feedback sensor source, any offsets for the
610 * feedback sensor, and various ratios to describe the
611 * relationship between the sensor and the mechanism for
612 * closed looping.
613 *
614 * Parameter list:
615 *
616 * - FeedbackConfigs#FeedbackRotorOffset
617 * - FeedbackConfigs#SensorToMechanismRatio
618 * - FeedbackConfigs#RotorToSensorRatio
619 * - FeedbackConfigs#FeedbackSensorSource
620 * - FeedbackConfigs#FeedbackRemoteSensorID
621 * - FeedbackConfigs#VelocityFilterTimeConstant
622 *
623 *
624 * \param newFeedback Parameter to modify
625 * \returns Itself
626 */
628 {
629 Feedback = std::move(newFeedback);
630 return *this;
631 }
632
633 /**
634 * \brief Modifies this configuration's DifferentialSensors parameter and returns itself for
635 * method-chaining and easier to use config API.
636 *
637 * Configs related to sensors used for differential control of a
638 * mechanism.
639 *
640 * \details Includes the differential sensor sources and IDs.
641 *
642 * Parameter list:
643 *
644 * - DifferentialSensorsConfigs#DifferentialSensorSource
645 * - DifferentialSensorsConfigs#DifferentialTalonFXSensorID
646 * - DifferentialSensorsConfigs#DifferentialRemoteSensorID
647 * - DifferentialSensorsConfigs#SensorToDifferentialRatio
648 *
649 *
650 * \param newDifferentialSensors Parameter to modify
651 * \returns Itself
652 */
654 {
655 DifferentialSensors = std::move(newDifferentialSensors);
656 return *this;
657 }
658
659 /**
660 * \brief Modifies this configuration's DifferentialConstants parameter and returns itself for
661 * method-chaining and easier to use config API.
662 *
663 * Configs related to constants used for differential control of a
664 * mechanism.
665 *
666 * \details Includes the differential peak outputs.
667 *
668 * Parameter list:
669 *
670 * - DifferentialConstantsConfigs#PeakDifferentialDutyCycle
671 * - DifferentialConstantsConfigs#PeakDifferentialVoltage
672 * - DifferentialConstantsConfigs#PeakDifferentialTorqueCurrent
673 *
674 *
675 * \param newDifferentialConstants Parameter to modify
676 * \returns Itself
677 */
679 {
680 DifferentialConstants = std::move(newDifferentialConstants);
681 return *this;
682 }
683
684 /**
685 * \brief Modifies this configuration's OpenLoopRamps parameter and returns itself for
686 * method-chaining and easier to use config API.
687 *
688 * Configs that affect the open-loop control of this motor controller.
689 *
690 * \details Open-loop ramp rates for the various control types.
691 *
692 * Parameter list:
693 *
694 * - OpenLoopRampsConfigs#DutyCycleOpenLoopRampPeriod
695 * - OpenLoopRampsConfigs#VoltageOpenLoopRampPeriod
696 * - OpenLoopRampsConfigs#TorqueOpenLoopRampPeriod
697 *
698 *
699 * \param newOpenLoopRamps Parameter to modify
700 * \returns Itself
701 */
703 {
704 OpenLoopRamps = std::move(newOpenLoopRamps);
705 return *this;
706 }
707
708 /**
709 * \brief Modifies this configuration's ClosedLoopRamps parameter and returns itself for
710 * method-chaining and easier to use config API.
711 *
712 * Configs that affect the closed-loop control of this motor
713 * controller.
714 *
715 * \details Closed-loop ramp rates for the various control types.
716 *
717 * Parameter list:
718 *
719 * - ClosedLoopRampsConfigs#DutyCycleClosedLoopRampPeriod
720 * - ClosedLoopRampsConfigs#VoltageClosedLoopRampPeriod
721 * - ClosedLoopRampsConfigs#TorqueClosedLoopRampPeriod
722 *
723 *
724 * \param newClosedLoopRamps Parameter to modify
725 * \returns Itself
726 */
728 {
729 ClosedLoopRamps = std::move(newClosedLoopRamps);
730 return *this;
731 }
732
733 /**
734 * \brief Modifies this configuration's HardwareLimitSwitch parameter and returns itself for
735 * method-chaining and easier to use config API.
736 *
737 * Configs that change how the motor controller behaves under
738 * different limit switch states.
739 *
740 * \details Includes configs such as enabling limit switches,
741 * configuring the remote sensor ID, the source, and the
742 * position to set on limit.
743 *
744 * Parameter list:
745 *
746 * - HardwareLimitSwitchConfigs#ForwardLimitType
747 * - HardwareLimitSwitchConfigs#ForwardLimitAutosetPositionEnable
748 * - HardwareLimitSwitchConfigs#ForwardLimitAutosetPositionValue
749 * - HardwareLimitSwitchConfigs#ForwardLimitEnable
750 * - HardwareLimitSwitchConfigs#ForwardLimitSource
751 * - HardwareLimitSwitchConfigs#ForwardLimitRemoteSensorID
752 * - HardwareLimitSwitchConfigs#ReverseLimitType
753 * - HardwareLimitSwitchConfigs#ReverseLimitAutosetPositionEnable
754 * - HardwareLimitSwitchConfigs#ReverseLimitAutosetPositionValue
755 * - HardwareLimitSwitchConfigs#ReverseLimitEnable
756 * - HardwareLimitSwitchConfigs#ReverseLimitSource
757 * - HardwareLimitSwitchConfigs#ReverseLimitRemoteSensorID
758 *
759 *
760 * \param newHardwareLimitSwitch Parameter to modify
761 * \returns Itself
762 */
764 {
765 HardwareLimitSwitch = std::move(newHardwareLimitSwitch);
766 return *this;
767 }
768
769 /**
770 * \brief Modifies this configuration's Audio parameter and returns itself for
771 * method-chaining and easier to use config API.
772 *
773 * Configs that affect audible components of the device.
774 *
775 * \details Includes configuration for the beep on boot.
776 *
777 * Parameter list:
778 *
779 * - AudioConfigs#BeepOnBoot
780 * - AudioConfigs#BeepOnConfig
781 * - AudioConfigs#AllowMusicDurDisable
782 *
783 *
784 * \param newAudio Parameter to modify
785 * \returns Itself
786 */
788 {
789 Audio = std::move(newAudio);
790 return *this;
791 }
792
793 /**
794 * \brief Modifies this configuration's SoftwareLimitSwitch parameter and returns itself for
795 * method-chaining and easier to use config API.
796 *
797 * Configs that affect how software-limit switches behave.
798 *
799 * \details Includes enabling software-limit switches and the
800 * threshold at which they are tripped.
801 *
802 * Parameter list:
803 *
804 * - SoftwareLimitSwitchConfigs#ForwardSoftLimitEnable
805 * - SoftwareLimitSwitchConfigs#ReverseSoftLimitEnable
806 * - SoftwareLimitSwitchConfigs#ForwardSoftLimitThreshold
807 * - SoftwareLimitSwitchConfigs#ReverseSoftLimitThreshold
808 *
809 *
810 * \param newSoftwareLimitSwitch Parameter to modify
811 * \returns Itself
812 */
814 {
815 SoftwareLimitSwitch = std::move(newSoftwareLimitSwitch);
816 return *this;
817 }
818
819 /**
820 * \brief Modifies this configuration's MotionMagic parameter and returns itself for
821 * method-chaining and easier to use config API.
822 *
823 * Configs for Motion Magic®.
824 *
825 * \details Includes Velocity, Acceleration, Jerk, and Expo
826 * parameters.
827 *
828 * Parameter list:
829 *
830 * - MotionMagicConfigs#MotionMagicCruiseVelocity
831 * - MotionMagicConfigs#MotionMagicAcceleration
832 * - MotionMagicConfigs#MotionMagicJerk
833 * - MotionMagicConfigs#MotionMagicExpo_kV
834 * - MotionMagicConfigs#MotionMagicExpo_kA
835 *
836 *
837 * \param newMotionMagic Parameter to modify
838 * \returns Itself
839 */
841 {
842 MotionMagic = std::move(newMotionMagic);
843 return *this;
844 }
845
846 /**
847 * \brief Modifies this configuration's CustomParams parameter and returns itself for
848 * method-chaining and easier to use config API.
849 *
850 * Custom Params.
851 *
852 * \details Custom paramaters that have no real impact on controller.
853 *
854 * Parameter list:
855 *
856 * - CustomParamsConfigs#CustomParam0
857 * - CustomParamsConfigs#CustomParam1
858 *
859 *
860 * \param newCustomParams Parameter to modify
861 * \returns Itself
862 */
864 {
865 CustomParams = std::move(newCustomParams);
866 return *this;
867 }
868
869 /**
870 * \brief Modifies this configuration's ClosedLoopGeneral parameter and returns itself for
871 * method-chaining and easier to use config API.
872 *
873 * Configs that affect general behavior during closed-looping.
874 *
875 * \details Includes Continuous Wrap features.
876 *
877 * Parameter list:
878 *
879 * - ClosedLoopGeneralConfigs#ContinuousWrap
880 * - ClosedLoopGeneralConfigs#DifferentialContinuousWrap
881 * - ClosedLoopGeneralConfigs#GainSchedErrorThreshold
882 * - ClosedLoopGeneralConfigs#GainSchedKpBehavior
883 *
884 *
885 * \param newClosedLoopGeneral Parameter to modify
886 * \returns Itself
887 */
889 {
890 ClosedLoopGeneral = std::move(newClosedLoopGeneral);
891 return *this;
892 }
893
894 /**
895 * \brief Modifies this configuration's Slot0 parameter and returns itself for
896 * method-chaining and easier to use config API.
897 *
898 * Gains for the specified slot.
899 *
900 * \details If this slot is selected, these gains are used in closed
901 * loop control requests.
902 *
903 * Parameter list:
904 *
905 * - Slot0Configs#kP
906 * - Slot0Configs#kI
907 * - Slot0Configs#kD
908 * - Slot0Configs#kS
909 * - Slot0Configs#kV
910 * - Slot0Configs#kA
911 * - Slot0Configs#kG
912 * - Slot0Configs#GravityType
913 * - Slot0Configs#StaticFeedforwardSign
914 * - Slot0Configs#GravityArmPositionOffset
915 * - Slot0Configs#GainSchedBehavior
916 *
917 *
918 * \param newSlot0 Parameter to modify
919 * \returns Itself
920 */
922 {
923 Slot0 = std::move(newSlot0);
924 return *this;
925 }
926
927 /**
928 * \brief Modifies this configuration's Slot1 parameter and returns itself for
929 * method-chaining and easier to use config API.
930 *
931 * Gains for the specified slot.
932 *
933 * \details If this slot is selected, these gains are used in closed
934 * loop control requests.
935 *
936 * Parameter list:
937 *
938 * - Slot1Configs#kP
939 * - Slot1Configs#kI
940 * - Slot1Configs#kD
941 * - Slot1Configs#kS
942 * - Slot1Configs#kV
943 * - Slot1Configs#kA
944 * - Slot1Configs#kG
945 * - Slot1Configs#GravityType
946 * - Slot1Configs#StaticFeedforwardSign
947 * - Slot1Configs#GravityArmPositionOffset
948 * - Slot1Configs#GainSchedBehavior
949 *
950 *
951 * \param newSlot1 Parameter to modify
952 * \returns Itself
953 */
955 {
956 Slot1 = std::move(newSlot1);
957 return *this;
958 }
959
960 /**
961 * \brief Modifies this configuration's Slot2 parameter and returns itself for
962 * method-chaining and easier to use config API.
963 *
964 * Gains for the specified slot.
965 *
966 * \details If this slot is selected, these gains are used in closed
967 * loop control requests.
968 *
969 * Parameter list:
970 *
971 * - Slot2Configs#kP
972 * - Slot2Configs#kI
973 * - Slot2Configs#kD
974 * - Slot2Configs#kS
975 * - Slot2Configs#kV
976 * - Slot2Configs#kA
977 * - Slot2Configs#kG
978 * - Slot2Configs#GravityType
979 * - Slot2Configs#StaticFeedforwardSign
980 * - Slot2Configs#GravityArmPositionOffset
981 * - Slot2Configs#GainSchedBehavior
982 *
983 *
984 * \param newSlot2 Parameter to modify
985 * \returns Itself
986 */
988 {
989 Slot2 = std::move(newSlot2);
990 return *this;
991 }
992
993 /**
994 * \brief Get the string representation of this configuration
995 */
996 std::string ToString() const override;
997
998 /**
999 * \brief Get the serialized form of this configuration
1000 */
1001 std::string Serialize() const final;
1002 /**
1003 * \brief Take a string and deserialize it to this configuration
1004 */
1005 ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final;
1006};
1007
1008/**
1009 * Class description for the Talon FX integrated motor controller.
1010 *
1011 * This handles applying and refreshing configurations for the hardware#TalonFX.
1012 */
1014{
1015private:
1017 ParentConfigurator{std::move(id)}
1018 {}
1019
1021
1022public:
1023 /**
1024 * \brief Refreshes the values of the specified config group.
1025 *
1026 * This will wait up to #DefaultTimeoutSeconds.
1027 *
1028 * \details Call to refresh the selected configs from the device.
1029 *
1030 * \param configs The configs to refresh
1031 * \returns StatusCode of refreshing the configs
1032 */
1034 {
1035 return Refresh(configs, DefaultTimeoutSeconds);
1036 }
1037
1038 /**
1039 * \brief Refreshes the values of the specified config group.
1040 *
1041 * \details Call to refresh the selected configs from the device.
1042 *
1043 * \param configs The configs to refresh
1044 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1045 * \returns StatusCode of refreshing the configs
1046 */
1047 ctre::phoenix::StatusCode Refresh(TalonFXConfiguration &configs, units::time::second_t timeoutSeconds) const
1048 {
1049 std::string ref;
1050 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1051 configs.Deserialize(ref);
1052 return ret;
1053 }
1054
1055 /**
1056 * \brief Applies the contents of the specified config to the device.
1057 *
1058 * This will wait up to #DefaultTimeoutSeconds.
1059 *
1060 * \details Call to apply the selected configs.
1061 *
1062 * \param configs Configs to apply against.
1063 * \returns StatusCode of the set command
1064 */
1066 {
1067 return Apply(configs, DefaultTimeoutSeconds);
1068 }
1069
1070 /**
1071 * \brief Applies the contents of the specified config to the device.
1072 *
1073 * \details Call to apply the selected configs.
1074 *
1075 * \param configs Configs to apply against.
1076 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1077 * \returns StatusCode of the set command
1078 */
1079 ctre::phoenix::StatusCode Apply(const TalonFXConfiguration &configs, units::time::second_t timeoutSeconds)
1080 {
1081 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, configs.FutureProofConfigs, false);
1082 }
1083
1084
1085 /**
1086 * \brief Refreshes the values of the specified config group.
1087 *
1088 * This will wait up to #DefaultTimeoutSeconds.
1089 *
1090 * \details Call to refresh the selected configs from the device.
1091 *
1092 * \param configs The configs to refresh
1093 * \returns StatusCode of refreshing the configs
1094 */
1096 {
1097 return Refresh(configs, DefaultTimeoutSeconds);
1098 }
1099 /**
1100 * \brief Refreshes the values of the specified config group.
1101 *
1102 * \details Call to refresh the selected configs from the device.
1103 *
1104 * \param configs The configs to refresh
1105 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1106 * \returns StatusCode of refreshing the configs
1107 */
1108 ctre::phoenix::StatusCode Refresh(MotorOutputConfigs &configs, units::time::second_t timeoutSeconds) const
1109 {
1110 std::string ref;
1111 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1112 configs.Deserialize(ref);
1113 return ret;
1114 }
1115
1116 /**
1117 * \brief Applies the contents of the specified config to the device.
1118 *
1119 * This will wait up to #DefaultTimeoutSeconds.
1120 *
1121 * \details Call to apply the selected configs.
1122 *
1123 * \param configs Configs to apply against.
1124 * \returns StatusCode of the set command
1125 */
1127 {
1128 return Apply(configs, DefaultTimeoutSeconds);
1129 }
1130
1131 /**
1132 * \brief Applies the contents of the specified config to the device.
1133 *
1134 * \details Call to apply the selected configs.
1135 *
1136 * \param configs Configs to apply against.
1137 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1138 * \returns StatusCode of the set command
1139 */
1140 ctre::phoenix::StatusCode Apply(const MotorOutputConfigs &configs, units::time::second_t timeoutSeconds)
1141 {
1142 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1143 }
1144
1145 /**
1146 * \brief Refreshes the values of the specified config group.
1147 *
1148 * This will wait up to #DefaultTimeoutSeconds.
1149 *
1150 * \details Call to refresh the selected configs from the device.
1151 *
1152 * \param configs The configs to refresh
1153 * \returns StatusCode of refreshing the configs
1154 */
1156 {
1157 return Refresh(configs, DefaultTimeoutSeconds);
1158 }
1159 /**
1160 * \brief Refreshes the values of the specified config group.
1161 *
1162 * \details Call to refresh the selected configs from the device.
1163 *
1164 * \param configs The configs to refresh
1165 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1166 * \returns StatusCode of refreshing the configs
1167 */
1168 ctre::phoenix::StatusCode Refresh(CurrentLimitsConfigs &configs, units::time::second_t timeoutSeconds) const
1169 {
1170 std::string ref;
1171 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1172 configs.Deserialize(ref);
1173 return ret;
1174 }
1175
1176 /**
1177 * \brief Applies the contents of the specified config to the device.
1178 *
1179 * This will wait up to #DefaultTimeoutSeconds.
1180 *
1181 * \details Call to apply the selected configs.
1182 *
1183 * \param configs Configs to apply against.
1184 * \returns StatusCode of the set command
1185 */
1187 {
1188 return Apply(configs, DefaultTimeoutSeconds);
1189 }
1190
1191 /**
1192 * \brief Applies the contents of the specified config to the device.
1193 *
1194 * \details Call to apply the selected configs.
1195 *
1196 * \param configs Configs to apply against.
1197 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1198 * \returns StatusCode of the set command
1199 */
1200 ctre::phoenix::StatusCode Apply(const CurrentLimitsConfigs &configs, units::time::second_t timeoutSeconds)
1201 {
1202 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1203 }
1204
1205 /**
1206 * \brief Refreshes the values of the specified config group.
1207 *
1208 * This will wait up to #DefaultTimeoutSeconds.
1209 *
1210 * \details Call to refresh the selected configs from the device.
1211 *
1212 * \param configs The configs to refresh
1213 * \returns StatusCode of refreshing the configs
1214 */
1216 {
1217 return Refresh(configs, DefaultTimeoutSeconds);
1218 }
1219 /**
1220 * \brief Refreshes the values of the specified config group.
1221 *
1222 * \details Call to refresh the selected configs from the device.
1223 *
1224 * \param configs The configs to refresh
1225 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1226 * \returns StatusCode of refreshing the configs
1227 */
1228 ctre::phoenix::StatusCode Refresh(VoltageConfigs &configs, units::time::second_t timeoutSeconds) const
1229 {
1230 std::string ref;
1231 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1232 configs.Deserialize(ref);
1233 return ret;
1234 }
1235
1236 /**
1237 * \brief Applies the contents of the specified config to the device.
1238 *
1239 * This will wait up to #DefaultTimeoutSeconds.
1240 *
1241 * \details Call to apply the selected configs.
1242 *
1243 * \param configs Configs to apply against.
1244 * \returns StatusCode of the set command
1245 */
1247 {
1248 return Apply(configs, DefaultTimeoutSeconds);
1249 }
1250
1251 /**
1252 * \brief Applies the contents of the specified config to the device.
1253 *
1254 * \details Call to apply the selected configs.
1255 *
1256 * \param configs Configs to apply against.
1257 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1258 * \returns StatusCode of the set command
1259 */
1260 ctre::phoenix::StatusCode Apply(const VoltageConfigs &configs, units::time::second_t timeoutSeconds)
1261 {
1262 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1263 }
1264
1265 /**
1266 * \brief Refreshes the values of the specified config group.
1267 *
1268 * This will wait up to #DefaultTimeoutSeconds.
1269 *
1270 * \details Call to refresh the selected configs from the device.
1271 *
1272 * \param configs The configs to refresh
1273 * \returns StatusCode of refreshing the configs
1274 */
1276 {
1277 return Refresh(configs, DefaultTimeoutSeconds);
1278 }
1279 /**
1280 * \brief Refreshes the values of the specified config group.
1281 *
1282 * \details Call to refresh the selected configs from the device.
1283 *
1284 * \param configs The configs to refresh
1285 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1286 * \returns StatusCode of refreshing the configs
1287 */
1288 ctre::phoenix::StatusCode Refresh(TorqueCurrentConfigs &configs, units::time::second_t timeoutSeconds) const
1289 {
1290 std::string ref;
1291 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1292 configs.Deserialize(ref);
1293 return ret;
1294 }
1295
1296 /**
1297 * \brief Applies the contents of the specified config to the device.
1298 *
1299 * This will wait up to #DefaultTimeoutSeconds.
1300 *
1301 * \details Call to apply the selected configs.
1302 *
1303 * \param configs Configs to apply against.
1304 * \returns StatusCode of the set command
1305 */
1307 {
1308 return Apply(configs, DefaultTimeoutSeconds);
1309 }
1310
1311 /**
1312 * \brief Applies the contents of the specified config to the device.
1313 *
1314 * \details Call to apply the selected configs.
1315 *
1316 * \param configs Configs to apply against.
1317 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1318 * \returns StatusCode of the set command
1319 */
1320 ctre::phoenix::StatusCode Apply(const TorqueCurrentConfigs &configs, units::time::second_t timeoutSeconds)
1321 {
1322 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1323 }
1324
1325 /**
1326 * \brief Refreshes the values of the specified config group.
1327 *
1328 * This will wait up to #DefaultTimeoutSeconds.
1329 *
1330 * \details Call to refresh the selected configs from the device.
1331 *
1332 * \param configs The configs to refresh
1333 * \returns StatusCode of refreshing the configs
1334 */
1336 {
1337 return Refresh(configs, DefaultTimeoutSeconds);
1338 }
1339 /**
1340 * \brief Refreshes the values of the specified config group.
1341 *
1342 * \details Call to refresh the selected configs from the device.
1343 *
1344 * \param configs The configs to refresh
1345 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1346 * \returns StatusCode of refreshing the configs
1347 */
1348 ctre::phoenix::StatusCode Refresh(FeedbackConfigs &configs, units::time::second_t timeoutSeconds) const
1349 {
1350 std::string ref;
1351 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1352 configs.Deserialize(ref);
1353 return ret;
1354 }
1355
1356 /**
1357 * \brief Applies the contents of the specified config to the device.
1358 *
1359 * This will wait up to #DefaultTimeoutSeconds.
1360 *
1361 * \details Call to apply the selected configs.
1362 *
1363 * \param configs Configs to apply against.
1364 * \returns StatusCode of the set command
1365 */
1367 {
1368 return Apply(configs, DefaultTimeoutSeconds);
1369 }
1370
1371 /**
1372 * \brief Applies the contents of the specified config to the device.
1373 *
1374 * \details Call to apply the selected configs.
1375 *
1376 * \param configs Configs to apply against.
1377 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1378 * \returns StatusCode of the set command
1379 */
1380 ctre::phoenix::StatusCode Apply(const FeedbackConfigs &configs, units::time::second_t timeoutSeconds)
1381 {
1382 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1383 }
1384
1385 /**
1386 * \brief Refreshes the values of the specified config group.
1387 *
1388 * This will wait up to #DefaultTimeoutSeconds.
1389 *
1390 * \details Call to refresh the selected configs from the device.
1391 *
1392 * \param configs The configs to refresh
1393 * \returns StatusCode of refreshing the configs
1394 */
1396 {
1397 return Refresh(configs, DefaultTimeoutSeconds);
1398 }
1399 /**
1400 * \brief Refreshes the values of the specified config group.
1401 *
1402 * \details Call to refresh the selected configs from the device.
1403 *
1404 * \param configs The configs to refresh
1405 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1406 * \returns StatusCode of refreshing the configs
1407 */
1408 ctre::phoenix::StatusCode Refresh(DifferentialSensorsConfigs &configs, units::time::second_t timeoutSeconds) const
1409 {
1410 std::string ref;
1411 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1412 configs.Deserialize(ref);
1413 return ret;
1414 }
1415
1416 /**
1417 * \brief Applies the contents of the specified config to the device.
1418 *
1419 * This will wait up to #DefaultTimeoutSeconds.
1420 *
1421 * \details Call to apply the selected configs.
1422 *
1423 * \param configs Configs to apply against.
1424 * \returns StatusCode of the set command
1425 */
1427 {
1428 return Apply(configs, DefaultTimeoutSeconds);
1429 }
1430
1431 /**
1432 * \brief Applies the contents of the specified config to the device.
1433 *
1434 * \details Call to apply the selected configs.
1435 *
1436 * \param configs Configs to apply against.
1437 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1438 * \returns StatusCode of the set command
1439 */
1440 ctre::phoenix::StatusCode Apply(const DifferentialSensorsConfigs &configs, units::time::second_t timeoutSeconds)
1441 {
1442 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1443 }
1444
1445 /**
1446 * \brief Refreshes the values of the specified config group.
1447 *
1448 * This will wait up to #DefaultTimeoutSeconds.
1449 *
1450 * \details Call to refresh the selected configs from the device.
1451 *
1452 * \param configs The configs to refresh
1453 * \returns StatusCode of refreshing the configs
1454 */
1456 {
1457 return Refresh(configs, DefaultTimeoutSeconds);
1458 }
1459 /**
1460 * \brief Refreshes the values of the specified config group.
1461 *
1462 * \details Call to refresh the selected configs from the device.
1463 *
1464 * \param configs The configs to refresh
1465 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1466 * \returns StatusCode of refreshing the configs
1467 */
1468 ctre::phoenix::StatusCode Refresh(DifferentialConstantsConfigs &configs, units::time::second_t timeoutSeconds) const
1469 {
1470 std::string ref;
1471 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1472 configs.Deserialize(ref);
1473 return ret;
1474 }
1475
1476 /**
1477 * \brief Applies the contents of the specified config to the device.
1478 *
1479 * This will wait up to #DefaultTimeoutSeconds.
1480 *
1481 * \details Call to apply the selected configs.
1482 *
1483 * \param configs Configs to apply against.
1484 * \returns StatusCode of the set command
1485 */
1487 {
1488 return Apply(configs, DefaultTimeoutSeconds);
1489 }
1490
1491 /**
1492 * \brief Applies the contents of the specified config to the device.
1493 *
1494 * \details Call to apply the selected configs.
1495 *
1496 * \param configs Configs to apply against.
1497 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1498 * \returns StatusCode of the set command
1499 */
1500 ctre::phoenix::StatusCode Apply(const DifferentialConstantsConfigs &configs, units::time::second_t timeoutSeconds)
1501 {
1502 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1503 }
1504
1505 /**
1506 * \brief Refreshes the values of the specified config group.
1507 *
1508 * This will wait up to #DefaultTimeoutSeconds.
1509 *
1510 * \details Call to refresh the selected configs from the device.
1511 *
1512 * \param configs The configs to refresh
1513 * \returns StatusCode of refreshing the configs
1514 */
1516 {
1517 return Refresh(configs, DefaultTimeoutSeconds);
1518 }
1519 /**
1520 * \brief Refreshes the values of the specified config group.
1521 *
1522 * \details Call to refresh the selected configs from the device.
1523 *
1524 * \param configs The configs to refresh
1525 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1526 * \returns StatusCode of refreshing the configs
1527 */
1528 ctre::phoenix::StatusCode Refresh(OpenLoopRampsConfigs &configs, units::time::second_t timeoutSeconds) const
1529 {
1530 std::string ref;
1531 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1532 configs.Deserialize(ref);
1533 return ret;
1534 }
1535
1536 /**
1537 * \brief Applies the contents of the specified config to the device.
1538 *
1539 * This will wait up to #DefaultTimeoutSeconds.
1540 *
1541 * \details Call to apply the selected configs.
1542 *
1543 * \param configs Configs to apply against.
1544 * \returns StatusCode of the set command
1545 */
1547 {
1548 return Apply(configs, DefaultTimeoutSeconds);
1549 }
1550
1551 /**
1552 * \brief Applies the contents of the specified config to the device.
1553 *
1554 * \details Call to apply the selected configs.
1555 *
1556 * \param configs Configs to apply against.
1557 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1558 * \returns StatusCode of the set command
1559 */
1560 ctre::phoenix::StatusCode Apply(const OpenLoopRampsConfigs &configs, units::time::second_t timeoutSeconds)
1561 {
1562 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1563 }
1564
1565 /**
1566 * \brief Refreshes the values of the specified config group.
1567 *
1568 * This will wait up to #DefaultTimeoutSeconds.
1569 *
1570 * \details Call to refresh the selected configs from the device.
1571 *
1572 * \param configs The configs to refresh
1573 * \returns StatusCode of refreshing the configs
1574 */
1576 {
1577 return Refresh(configs, DefaultTimeoutSeconds);
1578 }
1579 /**
1580 * \brief Refreshes the values of the specified config group.
1581 *
1582 * \details Call to refresh the selected configs from the device.
1583 *
1584 * \param configs The configs to refresh
1585 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1586 * \returns StatusCode of refreshing the configs
1587 */
1588 ctre::phoenix::StatusCode Refresh(ClosedLoopRampsConfigs &configs, units::time::second_t timeoutSeconds) const
1589 {
1590 std::string ref;
1591 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1592 configs.Deserialize(ref);
1593 return ret;
1594 }
1595
1596 /**
1597 * \brief Applies the contents of the specified config to the device.
1598 *
1599 * This will wait up to #DefaultTimeoutSeconds.
1600 *
1601 * \details Call to apply the selected configs.
1602 *
1603 * \param configs Configs to apply against.
1604 * \returns StatusCode of the set command
1605 */
1607 {
1608 return Apply(configs, DefaultTimeoutSeconds);
1609 }
1610
1611 /**
1612 * \brief Applies the contents of the specified config to the device.
1613 *
1614 * \details Call to apply the selected configs.
1615 *
1616 * \param configs Configs to apply against.
1617 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1618 * \returns StatusCode of the set command
1619 */
1620 ctre::phoenix::StatusCode Apply(const ClosedLoopRampsConfigs &configs, units::time::second_t timeoutSeconds)
1621 {
1622 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1623 }
1624
1625 /**
1626 * \brief Refreshes the values of the specified config group.
1627 *
1628 * This will wait up to #DefaultTimeoutSeconds.
1629 *
1630 * \details Call to refresh the selected configs from the device.
1631 *
1632 * \param configs The configs to refresh
1633 * \returns StatusCode of refreshing the configs
1634 */
1636 {
1637 return Refresh(configs, DefaultTimeoutSeconds);
1638 }
1639 /**
1640 * \brief Refreshes the values of the specified config group.
1641 *
1642 * \details Call to refresh the selected configs from the device.
1643 *
1644 * \param configs The configs to refresh
1645 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1646 * \returns StatusCode of refreshing the configs
1647 */
1648 ctre::phoenix::StatusCode Refresh(HardwareLimitSwitchConfigs &configs, units::time::second_t timeoutSeconds) const
1649 {
1650 std::string ref;
1651 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1652 configs.Deserialize(ref);
1653 return ret;
1654 }
1655
1656 /**
1657 * \brief Applies the contents of the specified config to the device.
1658 *
1659 * This will wait up to #DefaultTimeoutSeconds.
1660 *
1661 * \details Call to apply the selected configs.
1662 *
1663 * \param configs Configs to apply against.
1664 * \returns StatusCode of the set command
1665 */
1667 {
1668 return Apply(configs, DefaultTimeoutSeconds);
1669 }
1670
1671 /**
1672 * \brief Applies the contents of the specified config to the device.
1673 *
1674 * \details Call to apply the selected configs.
1675 *
1676 * \param configs Configs to apply against.
1677 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1678 * \returns StatusCode of the set command
1679 */
1680 ctre::phoenix::StatusCode Apply(const HardwareLimitSwitchConfigs &configs, units::time::second_t timeoutSeconds)
1681 {
1682 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1683 }
1684
1685 /**
1686 * \brief Refreshes the values of the specified config group.
1687 *
1688 * This will wait up to #DefaultTimeoutSeconds.
1689 *
1690 * \details Call to refresh the selected configs from the device.
1691 *
1692 * \param configs The configs to refresh
1693 * \returns StatusCode of refreshing the configs
1694 */
1696 {
1697 return Refresh(configs, DefaultTimeoutSeconds);
1698 }
1699 /**
1700 * \brief Refreshes the values of the specified config group.
1701 *
1702 * \details Call to refresh the selected configs from the device.
1703 *
1704 * \param configs The configs to refresh
1705 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1706 * \returns StatusCode of refreshing the configs
1707 */
1708 ctre::phoenix::StatusCode Refresh(AudioConfigs &configs, units::time::second_t timeoutSeconds) const
1709 {
1710 std::string ref;
1711 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1712 configs.Deserialize(ref);
1713 return ret;
1714 }
1715
1716 /**
1717 * \brief Applies the contents of the specified config to the device.
1718 *
1719 * This will wait up to #DefaultTimeoutSeconds.
1720 *
1721 * \details Call to apply the selected configs.
1722 *
1723 * \param configs Configs to apply against.
1724 * \returns StatusCode of the set command
1725 */
1727 {
1728 return Apply(configs, DefaultTimeoutSeconds);
1729 }
1730
1731 /**
1732 * \brief Applies the contents of the specified config to the device.
1733 *
1734 * \details Call to apply the selected configs.
1735 *
1736 * \param configs Configs to apply against.
1737 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1738 * \returns StatusCode of the set command
1739 */
1740 ctre::phoenix::StatusCode Apply(const AudioConfigs &configs, units::time::second_t timeoutSeconds)
1741 {
1742 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1743 }
1744
1745 /**
1746 * \brief Refreshes the values of the specified config group.
1747 *
1748 * This will wait up to #DefaultTimeoutSeconds.
1749 *
1750 * \details Call to refresh the selected configs from the device.
1751 *
1752 * \param configs The configs to refresh
1753 * \returns StatusCode of refreshing the configs
1754 */
1756 {
1757 return Refresh(configs, DefaultTimeoutSeconds);
1758 }
1759 /**
1760 * \brief Refreshes the values of the specified config group.
1761 *
1762 * \details Call to refresh the selected configs from the device.
1763 *
1764 * \param configs The configs to refresh
1765 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1766 * \returns StatusCode of refreshing the configs
1767 */
1768 ctre::phoenix::StatusCode Refresh(SoftwareLimitSwitchConfigs &configs, units::time::second_t timeoutSeconds) const
1769 {
1770 std::string ref;
1771 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1772 configs.Deserialize(ref);
1773 return ret;
1774 }
1775
1776 /**
1777 * \brief Applies the contents of the specified config to the device.
1778 *
1779 * This will wait up to #DefaultTimeoutSeconds.
1780 *
1781 * \details Call to apply the selected configs.
1782 *
1783 * \param configs Configs to apply against.
1784 * \returns StatusCode of the set command
1785 */
1787 {
1788 return Apply(configs, DefaultTimeoutSeconds);
1789 }
1790
1791 /**
1792 * \brief Applies the contents of the specified config to the device.
1793 *
1794 * \details Call to apply the selected configs.
1795 *
1796 * \param configs Configs to apply against.
1797 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1798 * \returns StatusCode of the set command
1799 */
1800 ctre::phoenix::StatusCode Apply(const SoftwareLimitSwitchConfigs &configs, units::time::second_t timeoutSeconds)
1801 {
1802 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1803 }
1804
1805 /**
1806 * \brief Refreshes the values of the specified config group.
1807 *
1808 * This will wait up to #DefaultTimeoutSeconds.
1809 *
1810 * \details Call to refresh the selected configs from the device.
1811 *
1812 * \param configs The configs to refresh
1813 * \returns StatusCode of refreshing the configs
1814 */
1816 {
1817 return Refresh(configs, DefaultTimeoutSeconds);
1818 }
1819 /**
1820 * \brief Refreshes the values of the specified config group.
1821 *
1822 * \details Call to refresh the selected configs from the device.
1823 *
1824 * \param configs The configs to refresh
1825 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1826 * \returns StatusCode of refreshing the configs
1827 */
1828 ctre::phoenix::StatusCode Refresh(MotionMagicConfigs &configs, units::time::second_t timeoutSeconds) const
1829 {
1830 std::string ref;
1831 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1832 configs.Deserialize(ref);
1833 return ret;
1834 }
1835
1836 /**
1837 * \brief Applies the contents of the specified config to the device.
1838 *
1839 * This will wait up to #DefaultTimeoutSeconds.
1840 *
1841 * \details Call to apply the selected configs.
1842 *
1843 * \param configs Configs to apply against.
1844 * \returns StatusCode of the set command
1845 */
1847 {
1848 return Apply(configs, DefaultTimeoutSeconds);
1849 }
1850
1851 /**
1852 * \brief Applies the contents of the specified config to the device.
1853 *
1854 * \details Call to apply the selected configs.
1855 *
1856 * \param configs Configs to apply against.
1857 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1858 * \returns StatusCode of the set command
1859 */
1860 ctre::phoenix::StatusCode Apply(const MotionMagicConfigs &configs, units::time::second_t timeoutSeconds)
1861 {
1862 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1863 }
1864
1865 /**
1866 * \brief Refreshes the values of the specified config group.
1867 *
1868 * This will wait up to #DefaultTimeoutSeconds.
1869 *
1870 * \details Call to refresh the selected configs from the device.
1871 *
1872 * \param configs The configs to refresh
1873 * \returns StatusCode of refreshing the configs
1874 */
1876 {
1877 return Refresh(configs, DefaultTimeoutSeconds);
1878 }
1879 /**
1880 * \brief Refreshes the values of the specified config group.
1881 *
1882 * \details Call to refresh the selected configs from the device.
1883 *
1884 * \param configs The configs to refresh
1885 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1886 * \returns StatusCode of refreshing the configs
1887 */
1888 ctre::phoenix::StatusCode Refresh(CustomParamsConfigs &configs, units::time::second_t timeoutSeconds) const
1889 {
1890 std::string ref;
1891 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1892 configs.Deserialize(ref);
1893 return ret;
1894 }
1895
1896 /**
1897 * \brief Applies the contents of the specified config to the device.
1898 *
1899 * This will wait up to #DefaultTimeoutSeconds.
1900 *
1901 * \details Call to apply the selected configs.
1902 *
1903 * \param configs Configs to apply against.
1904 * \returns StatusCode of the set command
1905 */
1907 {
1908 return Apply(configs, DefaultTimeoutSeconds);
1909 }
1910
1911 /**
1912 * \brief Applies the contents of the specified config to the device.
1913 *
1914 * \details Call to apply the selected configs.
1915 *
1916 * \param configs Configs to apply against.
1917 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1918 * \returns StatusCode of the set command
1919 */
1920 ctre::phoenix::StatusCode Apply(const CustomParamsConfigs &configs, units::time::second_t timeoutSeconds)
1921 {
1922 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1923 }
1924
1925 /**
1926 * \brief Refreshes the values of the specified config group.
1927 *
1928 * This will wait up to #DefaultTimeoutSeconds.
1929 *
1930 * \details Call to refresh the selected configs from the device.
1931 *
1932 * \param configs The configs to refresh
1933 * \returns StatusCode of refreshing the configs
1934 */
1936 {
1937 return Refresh(configs, DefaultTimeoutSeconds);
1938 }
1939 /**
1940 * \brief Refreshes the values of the specified config group.
1941 *
1942 * \details Call to refresh the selected configs from the device.
1943 *
1944 * \param configs The configs to refresh
1945 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1946 * \returns StatusCode of refreshing the configs
1947 */
1948 ctre::phoenix::StatusCode Refresh(ClosedLoopGeneralConfigs &configs, units::time::second_t timeoutSeconds) const
1949 {
1950 std::string ref;
1951 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
1952 configs.Deserialize(ref);
1953 return ret;
1954 }
1955
1956 /**
1957 * \brief Applies the contents of the specified config to the device.
1958 *
1959 * This will wait up to #DefaultTimeoutSeconds.
1960 *
1961 * \details Call to apply the selected configs.
1962 *
1963 * \param configs Configs to apply against.
1964 * \returns StatusCode of the set command
1965 */
1967 {
1968 return Apply(configs, DefaultTimeoutSeconds);
1969 }
1970
1971 /**
1972 * \brief Applies the contents of the specified config to the device.
1973 *
1974 * \details Call to apply the selected configs.
1975 *
1976 * \param configs Configs to apply against.
1977 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
1978 * \returns StatusCode of the set command
1979 */
1980 ctre::phoenix::StatusCode Apply(const ClosedLoopGeneralConfigs &configs, units::time::second_t timeoutSeconds)
1981 {
1982 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
1983 }
1984
1985 /**
1986 * \brief Refreshes the values of the specified config group.
1987 *
1988 * This will wait up to #DefaultTimeoutSeconds.
1989 *
1990 * \details Call to refresh the selected configs from the device.
1991 *
1992 * \param configs The configs to refresh
1993 * \returns StatusCode of refreshing the configs
1994 */
1996 {
1997 return Refresh(configs, DefaultTimeoutSeconds);
1998 }
1999 /**
2000 * \brief Refreshes the values of the specified config group.
2001 *
2002 * \details Call to refresh the selected configs from the device.
2003 *
2004 * \param configs The configs to refresh
2005 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
2006 * \returns StatusCode of refreshing the configs
2007 */
2008 ctre::phoenix::StatusCode Refresh(Slot0Configs &configs, units::time::second_t timeoutSeconds) const
2009 {
2010 std::string ref;
2011 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
2012 configs.Deserialize(ref);
2013 return ret;
2014 }
2015
2016 /**
2017 * \brief Applies the contents of the specified config to the device.
2018 *
2019 * This will wait up to #DefaultTimeoutSeconds.
2020 *
2021 * \details Call to apply the selected configs.
2022 *
2023 * \param configs Configs to apply against.
2024 * \returns StatusCode of the set command
2025 */
2027 {
2028 return Apply(configs, DefaultTimeoutSeconds);
2029 }
2030
2031 /**
2032 * \brief Applies the contents of the specified config to the device.
2033 *
2034 * \details Call to apply the selected configs.
2035 *
2036 * \param configs Configs to apply against.
2037 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
2038 * \returns StatusCode of the set command
2039 */
2040 ctre::phoenix::StatusCode Apply(const Slot0Configs &configs, units::time::second_t timeoutSeconds)
2041 {
2042 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
2043 }
2044
2045 /**
2046 * \brief Refreshes the values of the specified config group.
2047 *
2048 * This will wait up to #DefaultTimeoutSeconds.
2049 *
2050 * \details Call to refresh the selected configs from the device.
2051 *
2052 * \param configs The configs to refresh
2053 * \returns StatusCode of refreshing the configs
2054 */
2056 {
2057 return Refresh(configs, DefaultTimeoutSeconds);
2058 }
2059 /**
2060 * \brief Refreshes the values of the specified config group.
2061 *
2062 * \details Call to refresh the selected configs from the device.
2063 *
2064 * \param configs The configs to refresh
2065 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
2066 * \returns StatusCode of refreshing the configs
2067 */
2068 ctre::phoenix::StatusCode Refresh(Slot1Configs &configs, units::time::second_t timeoutSeconds) const
2069 {
2070 std::string ref;
2071 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
2072 configs.Deserialize(ref);
2073 return ret;
2074 }
2075
2076 /**
2077 * \brief Applies the contents of the specified config to the device.
2078 *
2079 * This will wait up to #DefaultTimeoutSeconds.
2080 *
2081 * \details Call to apply the selected configs.
2082 *
2083 * \param configs Configs to apply against.
2084 * \returns StatusCode of the set command
2085 */
2087 {
2088 return Apply(configs, DefaultTimeoutSeconds);
2089 }
2090
2091 /**
2092 * \brief Applies the contents of the specified config to the device.
2093 *
2094 * \details Call to apply the selected configs.
2095 *
2096 * \param configs Configs to apply against.
2097 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
2098 * \returns StatusCode of the set command
2099 */
2100 ctre::phoenix::StatusCode Apply(const Slot1Configs &configs, units::time::second_t timeoutSeconds)
2101 {
2102 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
2103 }
2104
2105 /**
2106 * \brief Refreshes the values of the specified config group.
2107 *
2108 * This will wait up to #DefaultTimeoutSeconds.
2109 *
2110 * \details Call to refresh the selected configs from the device.
2111 *
2112 * \param configs The configs to refresh
2113 * \returns StatusCode of refreshing the configs
2114 */
2116 {
2117 return Refresh(configs, DefaultTimeoutSeconds);
2118 }
2119 /**
2120 * \brief Refreshes the values of the specified config group.
2121 *
2122 * \details Call to refresh the selected configs from the device.
2123 *
2124 * \param configs The configs to refresh
2125 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
2126 * \returns StatusCode of refreshing the configs
2127 */
2128 ctre::phoenix::StatusCode Refresh(Slot2Configs &configs, units::time::second_t timeoutSeconds) const
2129 {
2130 std::string ref;
2131 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
2132 configs.Deserialize(ref);
2133 return ret;
2134 }
2135
2136 /**
2137 * \brief Applies the contents of the specified config to the device.
2138 *
2139 * This will wait up to #DefaultTimeoutSeconds.
2140 *
2141 * \details Call to apply the selected configs.
2142 *
2143 * \param configs Configs to apply against.
2144 * \returns StatusCode of the set command
2145 */
2147 {
2148 return Apply(configs, DefaultTimeoutSeconds);
2149 }
2150
2151 /**
2152 * \brief Applies the contents of the specified config to the device.
2153 *
2154 * \details Call to apply the selected configs.
2155 *
2156 * \param configs Configs to apply against.
2157 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
2158 * \returns StatusCode of the set command
2159 */
2160 ctre::phoenix::StatusCode Apply(const Slot2Configs &configs, units::time::second_t timeoutSeconds)
2161 {
2162 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
2163 }
2164
2165 /**
2166 * \brief Refreshes the values of the specified config group.
2167 *
2168 * This will wait up to #DefaultTimeoutSeconds.
2169 *
2170 * \details Call to refresh the selected configs from the device.
2171 *
2172 * \param configs The configs to refresh
2173 * \returns StatusCode of refreshing the configs
2174 */
2176 {
2177 return Refresh(configs, DefaultTimeoutSeconds);
2178 }
2179 /**
2180 * \brief Refreshes the values of the specified config group.
2181 *
2182 * \details Call to refresh the selected configs from the device.
2183 *
2184 * \param configs The configs to refresh
2185 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
2186 * \returns StatusCode of refreshing the configs
2187 */
2188 ctre::phoenix::StatusCode Refresh(SlotConfigs &configs, units::time::second_t timeoutSeconds) const
2189 {
2190 std::string ref;
2191 ctre::phoenix::StatusCode ret = GetConfigsPrivate(ref, timeoutSeconds);
2192 configs.Deserialize(ref);
2193 return ret;
2194 }
2195
2196 /**
2197 * \brief Applies the contents of the specified config to the device.
2198 *
2199 * This will wait up to #DefaultTimeoutSeconds.
2200 *
2201 * \details Call to apply the selected configs.
2202 *
2203 * \param configs Configs to apply against.
2204 * \returns StatusCode of the set command
2205 */
2207 {
2208 return Apply(configs, DefaultTimeoutSeconds);
2209 }
2210
2211 /**
2212 * \brief Applies the contents of the specified config to the device.
2213 *
2214 * \details Call to apply the selected configs.
2215 *
2216 * \param configs Configs to apply against.
2217 * \param timeoutSeconds Maximum amount of time to wait when performing configuration
2218 * \returns StatusCode of the set command
2219 */
2220 ctre::phoenix::StatusCode Apply(const SlotConfigs &configs, units::time::second_t timeoutSeconds)
2221 {
2222 return SetConfigsPrivate(configs.Serialize(), timeoutSeconds, false, false);
2223 }
2224
2225
2226 /**
2227 * \brief Sets the mechanism position of the device in mechanism
2228 * rotations.
2229 *
2230 * This will wait up to #DefaultTimeoutSeconds.
2231 *
2232 * This is available in the configurator in case the user wants
2233 * to initialize their device entirely without passing a device
2234 * reference down to the code that performs the initialization.
2235 * In this case, the user passes down the configurator object
2236 * and performs all the initialization code on the object.
2237 *
2238 * \param newValue Value to set to. Units are in rotations.
2239 * \returns StatusCode of the set command
2240 */
2241 ctre::phoenix::StatusCode SetPosition(units::angle::turn_t newValue)
2242 {
2243 return SetPosition(newValue, DefaultTimeoutSeconds);
2244 }
2245 /**
2246 * \brief Sets the mechanism position of the device in mechanism
2247 * rotations.
2248 *
2249 * This is available in the configurator in case the user wants
2250 * to initialize their device entirely without passing a device
2251 * reference down to the code that performs the initialization.
2252 * In this case, the user passes down the configurator object
2253 * and performs all the initialization code on the object.
2254 *
2255 * \param newValue Value to set to. Units are in rotations.
2256 * \param timeoutSeconds Maximum time to wait up to in seconds.
2257 * \returns StatusCode of the set command
2258 */
2259 ctre::phoenix::StatusCode SetPosition(units::angle::turn_t newValue, units::time::second_t timeoutSeconds);
2260
2261 /**
2262 * \brief Clear the sticky faults in the device.
2263 *
2264 * \details This typically has no impact on the device functionality.
2265 * Instead, it just clears telemetry faults that are accessible via
2266 * API and Tuner Self-Test.
2267 *
2268 * This will wait up to #DefaultTimeoutSeconds.
2269 *
2270 * This is available in the configurator in case the user wants
2271 * to initialize their device entirely without passing a device
2272 * reference down to the code that performs the initialization.
2273 * In this case, the user passes down the configurator object
2274 * and performs all the initialization code on the object.
2275 *
2276 * \returns StatusCode of the set command
2277 */
2279 {
2280 return ClearStickyFaults(DefaultTimeoutSeconds);
2281 }
2282 /**
2283 * \brief Clear the sticky faults in the device.
2284 *
2285 * \details This typically has no impact on the device functionality.
2286 * Instead, it just clears telemetry faults that are accessible via
2287 * API and Tuner Self-Test.
2288 *
2289 * This is available in the configurator in case the user wants
2290 * to initialize their device entirely without passing a device
2291 * reference down to the code that performs the initialization.
2292 * In this case, the user passes down the configurator object
2293 * and performs all the initialization code on the object.
2294 *
2295 * \param timeoutSeconds Maximum time to wait up to in seconds.
2296 * \returns StatusCode of the set command
2297 */
2298 ctre::phoenix::StatusCode ClearStickyFaults(units::time::second_t timeoutSeconds);
2299
2300 /**
2301 * \brief Clear sticky fault: Hardware fault occurred
2302 *
2303 * This will wait up to #DefaultTimeoutSeconds.
2304 *
2305 * This is available in the configurator in case the user wants
2306 * to initialize their device entirely without passing a device
2307 * reference down to the code that performs the initialization.
2308 * In this case, the user passes down the configurator object
2309 * and performs all the initialization code on the object.
2310 *
2311 * \returns StatusCode of the set command
2312 */
2314 {
2315 return ClearStickyFault_Hardware(DefaultTimeoutSeconds);
2316 }
2317 /**
2318 * \brief Clear sticky fault: Hardware fault occurred
2319 *
2320 * This is available in the configurator in case the user wants
2321 * to initialize their device entirely without passing a device
2322 * reference down to the code that performs the initialization.
2323 * In this case, the user passes down the configurator object
2324 * and performs all the initialization code on the object.
2325 *
2326 * \param timeoutSeconds Maximum time to wait up to in seconds.
2327 * \returns StatusCode of the set command
2328 */
2329 ctre::phoenix::StatusCode ClearStickyFault_Hardware(units::time::second_t timeoutSeconds);
2330
2331 /**
2332 * \brief Clear sticky fault: Processor temperature exceeded limit
2333 *
2334 * This will wait up to #DefaultTimeoutSeconds.
2335 *
2336 * This is available in the configurator in case the user wants
2337 * to initialize their device entirely without passing a device
2338 * reference down to the code that performs the initialization.
2339 * In this case, the user passes down the configurator object
2340 * and performs all the initialization code on the object.
2341 *
2342 * \returns StatusCode of the set command
2343 */
2345 {
2346 return ClearStickyFault_ProcTemp(DefaultTimeoutSeconds);
2347 }
2348 /**
2349 * \brief Clear sticky fault: Processor temperature exceeded limit
2350 *
2351 * This is available in the configurator in case the user wants
2352 * to initialize their device entirely without passing a device
2353 * reference down to the code that performs the initialization.
2354 * In this case, the user passes down the configurator object
2355 * and performs all the initialization code on the object.
2356 *
2357 * \param timeoutSeconds Maximum time to wait up to in seconds.
2358 * \returns StatusCode of the set command
2359 */
2360 ctre::phoenix::StatusCode ClearStickyFault_ProcTemp(units::time::second_t timeoutSeconds);
2361
2362 /**
2363 * \brief Clear sticky fault: Device temperature exceeded limit
2364 *
2365 * This will wait up to #DefaultTimeoutSeconds.
2366 *
2367 * This is available in the configurator in case the user wants
2368 * to initialize their device entirely without passing a device
2369 * reference down to the code that performs the initialization.
2370 * In this case, the user passes down the configurator object
2371 * and performs all the initialization code on the object.
2372 *
2373 * \returns StatusCode of the set command
2374 */
2376 {
2377 return ClearStickyFault_DeviceTemp(DefaultTimeoutSeconds);
2378 }
2379 /**
2380 * \brief Clear sticky fault: Device temperature exceeded limit
2381 *
2382 * This is available in the configurator in case the user wants
2383 * to initialize their device entirely without passing a device
2384 * reference down to the code that performs the initialization.
2385 * In this case, the user passes down the configurator object
2386 * and performs all the initialization code on the object.
2387 *
2388 * \param timeoutSeconds Maximum time to wait up to in seconds.
2389 * \returns StatusCode of the set command
2390 */
2391 ctre::phoenix::StatusCode ClearStickyFault_DeviceTemp(units::time::second_t timeoutSeconds);
2392
2393 /**
2394 * \brief Clear sticky fault: Device supply voltage dropped to near
2395 * brownout levels
2396 *
2397 * This will wait up to #DefaultTimeoutSeconds.
2398 *
2399 * This is available in the configurator in case the user wants
2400 * to initialize their device entirely without passing a device
2401 * reference down to the code that performs the initialization.
2402 * In this case, the user passes down the configurator object
2403 * and performs all the initialization code on the object.
2404 *
2405 * \returns StatusCode of the set command
2406 */
2408 {
2409 return ClearStickyFault_Undervoltage(DefaultTimeoutSeconds);
2410 }
2411 /**
2412 * \brief Clear sticky fault: Device supply voltage dropped to near
2413 * brownout levels
2414 *
2415 * This is available in the configurator in case the user wants
2416 * to initialize their device entirely without passing a device
2417 * reference down to the code that performs the initialization.
2418 * In this case, the user passes down the configurator object
2419 * and performs all the initialization code on the object.
2420 *
2421 * \param timeoutSeconds Maximum time to wait up to in seconds.
2422 * \returns StatusCode of the set command
2423 */
2424 ctre::phoenix::StatusCode ClearStickyFault_Undervoltage(units::time::second_t timeoutSeconds);
2425
2426 /**
2427 * \brief Clear sticky fault: Device boot while detecting the enable
2428 * signal
2429 *
2430 * This will wait up to #DefaultTimeoutSeconds.
2431 *
2432 * This is available in the configurator in case the user wants
2433 * to initialize their device entirely without passing a device
2434 * reference down to the code that performs the initialization.
2435 * In this case, the user passes down the configurator object
2436 * and performs all the initialization code on the object.
2437 *
2438 * \returns StatusCode of the set command
2439 */
2441 {
2442 return ClearStickyFault_BootDuringEnable(DefaultTimeoutSeconds);
2443 }
2444 /**
2445 * \brief Clear sticky fault: Device boot while detecting the enable
2446 * signal
2447 *
2448 * This is available in the configurator in case the user wants
2449 * to initialize their device entirely without passing a device
2450 * reference down to the code that performs the initialization.
2451 * In this case, the user passes down the configurator object
2452 * and performs all the initialization code on the object.
2453 *
2454 * \param timeoutSeconds Maximum time to wait up to in seconds.
2455 * \returns StatusCode of the set command
2456 */
2458
2459 /**
2460 * \brief Clear sticky fault: An unlicensed feature is in use, device
2461 * may not behave as expected.
2462 *
2463 * This will wait up to #DefaultTimeoutSeconds.
2464 *
2465 * This is available in the configurator in case the user wants
2466 * to initialize their device entirely without passing a device
2467 * reference down to the code that performs the initialization.
2468 * In this case, the user passes down the configurator object
2469 * and performs all the initialization code on the object.
2470 *
2471 * \returns StatusCode of the set command
2472 */
2474 {
2475 return ClearStickyFault_UnlicensedFeatureInUse(DefaultTimeoutSeconds);
2476 }
2477 /**
2478 * \brief Clear sticky fault: An unlicensed feature is in use, device
2479 * may not behave as expected.
2480 *
2481 * This is available in the configurator in case the user wants
2482 * to initialize their device entirely without passing a device
2483 * reference down to the code that performs the initialization.
2484 * In this case, the user passes down the configurator object
2485 * and performs all the initialization code on the object.
2486 *
2487 * \param timeoutSeconds Maximum time to wait up to in seconds.
2488 * \returns StatusCode of the set command
2489 */
2491
2492 /**
2493 * \brief Clear sticky fault: Bridge was disabled most likely due to
2494 * supply voltage dropping too low.
2495 *
2496 * This will wait up to #DefaultTimeoutSeconds.
2497 *
2498 * This is available in the configurator in case the user wants
2499 * to initialize their device entirely without passing a device
2500 * reference down to the code that performs the initialization.
2501 * In this case, the user passes down the configurator object
2502 * and performs all the initialization code on the object.
2503 *
2504 * \returns StatusCode of the set command
2505 */
2507 {
2508 return ClearStickyFault_BridgeBrownout(DefaultTimeoutSeconds);
2509 }
2510 /**
2511 * \brief Clear sticky fault: Bridge was disabled most likely due to
2512 * supply voltage dropping too low.
2513 *
2514 * This is available in the configurator in case the user wants
2515 * to initialize their device entirely without passing a device
2516 * reference down to the code that performs the initialization.
2517 * In this case, the user passes down the configurator object
2518 * and performs all the initialization code on the object.
2519 *
2520 * \param timeoutSeconds Maximum time to wait up to in seconds.
2521 * \returns StatusCode of the set command
2522 */
2523 ctre::phoenix::StatusCode ClearStickyFault_BridgeBrownout(units::time::second_t timeoutSeconds);
2524
2525 /**
2526 * \brief Clear sticky fault: The remote sensor has reset.
2527 *
2528 * This will wait up to #DefaultTimeoutSeconds.
2529 *
2530 * This is available in the configurator in case the user wants
2531 * to initialize their device entirely without passing a device
2532 * reference down to the code that performs the initialization.
2533 * In this case, the user passes down the configurator object
2534 * and performs all the initialization code on the object.
2535 *
2536 * \returns StatusCode of the set command
2537 */
2539 {
2540 return ClearStickyFault_RemoteSensorReset(DefaultTimeoutSeconds);
2541 }
2542 /**
2543 * \brief Clear sticky fault: The remote sensor has reset.
2544 *
2545 * This is available in the configurator in case the user wants
2546 * to initialize their device entirely without passing a device
2547 * reference down to the code that performs the initialization.
2548 * In this case, the user passes down the configurator object
2549 * and performs all the initialization code on the object.
2550 *
2551 * \param timeoutSeconds Maximum time to wait up to in seconds.
2552 * \returns StatusCode of the set command
2553 */
2555
2556 /**
2557 * \brief Clear sticky fault: The remote Talon used for differential
2558 * control is not present on CAN Bus.
2559 *
2560 * This will wait up to #DefaultTimeoutSeconds.
2561 *
2562 * This is available in the configurator in case the user wants
2563 * to initialize their device entirely without passing a device
2564 * reference down to the code that performs the initialization.
2565 * In this case, the user passes down the configurator object
2566 * and performs all the initialization code on the object.
2567 *
2568 * \returns StatusCode of the set command
2569 */
2571 {
2572 return ClearStickyFault_MissingDifferentialFX(DefaultTimeoutSeconds);
2573 }
2574 /**
2575 * \brief Clear sticky fault: The remote Talon used for differential
2576 * control is not present on CAN Bus.
2577 *
2578 * This is available in the configurator in case the user wants
2579 * to initialize their device entirely without passing a device
2580 * reference down to the code that performs the initialization.
2581 * In this case, the user passes down the configurator object
2582 * and performs all the initialization code on the object.
2583 *
2584 * \param timeoutSeconds Maximum time to wait up to in seconds.
2585 * \returns StatusCode of the set command
2586 */
2588
2589 /**
2590 * \brief Clear sticky fault: The remote sensor position has
2591 * overflowed. Because of the nature of remote sensors, it is possible
2592 * for the remote sensor position to overflow beyond what is supported
2593 * by the status signal frame. However, this is rare and cannot occur
2594 * over the course of an FRC match under normal use.
2595 *
2596 * This will wait up to #DefaultTimeoutSeconds.
2597 *
2598 * This is available in the configurator in case the user wants
2599 * to initialize their device entirely without passing a device
2600 * reference down to the code that performs the initialization.
2601 * In this case, the user passes down the configurator object
2602 * and performs all the initialization code on the object.
2603 *
2604 * \returns StatusCode of the set command
2605 */
2607 {
2608 return ClearStickyFault_RemoteSensorPosOverflow(DefaultTimeoutSeconds);
2609 }
2610 /**
2611 * \brief Clear sticky fault: The remote sensor position has
2612 * overflowed. Because of the nature of remote sensors, it is possible
2613 * for the remote sensor position to overflow beyond what is supported
2614 * by the status signal frame. However, this is rare and cannot occur
2615 * over the course of an FRC match under normal use.
2616 *
2617 * This is available in the configurator in case the user wants
2618 * to initialize their device entirely without passing a device
2619 * reference down to the code that performs the initialization.
2620 * In this case, the user passes down the configurator object
2621 * and performs all the initialization code on the object.
2622 *
2623 * \param timeoutSeconds Maximum time to wait up to in seconds.
2624 * \returns StatusCode of the set command
2625 */
2627
2628 /**
2629 * \brief Clear sticky fault: Supply Voltage has exceeded the maximum
2630 * voltage rating of device.
2631 *
2632 * This will wait up to #DefaultTimeoutSeconds.
2633 *
2634 * This is available in the configurator in case the user wants
2635 * to initialize their device entirely without passing a device
2636 * reference down to the code that performs the initialization.
2637 * In this case, the user passes down the configurator object
2638 * and performs all the initialization code on the object.
2639 *
2640 * \returns StatusCode of the set command
2641 */
2643 {
2644 return ClearStickyFault_OverSupplyV(DefaultTimeoutSeconds);
2645 }
2646 /**
2647 * \brief Clear sticky fault: Supply Voltage has exceeded the maximum
2648 * voltage rating of device.
2649 *
2650 * This is available in the configurator in case the user wants
2651 * to initialize their device entirely without passing a device
2652 * reference down to the code that performs the initialization.
2653 * In this case, the user passes down the configurator object
2654 * and performs all the initialization code on the object.
2655 *
2656 * \param timeoutSeconds Maximum time to wait up to in seconds.
2657 * \returns StatusCode of the set command
2658 */
2659 ctre::phoenix::StatusCode ClearStickyFault_OverSupplyV(units::time::second_t timeoutSeconds);
2660
2661 /**
2662 * \brief Clear sticky fault: Supply Voltage is unstable. Ensure you
2663 * are using a battery and current limited power supply.
2664 *
2665 * This will wait up to #DefaultTimeoutSeconds.
2666 *
2667 * This is available in the configurator in case the user wants
2668 * to initialize their device entirely without passing a device
2669 * reference down to the code that performs the initialization.
2670 * In this case, the user passes down the configurator object
2671 * and performs all the initialization code on the object.
2672 *
2673 * \returns StatusCode of the set command
2674 */
2676 {
2677 return ClearStickyFault_UnstableSupplyV(DefaultTimeoutSeconds);
2678 }
2679 /**
2680 * \brief Clear sticky fault: Supply Voltage is unstable. Ensure you
2681 * are using a battery and current limited power supply.
2682 *
2683 * This is available in the configurator in case the user wants
2684 * to initialize their device entirely without passing a device
2685 * reference down to the code that performs the initialization.
2686 * In this case, the user passes down the configurator object
2687 * and performs all the initialization code on the object.
2688 *
2689 * \param timeoutSeconds Maximum time to wait up to in seconds.
2690 * \returns StatusCode of the set command
2691 */
2693
2694 /**
2695 * \brief Clear sticky fault: Reverse limit switch has been asserted.
2696 * Output is set to neutral.
2697 *
2698 * This will wait up to #DefaultTimeoutSeconds.
2699 *
2700 * This is available in the configurator in case the user wants
2701 * to initialize their device entirely without passing a device
2702 * reference down to the code that performs the initialization.
2703 * In this case, the user passes down the configurator object
2704 * and performs all the initialization code on the object.
2705 *
2706 * \returns StatusCode of the set command
2707 */
2709 {
2710 return ClearStickyFault_ReverseHardLimit(DefaultTimeoutSeconds);
2711 }
2712 /**
2713 * \brief Clear sticky fault: Reverse limit switch has been asserted.
2714 * Output is set to neutral.
2715 *
2716 * This is available in the configurator in case the user wants
2717 * to initialize their device entirely without passing a device
2718 * reference down to the code that performs the initialization.
2719 * In this case, the user passes down the configurator object
2720 * and performs all the initialization code on the object.
2721 *
2722 * \param timeoutSeconds Maximum time to wait up to in seconds.
2723 * \returns StatusCode of the set command
2724 */
2726
2727 /**
2728 * \brief Clear sticky fault: Forward limit switch has been asserted.
2729 * Output is set to neutral.
2730 *
2731 * This will wait up to #DefaultTimeoutSeconds.
2732 *
2733 * This is available in the configurator in case the user wants
2734 * to initialize their device entirely without passing a device
2735 * reference down to the code that performs the initialization.
2736 * In this case, the user passes down the configurator object
2737 * and performs all the initialization code on the object.
2738 *
2739 * \returns StatusCode of the set command
2740 */
2742 {
2743 return ClearStickyFault_ForwardHardLimit(DefaultTimeoutSeconds);
2744 }
2745 /**
2746 * \brief Clear sticky fault: Forward limit switch has been asserted.
2747 * Output is set to neutral.
2748 *
2749 * This is available in the configurator in case the user wants
2750 * to initialize their device entirely without passing a device
2751 * reference down to the code that performs the initialization.
2752 * In this case, the user passes down the configurator object
2753 * and performs all the initialization code on the object.
2754 *
2755 * \param timeoutSeconds Maximum time to wait up to in seconds.
2756 * \returns StatusCode of the set command
2757 */
2759
2760 /**
2761 * \brief Clear sticky fault: Reverse soft limit has been asserted.
2762 * Output is set to neutral.
2763 *
2764 * This will wait up to #DefaultTimeoutSeconds.
2765 *
2766 * This is available in the configurator in case the user wants
2767 * to initialize their device entirely without passing a device
2768 * reference down to the code that performs the initialization.
2769 * In this case, the user passes down the configurator object
2770 * and performs all the initialization code on the object.
2771 *
2772 * \returns StatusCode of the set command
2773 */
2775 {
2776 return ClearStickyFault_ReverseSoftLimit(DefaultTimeoutSeconds);
2777 }
2778 /**
2779 * \brief Clear sticky fault: Reverse soft limit has been asserted.
2780 * Output is set to neutral.
2781 *
2782 * This is available in the configurator in case the user wants
2783 * to initialize their device entirely without passing a device
2784 * reference down to the code that performs the initialization.
2785 * In this case, the user passes down the configurator object
2786 * and performs all the initialization code on the object.
2787 *
2788 * \param timeoutSeconds Maximum time to wait up to in seconds.
2789 * \returns StatusCode of the set command
2790 */
2792
2793 /**
2794 * \brief Clear sticky fault: Forward soft limit has been asserted.
2795 * Output is set to neutral.
2796 *
2797 * This will wait up to #DefaultTimeoutSeconds.
2798 *
2799 * This is available in the configurator in case the user wants
2800 * to initialize their device entirely without passing a device
2801 * reference down to the code that performs the initialization.
2802 * In this case, the user passes down the configurator object
2803 * and performs all the initialization code on the object.
2804 *
2805 * \returns StatusCode of the set command
2806 */
2808 {
2809 return ClearStickyFault_ForwardSoftLimit(DefaultTimeoutSeconds);
2810 }
2811 /**
2812 * \brief Clear sticky fault: Forward soft limit has been asserted.
2813 * Output is set to neutral.
2814 *
2815 * This is available in the configurator in case the user wants
2816 * to initialize their device entirely without passing a device
2817 * reference down to the code that performs the initialization.
2818 * In this case, the user passes down the configurator object
2819 * and performs all the initialization code on the object.
2820 *
2821 * \param timeoutSeconds Maximum time to wait up to in seconds.
2822 * \returns StatusCode of the set command
2823 */
2825
2826 /**
2827 * \brief Clear sticky fault: The remote soft limit device is not
2828 * present on CAN Bus.
2829 *
2830 * This will wait up to #DefaultTimeoutSeconds.
2831 *
2832 * This is available in the configurator in case the user wants
2833 * to initialize their device entirely without passing a device
2834 * reference down to the code that performs the initialization.
2835 * In this case, the user passes down the configurator object
2836 * and performs all the initialization code on the object.
2837 *
2838 * \returns StatusCode of the set command
2839 */
2841 {
2842 return ClearStickyFault_MissingSoftLimitRemote(DefaultTimeoutSeconds);
2843 }
2844 /**
2845 * \brief Clear sticky fault: The remote soft limit device is not
2846 * present on CAN Bus.
2847 *
2848 * This is available in the configurator in case the user wants
2849 * to initialize their device entirely without passing a device
2850 * reference down to the code that performs the initialization.
2851 * In this case, the user passes down the configurator object
2852 * and performs all the initialization code on the object.
2853 *
2854 * \param timeoutSeconds Maximum time to wait up to in seconds.
2855 * \returns StatusCode of the set command
2856 */
2858
2859 /**
2860 * \brief Clear sticky fault: The remote limit switch device is not
2861 * present on CAN Bus.
2862 *
2863 * This will wait up to #DefaultTimeoutSeconds.
2864 *
2865 * This is available in the configurator in case the user wants
2866 * to initialize their device entirely without passing a device
2867 * reference down to the code that performs the initialization.
2868 * In this case, the user passes down the configurator object
2869 * and performs all the initialization code on the object.
2870 *
2871 * \returns StatusCode of the set command
2872 */
2874 {
2875 return ClearStickyFault_MissingHardLimitRemote(DefaultTimeoutSeconds);
2876 }
2877 /**
2878 * \brief Clear sticky fault: The remote limit switch device is not
2879 * present on CAN Bus.
2880 *
2881 * This is available in the configurator in case the user wants
2882 * to initialize their device entirely without passing a device
2883 * reference down to the code that performs the initialization.
2884 * In this case, the user passes down the configurator object
2885 * and performs all the initialization code on the object.
2886 *
2887 * \param timeoutSeconds Maximum time to wait up to in seconds.
2888 * \returns StatusCode of the set command
2889 */
2891
2892 /**
2893 * \brief Clear sticky fault: The remote sensor's data is no longer
2894 * trusted. This can happen if the remote sensor disappears from the
2895 * CAN bus or if the remote sensor indicates its data is no longer
2896 * valid, such as when a CANcoder's magnet strength falls into the
2897 * "red" range.
2898 *
2899 * This will wait up to #DefaultTimeoutSeconds.
2900 *
2901 * This is available in the configurator in case the user wants
2902 * to initialize their device entirely without passing a device
2903 * reference down to the code that performs the initialization.
2904 * In this case, the user passes down the configurator object
2905 * and performs all the initialization code on the object.
2906 *
2907 * \returns StatusCode of the set command
2908 */
2910 {
2911 return ClearStickyFault_RemoteSensorDataInvalid(DefaultTimeoutSeconds);
2912 }
2913 /**
2914 * \brief Clear sticky fault: The remote sensor's data is no longer
2915 * trusted. This can happen if the remote sensor disappears from the
2916 * CAN bus or if the remote sensor indicates its data is no longer
2917 * valid, such as when a CANcoder's magnet strength falls into the
2918 * "red" range.
2919 *
2920 * This is available in the configurator in case the user wants
2921 * to initialize their device entirely without passing a device
2922 * reference down to the code that performs the initialization.
2923 * In this case, the user passes down the configurator object
2924 * and performs all the initialization code on the object.
2925 *
2926 * \param timeoutSeconds Maximum time to wait up to in seconds.
2927 * \returns StatusCode of the set command
2928 */
2930
2931 /**
2932 * \brief Clear sticky fault: The remote sensor used for fusion has
2933 * fallen out of sync to the local sensor. A re-synchronization has
2934 * occurred, which may cause a discontinuity. This typically happens
2935 * if there is significant slop in the mechanism, or if the
2936 * RotorToSensorRatio configuration parameter is incorrect.
2937 *
2938 * This will wait up to #DefaultTimeoutSeconds.
2939 *
2940 * This is available in the configurator in case the user wants
2941 * to initialize their device entirely without passing a device
2942 * reference down to the code that performs the initialization.
2943 * In this case, the user passes down the configurator object
2944 * and performs all the initialization code on the object.
2945 *
2946 * \returns StatusCode of the set command
2947 */
2949 {
2950 return ClearStickyFault_FusedSensorOutOfSync(DefaultTimeoutSeconds);
2951 }
2952 /**
2953 * \brief Clear sticky fault: The remote sensor used for fusion has
2954 * fallen out of sync to the local sensor. A re-synchronization has
2955 * occurred, which may cause a discontinuity. This typically happens
2956 * if there is significant slop in the mechanism, or if the
2957 * RotorToSensorRatio configuration parameter is incorrect.
2958 *
2959 * This is available in the configurator in case the user wants
2960 * to initialize their device entirely without passing a device
2961 * reference down to the code that performs the initialization.
2962 * In this case, the user passes down the configurator object
2963 * and performs all the initialization code on the object.
2964 *
2965 * \param timeoutSeconds Maximum time to wait up to in seconds.
2966 * \returns StatusCode of the set command
2967 */
2969
2970 /**
2971 * \brief Clear sticky fault: Stator current limit occured.
2972 *
2973 * This will wait up to #DefaultTimeoutSeconds.
2974 *
2975 * This is available in the configurator in case the user wants
2976 * to initialize their device entirely without passing a device
2977 * reference down to the code that performs the initialization.
2978 * In this case, the user passes down the configurator object
2979 * and performs all the initialization code on the object.
2980 *
2981 * \returns StatusCode of the set command
2982 */
2984 {
2985 return ClearStickyFault_StatorCurrLimit(DefaultTimeoutSeconds);
2986 }
2987 /**
2988 * \brief Clear sticky fault: Stator current limit occured.
2989 *
2990 * This is available in the configurator in case the user wants
2991 * to initialize their device entirely without passing a device
2992 * reference down to the code that performs the initialization.
2993 * In this case, the user passes down the configurator object
2994 * and performs all the initialization code on the object.
2995 *
2996 * \param timeoutSeconds Maximum time to wait up to in seconds.
2997 * \returns StatusCode of the set command
2998 */
3000
3001 /**
3002 * \brief Clear sticky fault: Supply current limit occured.
3003 *
3004 * This will wait up to #DefaultTimeoutSeconds.
3005 *
3006 * This is available in the configurator in case the user wants
3007 * to initialize their device entirely without passing a device
3008 * reference down to the code that performs the initialization.
3009 * In this case, the user passes down the configurator object
3010 * and performs all the initialization code on the object.
3011 *
3012 * \returns StatusCode of the set command
3013 */
3015 {
3016 return ClearStickyFault_SupplyCurrLimit(DefaultTimeoutSeconds);
3017 }
3018 /**
3019 * \brief Clear sticky fault: Supply current limit occured.
3020 *
3021 * This is available in the configurator in case the user wants
3022 * to initialize their device entirely without passing a device
3023 * reference down to the code that performs the initialization.
3024 * In this case, the user passes down the configurator object
3025 * and performs all the initialization code on the object.
3026 *
3027 * \param timeoutSeconds Maximum time to wait up to in seconds.
3028 * \returns StatusCode of the set command
3029 */
3031
3032 /**
3033 * \brief Clear sticky fault: Using Fused CANcoder feature while
3034 * unlicensed. Device has fallen back to remote CANcoder.
3035 *
3036 * This will wait up to #DefaultTimeoutSeconds.
3037 *
3038 * This is available in the configurator in case the user wants
3039 * to initialize their device entirely without passing a device
3040 * reference down to the code that performs the initialization.
3041 * In this case, the user passes down the configurator object
3042 * and performs all the initialization code on the object.
3043 *
3044 * \returns StatusCode of the set command
3045 */
3047 {
3048 return ClearStickyFault_UsingFusedCANcoderWhileUnlicensed(DefaultTimeoutSeconds);
3049 }
3050 /**
3051 * \brief Clear sticky fault: Using Fused CANcoder feature while
3052 * unlicensed. Device has fallen back to remote CANcoder.
3053 *
3054 * This is available in the configurator in case the user wants
3055 * to initialize their device entirely without passing a device
3056 * reference down to the code that performs the initialization.
3057 * In this case, the user passes down the configurator object
3058 * and performs all the initialization code on the object.
3059 *
3060 * \param timeoutSeconds Maximum time to wait up to in seconds.
3061 * \returns StatusCode of the set command
3062 */
3064
3065 /**
3066 * \brief Clear sticky fault: Static brake was momentarily disabled
3067 * due to excessive braking current while disabled.
3068 *
3069 * This will wait up to #DefaultTimeoutSeconds.
3070 *
3071 * This is available in the configurator in case the user wants
3072 * to initialize their device entirely without passing a device
3073 * reference down to the code that performs the initialization.
3074 * In this case, the user passes down the configurator object
3075 * and performs all the initialization code on the object.
3076 *
3077 * \returns StatusCode of the set command
3078 */
3080 {
3081 return ClearStickyFault_StaticBrakeDisabled(DefaultTimeoutSeconds);
3082 }
3083 /**
3084 * \brief Clear sticky fault: Static brake was momentarily disabled
3085 * due to excessive braking current while disabled.
3086 *
3087 * This is available in the configurator in case the user wants
3088 * to initialize their device entirely without passing a device
3089 * reference down to the code that performs the initialization.
3090 * In this case, the user passes down the configurator object
3091 * and performs all the initialization code on the object.
3092 *
3093 * \param timeoutSeconds Maximum time to wait up to in seconds.
3094 * \returns StatusCode of the set command
3095 */
3097
3098 /**
3099 * \brief Clear sticky fault: Trips if a major mechanical or ESD event
3100 * caused a brief loss of position data triggering a recovery while
3101 * not in motion. If the event occurs often, inspect for excess axial
3102 * force or sources of ESD at the rotor.
3103 *
3104 * This will wait up to #DefaultTimeoutSeconds.
3105 *
3106 * This is available in the configurator in case the user wants
3107 * to initialize their device entirely without passing a device
3108 * reference down to the code that performs the initialization.
3109 * In this case, the user passes down the configurator object
3110 * and performs all the initialization code on the object.
3111 *
3112 * \returns StatusCode of the set command
3113 */
3115 {
3116 return ClearStickyFault_RotorFault1(DefaultTimeoutSeconds);
3117 }
3118 /**
3119 * \brief Clear sticky fault: Trips if a major mechanical or ESD event
3120 * caused a brief loss of position data triggering a recovery while
3121 * not in motion. If the event occurs often, inspect for excess axial
3122 * force or sources of ESD at the rotor.
3123 *
3124 * This is available in the configurator in case the user wants
3125 * to initialize their device entirely without passing a device
3126 * reference down to the code that performs the initialization.
3127 * In this case, the user passes down the configurator object
3128 * and performs all the initialization code on the object.
3129 *
3130 * \param timeoutSeconds Maximum time to wait up to in seconds.
3131 * \returns StatusCode of the set command
3132 */
3133 ctre::phoenix::StatusCode ClearStickyFault_RotorFault1(units::time::second_t timeoutSeconds);
3134
3135 /**
3136 * \brief Clear sticky fault: Trips if a major mechanical or ESD event
3137 * caused a brief loss of position data triggering a recovery while in
3138 * motion. If the event occurs often, inspect for excess axial force
3139 * or sources of ESD at the rotor.
3140 *
3141 * This will wait up to #DefaultTimeoutSeconds.
3142 *
3143 * This is available in the configurator in case the user wants
3144 * to initialize their device entirely without passing a device
3145 * reference down to the code that performs the initialization.
3146 * In this case, the user passes down the configurator object
3147 * and performs all the initialization code on the object.
3148 *
3149 * \returns StatusCode of the set command
3150 */
3152 {
3153 return ClearStickyFault_RotorFault2(DefaultTimeoutSeconds);
3154 }
3155 /**
3156 * \brief Clear sticky fault: Trips if a major mechanical or ESD event
3157 * caused a brief loss of position data triggering a recovery while in
3158 * motion. If the event occurs often, inspect for excess axial force
3159 * or sources of ESD at the rotor.
3160 *
3161 * This is available in the configurator in case the user wants
3162 * to initialize their device entirely without passing a device
3163 * reference down to the code that performs the initialization.
3164 * In this case, the user passes down the configurator object
3165 * and performs all the initialization code on the object.
3166 *
3167 * \param timeoutSeconds Maximum time to wait up to in seconds.
3168 * \returns StatusCode of the set command
3169 */
3170 ctre::phoenix::StatusCode ClearStickyFault_RotorFault2(units::time::second_t timeoutSeconds);
3171};
3172
3173}
3174
3175namespace hardware {
3176namespace core {
3177
3178#if defined(_WIN32) || defined(_WIN64)
3179#pragma warning(push)
3180#pragma warning(disable : 4250)
3181#endif
3182
3183/**
3184 * Class description for the Talon FX integrated motor controller.
3185 */
3187{
3188private:
3190
3191public:
3192 /**
3193 * \brief The configuration class for this device.
3194 */
3196
3197 /**
3198 * Constructs a new Talon FX motor controller object.
3199 *
3200 * \param deviceId ID of the device, as configured in Phoenix Tuner
3201 * \param canbus The CAN bus this device is on
3202 */
3203 CoreTalonFX(int deviceId, CANBus canbus = {});
3204
3205 /**
3206 * Constructs a new Talon FX motor controller object.
3207 *
3208 * \param deviceId ID of the device, as configured in Phoenix Tuner
3209 * \param canbus Name of the CAN bus this device is on. Possible CAN bus strings are:
3210 * - "rio" for the native roboRIO CAN bus
3211 * - CANivore name or serial number
3212 * - SocketCAN interface (non-FRC Linux only)
3213 * - "*" for any CANivore seen by the program
3214 * - empty string (default) to select the default for the system:
3215 * - "rio" on roboRIO
3216 * - "can0" on Linux
3217 * - "*" on Windows
3218 *
3219 * \deprecated Constructing devices with a CAN bus string is deprecated for removal
3220 * in the 2027 season. Construct devices using a CANBus instance instead.
3221 */
3222 CoreTalonFX(int deviceId, std::string canbus);
3223
3224 /**
3225 * \brief Gets the configurator for this TalonFX
3226 *
3227 * \details Gets the configurator for this TalonFX
3228 *
3229 * \returns Configurator for this TalonFX
3230 */
3232 {
3233 return _configs;
3234 }
3235
3236 /**
3237 * \brief Gets the configurator for this TalonFX
3238 *
3239 * \details Gets the configurator for this TalonFX
3240 *
3241 * \returns Configurator for this TalonFX
3242 */
3244 {
3245 return _configs;
3246 }
3247
3248
3249private:
3250 std::unique_ptr<sim::TalonFXSimState> _simState{};
3251public:
3252 /**
3253 * \brief Get the simulation state for this device.
3254 *
3255 * \details This function reuses an allocated simulation
3256 * state object, so it is safe to call this function multiple
3257 * times in a robot loop.
3258 *
3259 * \returns Simulation state
3260 */
3262 {
3263 if (_simState == nullptr)
3264 _simState = std::make_unique<sim::TalonFXSimState>(*this);
3265 return *_simState;
3266 }
3267
3268
3269
3270 /**
3271 * \brief App Major Version number.
3272 *
3273 * - Minimum Value: 0
3274 * - Maximum Value: 255
3275 * - Default Value: 0
3276 * - Units:
3277 *
3278 * Default Rates:
3279 * - CAN: 4.0 Hz
3280 *
3281 * This refreshes and returns a cached StatusSignal object.
3282 *
3283 * \param refresh Whether to refresh the StatusSignal before returning it;
3284 * defaults to true
3285 * \returns VersionMajor Status Signal Object
3286 */
3287 StatusSignal<int> &GetVersionMajor(bool refresh = true) final;
3288
3289 /**
3290 * \brief App Minor Version number.
3291 *
3292 * - Minimum Value: 0
3293 * - Maximum Value: 255
3294 * - Default Value: 0
3295 * - Units:
3296 *
3297 * Default Rates:
3298 * - CAN: 4.0 Hz
3299 *
3300 * This refreshes and returns a cached StatusSignal object.
3301 *
3302 * \param refresh Whether to refresh the StatusSignal before returning it;
3303 * defaults to true
3304 * \returns VersionMinor Status Signal Object
3305 */
3306 StatusSignal<int> &GetVersionMinor(bool refresh = true) final;
3307
3308 /**
3309 * \brief App Bugfix Version number.
3310 *
3311 * - Minimum Value: 0
3312 * - Maximum Value: 255
3313 * - Default Value: 0
3314 * - Units:
3315 *
3316 * Default Rates:
3317 * - CAN: 4.0 Hz
3318 *
3319 * This refreshes and returns a cached StatusSignal object.
3320 *
3321 * \param refresh Whether to refresh the StatusSignal before returning it;
3322 * defaults to true
3323 * \returns VersionBugfix Status Signal Object
3324 */
3325 StatusSignal<int> &GetVersionBugfix(bool refresh = true) final;
3326
3327 /**
3328 * \brief App Build Version number.
3329 *
3330 * - Minimum Value: 0
3331 * - Maximum Value: 255
3332 * - Default Value: 0
3333 * - Units:
3334 *
3335 * Default Rates:
3336 * - CAN: 4.0 Hz
3337 *
3338 * This refreshes and returns a cached StatusSignal object.
3339 *
3340 * \param refresh Whether to refresh the StatusSignal before returning it;
3341 * defaults to true
3342 * \returns VersionBuild Status Signal Object
3343 */
3344 StatusSignal<int> &GetVersionBuild(bool refresh = true) final;
3345
3346 /**
3347 * \brief Full Version of firmware in device. The format is a four
3348 * byte value.
3349 *
3350 * - Minimum Value: 0
3351 * - Maximum Value: 4294967295
3352 * - Default Value: 0
3353 * - Units:
3354 *
3355 * Default Rates:
3356 * - CAN: 4.0 Hz
3357 *
3358 * This refreshes and returns a cached StatusSignal object.
3359 *
3360 * \param refresh Whether to refresh the StatusSignal before returning it;
3361 * defaults to true
3362 * \returns Version Status Signal Object
3363 */
3364 StatusSignal<int> &GetVersion(bool refresh = true) final;
3365
3366 /**
3367 * \brief Integer representing all fault flags reported by the device.
3368 *
3369 * \details These are device specific and are not used directly in
3370 * typical applications. Use the signal specific GetFault_*() methods
3371 * instead.
3372 *
3373 * - Minimum Value: 0
3374 * - Maximum Value: 4294967295
3375 * - Default Value: 0
3376 * - Units:
3377 *
3378 * Default Rates:
3379 * - CAN: 4.0 Hz
3380 *
3381 * This refreshes and returns a cached StatusSignal object.
3382 *
3383 * \param refresh Whether to refresh the StatusSignal before returning it;
3384 * defaults to true
3385 * \returns FaultField Status Signal Object
3386 */
3387 StatusSignal<int> &GetFaultField(bool refresh = true) final;
3388
3389 /**
3390 * \brief Integer representing all (persistent) sticky fault flags
3391 * reported by the device.
3392 *
3393 * \details These are device specific and are not used directly in
3394 * typical applications. Use the signal specific GetStickyFault_*()
3395 * methods instead.
3396 *
3397 * - Minimum Value: 0
3398 * - Maximum Value: 4294967295
3399 * - Default Value: 0
3400 * - Units:
3401 *
3402 * Default Rates:
3403 * - CAN: 4.0 Hz
3404 *
3405 * This refreshes and returns a cached StatusSignal object.
3406 *
3407 * \param refresh Whether to refresh the StatusSignal before returning it;
3408 * defaults to true
3409 * \returns StickyFaultField Status Signal Object
3410 */
3411 StatusSignal<int> &GetStickyFaultField(bool refresh = true) final;
3412
3413 /**
3414 * \brief The applied (output) motor voltage.
3415 *
3416 * - Minimum Value: -40.96
3417 * - Maximum Value: 40.95
3418 * - Default Value: 0
3419 * - Units: V
3420 *
3421 * Default Rates:
3422 * - CAN 2.0: 100.0 Hz
3423 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3424 *
3425 * This refreshes and returns a cached StatusSignal object.
3426 *
3427 * \param refresh Whether to refresh the StatusSignal before returning it;
3428 * defaults to true
3429 * \returns MotorVoltage Status Signal Object
3430 */
3431 StatusSignal<units::voltage::volt_t> &GetMotorVoltage(bool refresh = true) final;
3432
3433 /**
3434 * \brief Forward Limit Pin.
3435 *
3436 *
3437 * Default Rates:
3438 * - CAN 2.0: 100.0 Hz
3439 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3440 *
3441 * This refreshes and returns a cached StatusSignal object.
3442 *
3443 * \param refresh Whether to refresh the StatusSignal before returning it;
3444 * defaults to true
3445 * \returns ForwardLimit Status Signal Object
3446 */
3447 StatusSignal<signals::ForwardLimitValue> &GetForwardLimit(bool refresh = true) final;
3448
3449 /**
3450 * \brief Reverse Limit Pin.
3451 *
3452 *
3453 * Default Rates:
3454 * - CAN 2.0: 100.0 Hz
3455 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3456 *
3457 * This refreshes and returns a cached StatusSignal object.
3458 *
3459 * \param refresh Whether to refresh the StatusSignal before returning it;
3460 * defaults to true
3461 * \returns ReverseLimit Status Signal Object
3462 */
3463 StatusSignal<signals::ReverseLimitValue> &GetReverseLimit(bool refresh = true) final;
3464
3465 /**
3466 * \brief The applied rotor polarity as seen from the front of the
3467 * motor. This typically is determined by the Inverted config, but
3468 * can be overridden if using Follower features.
3469 *
3470 *
3471 * Default Rates:
3472 * - CAN 2.0: 100.0 Hz
3473 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3474 *
3475 * This refreshes and returns a cached StatusSignal object.
3476 *
3477 * \param refresh Whether to refresh the StatusSignal before returning it;
3478 * defaults to true
3479 * \returns AppliedRotorPolarity Status Signal Object
3480 */
3481 StatusSignal<signals::AppliedRotorPolarityValue> &GetAppliedRotorPolarity(bool refresh = true) final;
3482
3483 /**
3484 * \brief The applied motor duty cycle.
3485 *
3486 * - Minimum Value: -2.0
3487 * - Maximum Value: 1.9990234375
3488 * - Default Value: 0
3489 * - Units: fractional
3490 *
3491 * Default Rates:
3492 * - CAN 2.0: 100.0 Hz
3493 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3494 *
3495 * This refreshes and returns a cached StatusSignal object.
3496 *
3497 * \param refresh Whether to refresh the StatusSignal before returning it;
3498 * defaults to true
3499 * \returns DutyCycle Status Signal Object
3500 */
3501 StatusSignal<units::dimensionless::scalar_t> &GetDutyCycle(bool refresh = true) final;
3502
3503 /**
3504 * \brief Current corresponding to the torque output by the motor.
3505 * Similar to StatorCurrent. Users will likely prefer this current to
3506 * calculate the applied torque to the rotor.
3507 *
3508 * \details Stator current where positive current means torque is
3509 * applied in the forward direction as determined by the Inverted
3510 * setting.
3511 *
3512 * - Minimum Value: -327.68
3513 * - Maximum Value: 327.67
3514 * - Default Value: 0
3515 * - Units: A
3516 *
3517 * Default Rates:
3518 * - CAN 2.0: 100.0 Hz
3519 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3520 *
3521 * This refreshes and returns a cached StatusSignal object.
3522 *
3523 * \param refresh Whether to refresh the StatusSignal before returning it;
3524 * defaults to true
3525 * \returns TorqueCurrent Status Signal Object
3526 */
3527 StatusSignal<units::current::ampere_t> &GetTorqueCurrent(bool refresh = true) final;
3528
3529 /**
3530 * \brief Current corresponding to the stator windings. Similar to
3531 * TorqueCurrent. Users will likely prefer TorqueCurrent over
3532 * StatorCurrent.
3533 *
3534 * \details Stator current where Positive current indicates motoring
3535 * regardless of direction. Negative current indicates regenerative
3536 * braking regardless of direction.
3537 *
3538 * - Minimum Value: -327.68
3539 * - Maximum Value: 327.66
3540 * - Default Value: 0
3541 * - Units: A
3542 *
3543 * Default Rates:
3544 * - CAN 2.0: 4.0 Hz
3545 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3546 *
3547 * This refreshes and returns a cached StatusSignal object.
3548 *
3549 * \param refresh Whether to refresh the StatusSignal before returning it;
3550 * defaults to true
3551 * \returns StatorCurrent Status Signal Object
3552 */
3553 StatusSignal<units::current::ampere_t> &GetStatorCurrent(bool refresh = true) final;
3554
3555 /**
3556 * \brief Measured supply side current.
3557 *
3558 * - Minimum Value: -327.68
3559 * - Maximum Value: 327.66
3560 * - Default Value: 0
3561 * - Units: A
3562 *
3563 * Default Rates:
3564 * - CAN 2.0: 4.0 Hz
3565 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3566 *
3567 * This refreshes and returns a cached StatusSignal object.
3568 *
3569 * \param refresh Whether to refresh the StatusSignal before returning it;
3570 * defaults to true
3571 * \returns SupplyCurrent Status Signal Object
3572 */
3573 StatusSignal<units::current::ampere_t> &GetSupplyCurrent(bool refresh = true) final;
3574
3575 /**
3576 * \brief Measured supply voltage to the device.
3577 *
3578 * - Minimum Value: 4
3579 * - Maximum Value: 29.575
3580 * - Default Value: 4
3581 * - Units: V
3582 *
3583 * Default Rates:
3584 * - CAN 2.0: 4.0 Hz
3585 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3586 *
3587 * This refreshes and returns a cached StatusSignal object.
3588 *
3589 * \param refresh Whether to refresh the StatusSignal before returning it;
3590 * defaults to true
3591 * \returns SupplyVoltage Status Signal Object
3592 */
3593 StatusSignal<units::voltage::volt_t> &GetSupplyVoltage(bool refresh = true) final;
3594
3595 /**
3596 * \brief Temperature of device.
3597 *
3598 * \details This is the temperature that the device measures itself to
3599 * be at. Similar to Processor Temperature.
3600 *
3601 * - Minimum Value: 0.0
3602 * - Maximum Value: 255.0
3603 * - Default Value: 0
3604 * - Units: ℃
3605 *
3606 * Default Rates:
3607 * - CAN 2.0: 4.0 Hz
3608 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3609 *
3610 * This refreshes and returns a cached StatusSignal object.
3611 *
3612 * \param refresh Whether to refresh the StatusSignal before returning it;
3613 * defaults to true
3614 * \returns DeviceTemp Status Signal Object
3615 */
3616 StatusSignal<units::temperature::celsius_t> &GetDeviceTemp(bool refresh = true) final;
3617
3618 /**
3619 * \brief Temperature of the processor.
3620 *
3621 * \details This is the temperature that the processor measures itself
3622 * to be at. Similar to Device Temperature.
3623 *
3624 * - Minimum Value: 0.0
3625 * - Maximum Value: 255.0
3626 * - Default Value: 0
3627 * - Units: ℃
3628 *
3629 * Default Rates:
3630 * - CAN 2.0: 4.0 Hz
3631 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3632 *
3633 * This refreshes and returns a cached StatusSignal object.
3634 *
3635 * \param refresh Whether to refresh the StatusSignal before returning it;
3636 * defaults to true
3637 * \returns ProcessorTemp Status Signal Object
3638 */
3639 StatusSignal<units::temperature::celsius_t> &GetProcessorTemp(bool refresh = true) final;
3640
3641 /**
3642 * \brief Velocity of the motor rotor. This velocity is not affected
3643 * by any feedback configs.
3644 *
3645 * - Minimum Value: -512.0
3646 * - Maximum Value: 511.998046875
3647 * - Default Value: 0
3648 * - Units: rotations per second
3649 *
3650 * Default Rates:
3651 * - CAN 2.0: 4.0 Hz
3652 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3653 *
3654 * This refreshes and returns a cached StatusSignal object.
3655 *
3656 * \param refresh Whether to refresh the StatusSignal before returning it;
3657 * defaults to true
3658 * \returns RotorVelocity Status Signal Object
3659 */
3660 StatusSignal<units::angular_velocity::turns_per_second_t> &GetRotorVelocity(bool refresh = true) final;
3661
3662 /**
3663 * \brief Position of the motor rotor. This position is only affected
3664 * by the RotorOffset config and calls to setPosition.
3665 *
3666 * - Minimum Value: -16384.0
3667 * - Maximum Value: 16383.999755859375
3668 * - Default Value: 0
3669 * - Units: rotations
3670 *
3671 * Default Rates:
3672 * - CAN 2.0: 4.0 Hz
3673 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3674 *
3675 * This refreshes and returns a cached StatusSignal object.
3676 *
3677 * \param refresh Whether to refresh the StatusSignal before returning it;
3678 * defaults to true
3679 * \returns RotorPosition Status Signal Object
3680 */
3681 StatusSignal<units::angle::turn_t> &GetRotorPosition(bool refresh = true) final;
3682
3683 /**
3684 * \brief Velocity of the device in mechanism rotations per second.
3685 * This can be the velocity of a remote sensor and is affected by the
3686 * RotorToSensorRatio and SensorToMechanismRatio configs.
3687 *
3688 * - Minimum Value: -512.0
3689 * - Maximum Value: 511.998046875
3690 * - Default Value: 0
3691 * - Units: rotations per second
3692 *
3693 * Default Rates:
3694 * - CAN 2.0: 50.0 Hz
3695 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3696 *
3697 * This refreshes and returns a cached StatusSignal object.
3698 *
3699 * \param refresh Whether to refresh the StatusSignal before returning it;
3700 * defaults to true
3701 * \returns Velocity Status Signal Object
3702 */
3703 StatusSignal<units::angular_velocity::turns_per_second_t> &GetVelocity(bool refresh = true) final;
3704
3705 /**
3706 * \brief Position of the device in mechanism rotations. This can be
3707 * the position of a remote sensor and is affected by the
3708 * RotorToSensorRatio and SensorToMechanismRatio configs, as well as
3709 * calls to setPosition.
3710 *
3711 * - Minimum Value: -16384.0
3712 * - Maximum Value: 16383.999755859375
3713 * - Default Value: 0
3714 * - Units: rotations
3715 *
3716 * Default Rates:
3717 * - CAN 2.0: 50.0 Hz
3718 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3719 *
3720 * This refreshes and returns a cached StatusSignal object.
3721 *
3722 * \param refresh Whether to refresh the StatusSignal before returning it;
3723 * defaults to true
3724 * \returns Position Status Signal Object
3725 */
3726 StatusSignal<units::angle::turn_t> &GetPosition(bool refresh = true) final;
3727
3728 /**
3729 * \brief Acceleration of the device in mechanism rotations per
3730 * second². This can be the acceleration of a remote sensor and is
3731 * affected by the RotorToSensorRatio and SensorToMechanismRatio
3732 * configs.
3733 *
3734 * - Minimum Value: -2048.0
3735 * - Maximum Value: 2047.75
3736 * - Default Value: 0
3737 * - Units: rotations per second²
3738 *
3739 * Default Rates:
3740 * - CAN 2.0: 50.0 Hz
3741 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3742 *
3743 * This refreshes and returns a cached StatusSignal object.
3744 *
3745 * \param refresh Whether to refresh the StatusSignal before returning it;
3746 * defaults to true
3747 * \returns Acceleration Status Signal Object
3748 */
3749 StatusSignal<units::angular_acceleration::turns_per_second_squared_t> &GetAcceleration(bool refresh = true) final;
3750
3751 /**
3752 * \brief The active control mode of the motor controller.
3753 *
3754 *
3755 * Default Rates:
3756 * - CAN 2.0: 4.0 Hz
3757 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3758 *
3759 * This refreshes and returns a cached StatusSignal object.
3760 *
3761 * \param refresh Whether to refresh the StatusSignal before returning it;
3762 * defaults to true
3763 * \returns ControlMode Status Signal Object
3764 */
3765 StatusSignal<signals::ControlModeValue> &GetControlMode(bool refresh = true) final;
3766
3767 /**
3768 * \brief Check if the Motion Magic® profile has reached the target.
3769 * This is equivalent to checking that MotionMagicIsRunning, the
3770 * ClosedLoopReference is the target, and the ClosedLoopReferenceSlope
3771 * is 0.
3772 *
3773 * - Default Value: False
3774 *
3775 * Default Rates:
3776 * - CAN 2.0: 4.0 Hz
3777 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3778 *
3779 * This refreshes and returns a cached StatusSignal object.
3780 *
3781 * \param refresh Whether to refresh the StatusSignal before returning it;
3782 * defaults to true
3783 * \returns MotionMagicAtTarget Status Signal Object
3784 */
3785 StatusSignal<bool> &GetMotionMagicAtTarget(bool refresh = true) final;
3786
3787 /**
3788 * \brief Check if Motion Magic® is running. This is equivalent to
3789 * checking that the reported control mode is a Motion Magic® based
3790 * mode.
3791 *
3792 * - Default Value: False
3793 *
3794 * Default Rates:
3795 * - CAN 2.0: 4.0 Hz
3796 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3797 *
3798 * This refreshes and returns a cached StatusSignal object.
3799 *
3800 * \param refresh Whether to refresh the StatusSignal before returning it;
3801 * defaults to true
3802 * \returns MotionMagicIsRunning Status Signal Object
3803 */
3804 StatusSignal<bool> &GetMotionMagicIsRunning(bool refresh = true) final;
3805
3806 /**
3807 * \brief Indicates if the robot is enabled.
3808 *
3809 *
3810 * Default Rates:
3811 * - CAN 2.0: 4.0 Hz
3812 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3813 *
3814 * This refreshes and returns a cached StatusSignal object.
3815 *
3816 * \param refresh Whether to refresh the StatusSignal before returning it;
3817 * defaults to true
3818 * \returns RobotEnable Status Signal Object
3819 */
3820 StatusSignal<signals::RobotEnableValue> &GetRobotEnable(bool refresh = true) final;
3821
3822 /**
3823 * \brief Indicates if device is actuator enabled.
3824 *
3825 *
3826 * Default Rates:
3827 * - CAN 2.0: 4.0 Hz
3828 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3829 *
3830 * This refreshes and returns a cached StatusSignal object.
3831 *
3832 * \param refresh Whether to refresh the StatusSignal before returning it;
3833 * defaults to true
3834 * \returns DeviceEnable Status Signal Object
3835 */
3836 StatusSignal<signals::DeviceEnableValue> &GetDeviceEnable(bool refresh = true) final;
3837
3838 /**
3839 * \brief The slot that the closed-loop PID is using.
3840 *
3841 * - Minimum Value: 0
3842 * - Maximum Value: 2
3843 * - Default Value: 0
3844 * - Units:
3845 *
3846 * Default Rates:
3847 * - CAN 2.0: 4.0 Hz
3848 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3849 *
3850 * This refreshes and returns a cached StatusSignal object.
3851 *
3852 * \param refresh Whether to refresh the StatusSignal before returning it;
3853 * defaults to true
3854 * \returns ClosedLoopSlot Status Signal Object
3855 */
3856 StatusSignal<int> &GetClosedLoopSlot(bool refresh = true) final;
3857
3858 /**
3859 * \brief Assess the status of the motor output with respect to load
3860 * and supply.
3861 *
3862 * \details This routine can be used to determine the general status
3863 * of motor commutation.
3864 *
3865 *
3866 * Default Rates:
3867 * - CAN 2.0: 4.0 Hz
3868 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3869 *
3870 * This refreshes and returns a cached StatusSignal object.
3871 *
3872 * \param refresh Whether to refresh the StatusSignal before returning it;
3873 * defaults to true
3874 * \returns MotorOutputStatus Status Signal Object
3875 */
3876 StatusSignal<signals::MotorOutputStatusValue> &GetMotorOutputStatus(bool refresh = true) final;
3877
3878 /**
3879 * \brief The active control mode of the differential controller.
3880 *
3881 *
3882 * Default Rates:
3883 * - CAN 2.0: 100.0 Hz
3884 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3885 *
3886 * This refreshes and returns a cached StatusSignal object.
3887 *
3888 * \param refresh Whether to refresh the StatusSignal before returning it;
3889 * defaults to true
3890 * \returns DifferentialControlMode Status Signal Object
3891 */
3892 StatusSignal<signals::DifferentialControlModeValue> &GetDifferentialControlMode(bool refresh = true) final;
3893
3894 /**
3895 * \brief Average component of the differential velocity of device.
3896 *
3897 * - Minimum Value: -512.0
3898 * - Maximum Value: 511.998046875
3899 * - Default Value: 0
3900 * - Units: rotations per second
3901 *
3902 * Default Rates:
3903 * - CAN 2.0: 4.0 Hz
3904 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3905 *
3906 * This refreshes and returns a cached StatusSignal object.
3907 *
3908 * \param refresh Whether to refresh the StatusSignal before returning it;
3909 * defaults to true
3910 * \returns DifferentialAverageVelocity Status Signal Object
3911 */
3912 StatusSignal<units::angular_velocity::turns_per_second_t> &GetDifferentialAverageVelocity(bool refresh = true) final;
3913
3914 /**
3915 * \brief Average component of the differential position of device.
3916 *
3917 * - Minimum Value: -16384.0
3918 * - Maximum Value: 16383.999755859375
3919 * - Default Value: 0
3920 * - Units: rotations
3921 *
3922 * Default Rates:
3923 * - CAN 2.0: 4.0 Hz
3924 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3925 *
3926 * This refreshes and returns a cached StatusSignal object.
3927 *
3928 * \param refresh Whether to refresh the StatusSignal before returning it;
3929 * defaults to true
3930 * \returns DifferentialAveragePosition Status Signal Object
3931 */
3932 StatusSignal<units::angle::turn_t> &GetDifferentialAveragePosition(bool refresh = true) final;
3933
3934 /**
3935 * \brief Difference component of the differential velocity of device.
3936 *
3937 * - Minimum Value: -512.0
3938 * - Maximum Value: 511.998046875
3939 * - Default Value: 0
3940 * - Units: rotations per second
3941 *
3942 * Default Rates:
3943 * - CAN 2.0: 4.0 Hz
3944 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3945 *
3946 * This refreshes and returns a cached StatusSignal object.
3947 *
3948 * \param refresh Whether to refresh the StatusSignal before returning it;
3949 * defaults to true
3950 * \returns DifferentialDifferenceVelocity Status Signal Object
3951 */
3952 StatusSignal<units::angular_velocity::turns_per_second_t> &GetDifferentialDifferenceVelocity(bool refresh = true) final;
3953
3954 /**
3955 * \brief Difference component of the differential position of device.
3956 *
3957 * - Minimum Value: -16384.0
3958 * - Maximum Value: 16383.999755859375
3959 * - Default Value: 0
3960 * - Units: rotations
3961 *
3962 * Default Rates:
3963 * - CAN 2.0: 4.0 Hz
3964 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3965 *
3966 * This refreshes and returns a cached StatusSignal object.
3967 *
3968 * \param refresh Whether to refresh the StatusSignal before returning it;
3969 * defaults to true
3970 * \returns DifferentialDifferencePosition Status Signal Object
3971 */
3972 StatusSignal<units::angle::turn_t> &GetDifferentialDifferencePosition(bool refresh = true) final;
3973
3974 /**
3975 * \brief The slot that the closed-loop differential PID is using.
3976 *
3977 * - Minimum Value: 0
3978 * - Maximum Value: 2
3979 * - Default Value: 0
3980 * - Units:
3981 *
3982 * Default Rates:
3983 * - CAN 2.0: 4.0 Hz
3984 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
3985 *
3986 * This refreshes and returns a cached StatusSignal object.
3987 *
3988 * \param refresh Whether to refresh the StatusSignal before returning it;
3989 * defaults to true
3990 * \returns DifferentialClosedLoopSlot Status Signal Object
3991 */
3992 StatusSignal<int> &GetDifferentialClosedLoopSlot(bool refresh = true) final;
3993
3994 /**
3995 * \brief The torque constant (K_T) of the motor.
3996 *
3997 * - Minimum Value: 0.0
3998 * - Maximum Value: 0.025500000000000002
3999 * - Default Value: 0
4000 * - Units: Nm/A
4001 *
4002 * Default Rates:
4003 * - CAN: 4.0 Hz
4004 *
4005 * This refreshes and returns a cached StatusSignal object.
4006 *
4007 * \param refresh Whether to refresh the StatusSignal before returning it;
4008 * defaults to true
4009 * \returns MotorKT Status Signal Object
4010 */
4011 StatusSignal<ctre::unit::newton_meters_per_ampere_t> &GetMotorKT(bool refresh = true) final;
4012
4013 /**
4014 * \brief The velocity constant (K_V) of the motor.
4015 *
4016 * - Minimum Value: 0.0
4017 * - Maximum Value: 2047.0
4018 * - Default Value: 0
4019 * - Units: RPM/V
4020 *
4021 * Default Rates:
4022 * - CAN: 4.0 Hz
4023 *
4024 * This refreshes and returns a cached StatusSignal object.
4025 *
4026 * \param refresh Whether to refresh the StatusSignal before returning it;
4027 * defaults to true
4028 * \returns MotorKV Status Signal Object
4029 */
4030 StatusSignal<ctre::unit::rpm_per_volt_t> &GetMotorKV(bool refresh = true) final;
4031
4032 /**
4033 * \brief The stall current of the motor at 12 V output.
4034 *
4035 * - Minimum Value: 0.0
4036 * - Maximum Value: 1023.0
4037 * - Default Value: 0
4038 * - Units: A
4039 *
4040 * Default Rates:
4041 * - CAN: 4.0 Hz
4042 *
4043 * This refreshes and returns a cached StatusSignal object.
4044 *
4045 * \param refresh Whether to refresh the StatusSignal before returning it;
4046 * defaults to true
4047 * \returns MotorStallCurrent Status Signal Object
4048 */
4049 StatusSignal<units::current::ampere_t> &GetMotorStallCurrent(bool refresh = true) final;
4050
4051 /**
4052 * \brief The applied output of the bridge.
4053 *
4054 *
4055 * Default Rates:
4056 * - CAN 2.0: 100.0 Hz
4057 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
4058 *
4059 * This refreshes and returns a cached StatusSignal object.
4060 *
4061 * \param refresh Whether to refresh the StatusSignal before returning it;
4062 * defaults to true
4063 * \returns BridgeOutput Status Signal Object
4064 */
4065 StatusSignal<signals::BridgeOutputValue> &GetBridgeOutput(bool refresh = true) final;
4066
4067 /**
4068 * \brief Whether the device is Phoenix Pro licensed.
4069 *
4070 * - Default Value: False
4071 *
4072 * Default Rates:
4073 * - CAN: 4.0 Hz
4074 *
4075 * This refreshes and returns a cached StatusSignal object.
4076 *
4077 * \param refresh Whether to refresh the StatusSignal before returning it;
4078 * defaults to true
4079 * \returns IsProLicensed Status Signal Object
4080 */
4081 StatusSignal<bool> &GetIsProLicensed(bool refresh = true) final;
4082
4083 /**
4084 * \brief Temperature of device from second sensor.
4085 *
4086 * \details Newer versions of Talon have multiple temperature
4087 * measurement methods.
4088 *
4089 * - Minimum Value: 0.0
4090 * - Maximum Value: 255.0
4091 * - Default Value: 0
4092 * - Units: ℃
4093 *
4094 * Default Rates:
4095 * - CAN 2.0: 4.0 Hz
4096 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
4097 *
4098 * This refreshes and returns a cached StatusSignal object.
4099 *
4100 * \param refresh Whether to refresh the StatusSignal before returning it;
4101 * defaults to true
4102 * \returns AncillaryDeviceTemp Status Signal Object
4103 */
4104 StatusSignal<units::temperature::celsius_t> &GetAncillaryDeviceTemp(bool refresh = true) final;
4105
4106 /**
4107 * \brief The type of motor attached to the Talon.
4108 *
4109 * \details This can be used to determine what motor is attached to
4110 * the Talon FX. Return will be "Unknown" if firmware is too old or
4111 * device is not present.
4112 *
4113 *
4114 * Default Rates:
4115 * - CAN 2.0: 4.0 Hz
4116 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
4117 *
4118 * This refreshes and returns a cached StatusSignal object.
4119 *
4120 * \param refresh Whether to refresh the StatusSignal before returning it;
4121 * defaults to true
4122 * \returns ConnectedMotor Status Signal Object
4123 */
4124 StatusSignal<signals::ConnectedMotorValue> &GetConnectedMotor(bool refresh = true) final;
4125
4126 /**
4127 * \brief Hardware fault occurred
4128 *
4129 * - Default Value: False
4130 *
4131 * Default Rates:
4132 * - CAN: 4.0 Hz
4133 *
4134 * This refreshes and returns a cached StatusSignal object.
4135 *
4136 * \param refresh Whether to refresh the StatusSignal before returning it;
4137 * defaults to true
4138 * \returns Fault_Hardware Status Signal Object
4139 */
4140 StatusSignal<bool> &GetFault_Hardware(bool refresh = true) final;
4141
4142 /**
4143 * \brief Hardware fault occurred
4144 *
4145 * - Default Value: False
4146 *
4147 * Default Rates:
4148 * - CAN: 4.0 Hz
4149 *
4150 * This refreshes and returns a cached StatusSignal object.
4151 *
4152 * \param refresh Whether to refresh the StatusSignal before returning it;
4153 * defaults to true
4154 * \returns StickyFault_Hardware Status Signal Object
4155 */
4156 StatusSignal<bool> &GetStickyFault_Hardware(bool refresh = true) final;
4157
4158 /**
4159 * \brief Processor temperature exceeded limit
4160 *
4161 * - Default Value: False
4162 *
4163 * Default Rates:
4164 * - CAN: 4.0 Hz
4165 *
4166 * This refreshes and returns a cached StatusSignal object.
4167 *
4168 * \param refresh Whether to refresh the StatusSignal before returning it;
4169 * defaults to true
4170 * \returns Fault_ProcTemp Status Signal Object
4171 */
4172 StatusSignal<bool> &GetFault_ProcTemp(bool refresh = true) final;
4173
4174 /**
4175 * \brief Processor temperature exceeded limit
4176 *
4177 * - Default Value: False
4178 *
4179 * Default Rates:
4180 * - CAN: 4.0 Hz
4181 *
4182 * This refreshes and returns a cached StatusSignal object.
4183 *
4184 * \param refresh Whether to refresh the StatusSignal before returning it;
4185 * defaults to true
4186 * \returns StickyFault_ProcTemp Status Signal Object
4187 */
4188 StatusSignal<bool> &GetStickyFault_ProcTemp(bool refresh = true) final;
4189
4190 /**
4191 * \brief Device temperature exceeded limit
4192 *
4193 * - Default Value: False
4194 *
4195 * Default Rates:
4196 * - CAN: 4.0 Hz
4197 *
4198 * This refreshes and returns a cached StatusSignal object.
4199 *
4200 * \param refresh Whether to refresh the StatusSignal before returning it;
4201 * defaults to true
4202 * \returns Fault_DeviceTemp Status Signal Object
4203 */
4204 StatusSignal<bool> &GetFault_DeviceTemp(bool refresh = true) final;
4205
4206 /**
4207 * \brief Device temperature exceeded limit
4208 *
4209 * - Default Value: False
4210 *
4211 * Default Rates:
4212 * - CAN: 4.0 Hz
4213 *
4214 * This refreshes and returns a cached StatusSignal object.
4215 *
4216 * \param refresh Whether to refresh the StatusSignal before returning it;
4217 * defaults to true
4218 * \returns StickyFault_DeviceTemp Status Signal Object
4219 */
4220 StatusSignal<bool> &GetStickyFault_DeviceTemp(bool refresh = true) final;
4221
4222 /**
4223 * \brief Device supply voltage dropped to near brownout levels
4224 *
4225 * - Default Value: False
4226 *
4227 * Default Rates:
4228 * - CAN: 4.0 Hz
4229 *
4230 * This refreshes and returns a cached StatusSignal object.
4231 *
4232 * \param refresh Whether to refresh the StatusSignal before returning it;
4233 * defaults to true
4234 * \returns Fault_Undervoltage Status Signal Object
4235 */
4236 StatusSignal<bool> &GetFault_Undervoltage(bool refresh = true) final;
4237
4238 /**
4239 * \brief Device supply voltage dropped to near brownout levels
4240 *
4241 * - Default Value: False
4242 *
4243 * Default Rates:
4244 * - CAN: 4.0 Hz
4245 *
4246 * This refreshes and returns a cached StatusSignal object.
4247 *
4248 * \param refresh Whether to refresh the StatusSignal before returning it;
4249 * defaults to true
4250 * \returns StickyFault_Undervoltage Status Signal Object
4251 */
4252 StatusSignal<bool> &GetStickyFault_Undervoltage(bool refresh = true) final;
4253
4254 /**
4255 * \brief Device boot while detecting the enable signal
4256 *
4257 * - Default Value: False
4258 *
4259 * Default Rates:
4260 * - CAN: 4.0 Hz
4261 *
4262 * This refreshes and returns a cached StatusSignal object.
4263 *
4264 * \param refresh Whether to refresh the StatusSignal before returning it;
4265 * defaults to true
4266 * \returns Fault_BootDuringEnable Status Signal Object
4267 */
4268 StatusSignal<bool> &GetFault_BootDuringEnable(bool refresh = true) final;
4269
4270 /**
4271 * \brief Device boot while detecting the enable signal
4272 *
4273 * - Default Value: False
4274 *
4275 * Default Rates:
4276 * - CAN: 4.0 Hz
4277 *
4278 * This refreshes and returns a cached StatusSignal object.
4279 *
4280 * \param refresh Whether to refresh the StatusSignal before returning it;
4281 * defaults to true
4282 * \returns StickyFault_BootDuringEnable Status Signal Object
4283 */
4284 StatusSignal<bool> &GetStickyFault_BootDuringEnable(bool refresh = true) final;
4285
4286 /**
4287 * \brief An unlicensed feature is in use, device may not behave as
4288 * expected.
4289 *
4290 * - Default Value: False
4291 *
4292 * Default Rates:
4293 * - CAN: 4.0 Hz
4294 *
4295 * This refreshes and returns a cached StatusSignal object.
4296 *
4297 * \param refresh Whether to refresh the StatusSignal before returning it;
4298 * defaults to true
4299 * \returns Fault_UnlicensedFeatureInUse Status Signal Object
4300 */
4301 StatusSignal<bool> &GetFault_UnlicensedFeatureInUse(bool refresh = true) final;
4302
4303 /**
4304 * \brief An unlicensed feature is in use, device may not behave as
4305 * expected.
4306 *
4307 * - Default Value: False
4308 *
4309 * Default Rates:
4310 * - CAN: 4.0 Hz
4311 *
4312 * This refreshes and returns a cached StatusSignal object.
4313 *
4314 * \param refresh Whether to refresh the StatusSignal before returning it;
4315 * defaults to true
4316 * \returns StickyFault_UnlicensedFeatureInUse Status Signal Object
4317 */
4318 StatusSignal<bool> &GetStickyFault_UnlicensedFeatureInUse(bool refresh = true) final;
4319
4320 /**
4321 * \brief Bridge was disabled most likely due to supply voltage
4322 * dropping too low.
4323 *
4324 * - Default Value: False
4325 *
4326 * Default Rates:
4327 * - CAN: 4.0 Hz
4328 *
4329 * This refreshes and returns a cached StatusSignal object.
4330 *
4331 * \param refresh Whether to refresh the StatusSignal before returning it;
4332 * defaults to true
4333 * \returns Fault_BridgeBrownout Status Signal Object
4334 */
4335 StatusSignal<bool> &GetFault_BridgeBrownout(bool refresh = true) final;
4336
4337 /**
4338 * \brief Bridge was disabled most likely due to supply voltage
4339 * dropping too low.
4340 *
4341 * - Default Value: False
4342 *
4343 * Default Rates:
4344 * - CAN: 4.0 Hz
4345 *
4346 * This refreshes and returns a cached StatusSignal object.
4347 *
4348 * \param refresh Whether to refresh the StatusSignal before returning it;
4349 * defaults to true
4350 * \returns StickyFault_BridgeBrownout Status Signal Object
4351 */
4352 StatusSignal<bool> &GetStickyFault_BridgeBrownout(bool refresh = true) final;
4353
4354 /**
4355 * \brief The remote sensor has reset.
4356 *
4357 * - Default Value: False
4358 *
4359 * Default Rates:
4360 * - CAN: 4.0 Hz
4361 *
4362 * This refreshes and returns a cached StatusSignal object.
4363 *
4364 * \param refresh Whether to refresh the StatusSignal before returning it;
4365 * defaults to true
4366 * \returns Fault_RemoteSensorReset Status Signal Object
4367 */
4368 StatusSignal<bool> &GetFault_RemoteSensorReset(bool refresh = true) final;
4369
4370 /**
4371 * \brief The remote sensor has reset.
4372 *
4373 * - Default Value: False
4374 *
4375 * Default Rates:
4376 * - CAN: 4.0 Hz
4377 *
4378 * This refreshes and returns a cached StatusSignal object.
4379 *
4380 * \param refresh Whether to refresh the StatusSignal before returning it;
4381 * defaults to true
4382 * \returns StickyFault_RemoteSensorReset Status Signal Object
4383 */
4384 StatusSignal<bool> &GetStickyFault_RemoteSensorReset(bool refresh = true) final;
4385
4386 /**
4387 * \brief The remote Talon used for differential control is not
4388 * present on CAN Bus.
4389 *
4390 * - Default Value: False
4391 *
4392 * Default Rates:
4393 * - CAN: 4.0 Hz
4394 *
4395 * This refreshes and returns a cached StatusSignal object.
4396 *
4397 * \param refresh Whether to refresh the StatusSignal before returning it;
4398 * defaults to true
4399 * \returns Fault_MissingDifferentialFX Status Signal Object
4400 */
4401 StatusSignal<bool> &GetFault_MissingDifferentialFX(bool refresh = true) final;
4402
4403 /**
4404 * \brief The remote Talon used for differential control is not
4405 * present on CAN Bus.
4406 *
4407 * - Default Value: False
4408 *
4409 * Default Rates:
4410 * - CAN: 4.0 Hz
4411 *
4412 * This refreshes and returns a cached StatusSignal object.
4413 *
4414 * \param refresh Whether to refresh the StatusSignal before returning it;
4415 * defaults to true
4416 * \returns StickyFault_MissingDifferentialFX Status Signal Object
4417 */
4418 StatusSignal<bool> &GetStickyFault_MissingDifferentialFX(bool refresh = true) final;
4419
4420 /**
4421 * \brief The remote sensor position has overflowed. Because of the
4422 * nature of remote sensors, it is possible for the remote sensor
4423 * position to overflow beyond what is supported by the status signal
4424 * frame. However, this is rare and cannot occur over the course of an
4425 * FRC match under normal use.
4426 *
4427 * - Default Value: False
4428 *
4429 * Default Rates:
4430 * - CAN: 4.0 Hz
4431 *
4432 * This refreshes and returns a cached StatusSignal object.
4433 *
4434 * \param refresh Whether to refresh the StatusSignal before returning it;
4435 * defaults to true
4436 * \returns Fault_RemoteSensorPosOverflow Status Signal Object
4437 */
4438 StatusSignal<bool> &GetFault_RemoteSensorPosOverflow(bool refresh = true) final;
4439
4440 /**
4441 * \brief The remote sensor position has overflowed. Because of the
4442 * nature of remote sensors, it is possible for the remote sensor
4443 * position to overflow beyond what is supported by the status signal
4444 * frame. However, this is rare and cannot occur over the course of an
4445 * FRC match under normal use.
4446 *
4447 * - Default Value: False
4448 *
4449 * Default Rates:
4450 * - CAN: 4.0 Hz
4451 *
4452 * This refreshes and returns a cached StatusSignal object.
4453 *
4454 * \param refresh Whether to refresh the StatusSignal before returning it;
4455 * defaults to true
4456 * \returns StickyFault_RemoteSensorPosOverflow Status Signal Object
4457 */
4458 StatusSignal<bool> &GetStickyFault_RemoteSensorPosOverflow(bool refresh = true) final;
4459
4460 /**
4461 * \brief Supply Voltage has exceeded the maximum voltage rating of
4462 * device.
4463 *
4464 * - Default Value: False
4465 *
4466 * Default Rates:
4467 * - CAN: 4.0 Hz
4468 *
4469 * This refreshes and returns a cached StatusSignal object.
4470 *
4471 * \param refresh Whether to refresh the StatusSignal before returning it;
4472 * defaults to true
4473 * \returns Fault_OverSupplyV Status Signal Object
4474 */
4475 StatusSignal<bool> &GetFault_OverSupplyV(bool refresh = true) final;
4476
4477 /**
4478 * \brief Supply Voltage has exceeded the maximum voltage rating of
4479 * device.
4480 *
4481 * - Default Value: False
4482 *
4483 * Default Rates:
4484 * - CAN: 4.0 Hz
4485 *
4486 * This refreshes and returns a cached StatusSignal object.
4487 *
4488 * \param refresh Whether to refresh the StatusSignal before returning it;
4489 * defaults to true
4490 * \returns StickyFault_OverSupplyV Status Signal Object
4491 */
4492 StatusSignal<bool> &GetStickyFault_OverSupplyV(bool refresh = true) final;
4493
4494 /**
4495 * \brief Supply Voltage is unstable. Ensure you are using a battery
4496 * and current limited power supply.
4497 *
4498 * - Default Value: False
4499 *
4500 * Default Rates:
4501 * - CAN: 4.0 Hz
4502 *
4503 * This refreshes and returns a cached StatusSignal object.
4504 *
4505 * \param refresh Whether to refresh the StatusSignal before returning it;
4506 * defaults to true
4507 * \returns Fault_UnstableSupplyV Status Signal Object
4508 */
4509 StatusSignal<bool> &GetFault_UnstableSupplyV(bool refresh = true) final;
4510
4511 /**
4512 * \brief Supply Voltage is unstable. Ensure you are using a battery
4513 * and current limited power supply.
4514 *
4515 * - Default Value: False
4516 *
4517 * Default Rates:
4518 * - CAN: 4.0 Hz
4519 *
4520 * This refreshes and returns a cached StatusSignal object.
4521 *
4522 * \param refresh Whether to refresh the StatusSignal before returning it;
4523 * defaults to true
4524 * \returns StickyFault_UnstableSupplyV Status Signal Object
4525 */
4526 StatusSignal<bool> &GetStickyFault_UnstableSupplyV(bool refresh = true) final;
4527
4528 /**
4529 * \brief Reverse limit switch has been asserted. Output is set to
4530 * neutral.
4531 *
4532 * - Default Value: False
4533 *
4534 * Default Rates:
4535 * - CAN: 4.0 Hz
4536 *
4537 * This refreshes and returns a cached StatusSignal object.
4538 *
4539 * \param refresh Whether to refresh the StatusSignal before returning it;
4540 * defaults to true
4541 * \returns Fault_ReverseHardLimit Status Signal Object
4542 */
4543 StatusSignal<bool> &GetFault_ReverseHardLimit(bool refresh = true) final;
4544
4545 /**
4546 * \brief Reverse limit switch has been asserted. Output is set to
4547 * neutral.
4548 *
4549 * - Default Value: False
4550 *
4551 * Default Rates:
4552 * - CAN: 4.0 Hz
4553 *
4554 * This refreshes and returns a cached StatusSignal object.
4555 *
4556 * \param refresh Whether to refresh the StatusSignal before returning it;
4557 * defaults to true
4558 * \returns StickyFault_ReverseHardLimit Status Signal Object
4559 */
4560 StatusSignal<bool> &GetStickyFault_ReverseHardLimit(bool refresh = true) final;
4561
4562 /**
4563 * \brief Forward limit switch has been asserted. Output is set to
4564 * neutral.
4565 *
4566 * - Default Value: False
4567 *
4568 * Default Rates:
4569 * - CAN: 4.0 Hz
4570 *
4571 * This refreshes and returns a cached StatusSignal object.
4572 *
4573 * \param refresh Whether to refresh the StatusSignal before returning it;
4574 * defaults to true
4575 * \returns Fault_ForwardHardLimit Status Signal Object
4576 */
4577 StatusSignal<bool> &GetFault_ForwardHardLimit(bool refresh = true) final;
4578
4579 /**
4580 * \brief Forward limit switch has been asserted. Output is set to
4581 * neutral.
4582 *
4583 * - Default Value: False
4584 *
4585 * Default Rates:
4586 * - CAN: 4.0 Hz
4587 *
4588 * This refreshes and returns a cached StatusSignal object.
4589 *
4590 * \param refresh Whether to refresh the StatusSignal before returning it;
4591 * defaults to true
4592 * \returns StickyFault_ForwardHardLimit Status Signal Object
4593 */
4594 StatusSignal<bool> &GetStickyFault_ForwardHardLimit(bool refresh = true) final;
4595
4596 /**
4597 * \brief Reverse soft limit has been asserted. Output is set to
4598 * neutral.
4599 *
4600 * - Default Value: False
4601 *
4602 * Default Rates:
4603 * - CAN: 4.0 Hz
4604 *
4605 * This refreshes and returns a cached StatusSignal object.
4606 *
4607 * \param refresh Whether to refresh the StatusSignal before returning it;
4608 * defaults to true
4609 * \returns Fault_ReverseSoftLimit Status Signal Object
4610 */
4611 StatusSignal<bool> &GetFault_ReverseSoftLimit(bool refresh = true) final;
4612
4613 /**
4614 * \brief Reverse soft limit has been asserted. Output is set to
4615 * neutral.
4616 *
4617 * - Default Value: False
4618 *
4619 * Default Rates:
4620 * - CAN: 4.0 Hz
4621 *
4622 * This refreshes and returns a cached StatusSignal object.
4623 *
4624 * \param refresh Whether to refresh the StatusSignal before returning it;
4625 * defaults to true
4626 * \returns StickyFault_ReverseSoftLimit Status Signal Object
4627 */
4628 StatusSignal<bool> &GetStickyFault_ReverseSoftLimit(bool refresh = true) final;
4629
4630 /**
4631 * \brief Forward soft limit has been asserted. Output is set to
4632 * neutral.
4633 *
4634 * - Default Value: False
4635 *
4636 * Default Rates:
4637 * - CAN: 4.0 Hz
4638 *
4639 * This refreshes and returns a cached StatusSignal object.
4640 *
4641 * \param refresh Whether to refresh the StatusSignal before returning it;
4642 * defaults to true
4643 * \returns Fault_ForwardSoftLimit Status Signal Object
4644 */
4645 StatusSignal<bool> &GetFault_ForwardSoftLimit(bool refresh = true) final;
4646
4647 /**
4648 * \brief Forward soft limit has been asserted. Output is set to
4649 * neutral.
4650 *
4651 * - Default Value: False
4652 *
4653 * Default Rates:
4654 * - CAN: 4.0 Hz
4655 *
4656 * This refreshes and returns a cached StatusSignal object.
4657 *
4658 * \param refresh Whether to refresh the StatusSignal before returning it;
4659 * defaults to true
4660 * \returns StickyFault_ForwardSoftLimit Status Signal Object
4661 */
4662 StatusSignal<bool> &GetStickyFault_ForwardSoftLimit(bool refresh = true) final;
4663
4664 /**
4665 * \brief The remote soft limit device is not present on CAN Bus.
4666 *
4667 * - Default Value: False
4668 *
4669 * Default Rates:
4670 * - CAN: 4.0 Hz
4671 *
4672 * This refreshes and returns a cached StatusSignal object.
4673 *
4674 * \param refresh Whether to refresh the StatusSignal before returning it;
4675 * defaults to true
4676 * \returns Fault_MissingSoftLimitRemote Status Signal Object
4677 */
4678 StatusSignal<bool> &GetFault_MissingSoftLimitRemote(bool refresh = true) final;
4679
4680 /**
4681 * \brief The remote soft limit device is not present on CAN Bus.
4682 *
4683 * - Default Value: False
4684 *
4685 * Default Rates:
4686 * - CAN: 4.0 Hz
4687 *
4688 * This refreshes and returns a cached StatusSignal object.
4689 *
4690 * \param refresh Whether to refresh the StatusSignal before returning it;
4691 * defaults to true
4692 * \returns StickyFault_MissingSoftLimitRemote Status Signal Object
4693 */
4694 StatusSignal<bool> &GetStickyFault_MissingSoftLimitRemote(bool refresh = true) final;
4695
4696 /**
4697 * \brief The remote limit switch device is not present on CAN Bus.
4698 *
4699 * - Default Value: False
4700 *
4701 * Default Rates:
4702 * - CAN: 4.0 Hz
4703 *
4704 * This refreshes and returns a cached StatusSignal object.
4705 *
4706 * \param refresh Whether to refresh the StatusSignal before returning it;
4707 * defaults to true
4708 * \returns Fault_MissingHardLimitRemote Status Signal Object
4709 */
4710 StatusSignal<bool> &GetFault_MissingHardLimitRemote(bool refresh = true) final;
4711
4712 /**
4713 * \brief The remote limit switch device is not present on CAN Bus.
4714 *
4715 * - Default Value: False
4716 *
4717 * Default Rates:
4718 * - CAN: 4.0 Hz
4719 *
4720 * This refreshes and returns a cached StatusSignal object.
4721 *
4722 * \param refresh Whether to refresh the StatusSignal before returning it;
4723 * defaults to true
4724 * \returns StickyFault_MissingHardLimitRemote Status Signal Object
4725 */
4726 StatusSignal<bool> &GetStickyFault_MissingHardLimitRemote(bool refresh = true) final;
4727
4728 /**
4729 * \brief The remote sensor's data is no longer trusted. This can
4730 * happen if the remote sensor disappears from the CAN bus or if the
4731 * remote sensor indicates its data is no longer valid, such as when a
4732 * CANcoder's magnet strength falls into the "red" range.
4733 *
4734 * - Default Value: False
4735 *
4736 * Default Rates:
4737 * - CAN: 4.0 Hz
4738 *
4739 * This refreshes and returns a cached StatusSignal object.
4740 *
4741 * \param refresh Whether to refresh the StatusSignal before returning it;
4742 * defaults to true
4743 * \returns Fault_RemoteSensorDataInvalid Status Signal Object
4744 */
4745 StatusSignal<bool> &GetFault_RemoteSensorDataInvalid(bool refresh = true) final;
4746
4747 /**
4748 * \brief The remote sensor's data is no longer trusted. This can
4749 * happen if the remote sensor disappears from the CAN bus or if the
4750 * remote sensor indicates its data is no longer valid, such as when a
4751 * CANcoder's magnet strength falls into the "red" range.
4752 *
4753 * - Default Value: False
4754 *
4755 * Default Rates:
4756 * - CAN: 4.0 Hz
4757 *
4758 * This refreshes and returns a cached StatusSignal object.
4759 *
4760 * \param refresh Whether to refresh the StatusSignal before returning it;
4761 * defaults to true
4762 * \returns StickyFault_RemoteSensorDataInvalid Status Signal Object
4763 */
4764 StatusSignal<bool> &GetStickyFault_RemoteSensorDataInvalid(bool refresh = true) final;
4765
4766 /**
4767 * \brief The remote sensor used for fusion has fallen out of sync to
4768 * the local sensor. A re-synchronization has occurred, which may
4769 * cause a discontinuity. This typically happens if there is
4770 * significant slop in the mechanism, or if the RotorToSensorRatio
4771 * configuration parameter is incorrect.
4772 *
4773 * - Default Value: False
4774 *
4775 * Default Rates:
4776 * - CAN: 4.0 Hz
4777 *
4778 * This refreshes and returns a cached StatusSignal object.
4779 *
4780 * \param refresh Whether to refresh the StatusSignal before returning it;
4781 * defaults to true
4782 * \returns Fault_FusedSensorOutOfSync Status Signal Object
4783 */
4784 StatusSignal<bool> &GetFault_FusedSensorOutOfSync(bool refresh = true) final;
4785
4786 /**
4787 * \brief The remote sensor used for fusion has fallen out of sync to
4788 * the local sensor. A re-synchronization has occurred, which may
4789 * cause a discontinuity. This typically happens if there is
4790 * significant slop in the mechanism, or if the RotorToSensorRatio
4791 * configuration parameter is incorrect.
4792 *
4793 * - Default Value: False
4794 *
4795 * Default Rates:
4796 * - CAN: 4.0 Hz
4797 *
4798 * This refreshes and returns a cached StatusSignal object.
4799 *
4800 * \param refresh Whether to refresh the StatusSignal before returning it;
4801 * defaults to true
4802 * \returns StickyFault_FusedSensorOutOfSync Status Signal Object
4803 */
4804 StatusSignal<bool> &GetStickyFault_FusedSensorOutOfSync(bool refresh = true) final;
4805
4806 /**
4807 * \brief Stator current limit occured.
4808 *
4809 * - Default Value: False
4810 *
4811 * Default Rates:
4812 * - CAN: 4.0 Hz
4813 *
4814 * This refreshes and returns a cached StatusSignal object.
4815 *
4816 * \param refresh Whether to refresh the StatusSignal before returning it;
4817 * defaults to true
4818 * \returns Fault_StatorCurrLimit Status Signal Object
4819 */
4820 StatusSignal<bool> &GetFault_StatorCurrLimit(bool refresh = true) final;
4821
4822 /**
4823 * \brief Stator current limit occured.
4824 *
4825 * - Default Value: False
4826 *
4827 * Default Rates:
4828 * - CAN: 4.0 Hz
4829 *
4830 * This refreshes and returns a cached StatusSignal object.
4831 *
4832 * \param refresh Whether to refresh the StatusSignal before returning it;
4833 * defaults to true
4834 * \returns StickyFault_StatorCurrLimit Status Signal Object
4835 */
4836 StatusSignal<bool> &GetStickyFault_StatorCurrLimit(bool refresh = true) final;
4837
4838 /**
4839 * \brief Supply current limit occured.
4840 *
4841 * - Default Value: False
4842 *
4843 * Default Rates:
4844 * - CAN: 4.0 Hz
4845 *
4846 * This refreshes and returns a cached StatusSignal object.
4847 *
4848 * \param refresh Whether to refresh the StatusSignal before returning it;
4849 * defaults to true
4850 * \returns Fault_SupplyCurrLimit Status Signal Object
4851 */
4852 StatusSignal<bool> &GetFault_SupplyCurrLimit(bool refresh = true) final;
4853
4854 /**
4855 * \brief Supply current limit occured.
4856 *
4857 * - Default Value: False
4858 *
4859 * Default Rates:
4860 * - CAN: 4.0 Hz
4861 *
4862 * This refreshes and returns a cached StatusSignal object.
4863 *
4864 * \param refresh Whether to refresh the StatusSignal before returning it;
4865 * defaults to true
4866 * \returns StickyFault_SupplyCurrLimit Status Signal Object
4867 */
4868 StatusSignal<bool> &GetStickyFault_SupplyCurrLimit(bool refresh = true) final;
4869
4870 /**
4871 * \brief Using Fused CANcoder feature while unlicensed. Device has
4872 * fallen back to remote CANcoder.
4873 *
4874 * - Default Value: False
4875 *
4876 * Default Rates:
4877 * - CAN: 4.0 Hz
4878 *
4879 * This refreshes and returns a cached StatusSignal object.
4880 *
4881 * \param refresh Whether to refresh the StatusSignal before returning it;
4882 * defaults to true
4883 * \returns Fault_UsingFusedCANcoderWhileUnlicensed Status Signal Object
4884 */
4885 StatusSignal<bool> &GetFault_UsingFusedCANcoderWhileUnlicensed(bool refresh = true) final;
4886
4887 /**
4888 * \brief Using Fused CANcoder feature while unlicensed. Device has
4889 * fallen back to remote CANcoder.
4890 *
4891 * - Default Value: False
4892 *
4893 * Default Rates:
4894 * - CAN: 4.0 Hz
4895 *
4896 * This refreshes and returns a cached StatusSignal object.
4897 *
4898 * \param refresh Whether to refresh the StatusSignal before returning it;
4899 * defaults to true
4900 * \returns StickyFault_UsingFusedCANcoderWhileUnlicensed Status Signal Object
4901 */
4902 StatusSignal<bool> &GetStickyFault_UsingFusedCANcoderWhileUnlicensed(bool refresh = true) final;
4903
4904 /**
4905 * \brief Static brake was momentarily disabled due to excessive
4906 * braking current while disabled.
4907 *
4908 * - Default Value: False
4909 *
4910 * Default Rates:
4911 * - CAN: 4.0 Hz
4912 *
4913 * This refreshes and returns a cached StatusSignal object.
4914 *
4915 * \param refresh Whether to refresh the StatusSignal before returning it;
4916 * defaults to true
4917 * \returns Fault_StaticBrakeDisabled Status Signal Object
4918 */
4919 StatusSignal<bool> &GetFault_StaticBrakeDisabled(bool refresh = true) final;
4920
4921 /**
4922 * \brief Static brake was momentarily disabled due to excessive
4923 * braking current while disabled.
4924 *
4925 * - Default Value: False
4926 *
4927 * Default Rates:
4928 * - CAN: 4.0 Hz
4929 *
4930 * This refreshes and returns a cached StatusSignal object.
4931 *
4932 * \param refresh Whether to refresh the StatusSignal before returning it;
4933 * defaults to true
4934 * \returns StickyFault_StaticBrakeDisabled Status Signal Object
4935 */
4936 StatusSignal<bool> &GetStickyFault_StaticBrakeDisabled(bool refresh = true) final;
4937
4938 /**
4939 * \brief Trips if a major mechanical or ESD event caused a brief loss
4940 * of position data triggering a recovery while not in motion. If the
4941 * event occurs often, inspect for excess axial force or sources of
4942 * ESD at the rotor.
4943 *
4944 * - Default Value: False
4945 *
4946 * Default Rates:
4947 * - CAN: 4.0 Hz
4948 *
4949 * This refreshes and returns a cached StatusSignal object.
4950 *
4951 * \param refresh Whether to refresh the StatusSignal before returning it;
4952 * defaults to true
4953 * \returns Fault_RotorFault1 Status Signal Object
4954 */
4955 StatusSignal<bool> &GetFault_RotorFault1(bool refresh = true) final;
4956
4957 /**
4958 * \brief Trips if a major mechanical or ESD event caused a brief loss
4959 * of position data triggering a recovery while not in motion. If the
4960 * event occurs often, inspect for excess axial force or sources of
4961 * ESD at the rotor.
4962 *
4963 * - Default Value: False
4964 *
4965 * Default Rates:
4966 * - CAN: 4.0 Hz
4967 *
4968 * This refreshes and returns a cached StatusSignal object.
4969 *
4970 * \param refresh Whether to refresh the StatusSignal before returning it;
4971 * defaults to true
4972 * \returns StickyFault_RotorFault1 Status Signal Object
4973 */
4974 StatusSignal<bool> &GetStickyFault_RotorFault1(bool refresh = true) final;
4975
4976 /**
4977 * \brief Trips if a major mechanical or ESD event caused a brief loss
4978 * of position data triggering a recovery while in motion. If the
4979 * event occurs often, inspect for excess axial force or sources of
4980 * ESD at the rotor.
4981 *
4982 * - Default Value: False
4983 *
4984 * Default Rates:
4985 * - CAN: 4.0 Hz
4986 *
4987 * This refreshes and returns a cached StatusSignal object.
4988 *
4989 * \param refresh Whether to refresh the StatusSignal before returning it;
4990 * defaults to true
4991 * \returns Fault_RotorFault2 Status Signal Object
4992 */
4993 StatusSignal<bool> &GetFault_RotorFault2(bool refresh = true) final;
4994
4995 /**
4996 * \brief Trips if a major mechanical or ESD event caused a brief loss
4997 * of position data triggering a recovery while in motion. If the
4998 * event occurs often, inspect for excess axial force or sources of
4999 * ESD at the rotor.
5000 *
5001 * - Default Value: False
5002 *
5003 * Default Rates:
5004 * - CAN: 4.0 Hz
5005 *
5006 * This refreshes and returns a cached StatusSignal object.
5007 *
5008 * \param refresh Whether to refresh the StatusSignal before returning it;
5009 * defaults to true
5010 * \returns StickyFault_RotorFault2 Status Signal Object
5011 */
5012 StatusSignal<bool> &GetStickyFault_RotorFault2(bool refresh = true) final;
5013
5014 /**
5015 * \brief Closed loop proportional component.
5016 *
5017 * \details The portion of the closed loop output that is proportional
5018 * to the error. Alternatively, the kP contribution of the closed loop
5019 * output.
5020 *
5021 * When using differential control, this applies to the average axis.
5022 *
5023 * Default Rates:
5024 * - CAN 2.0: 4.0 Hz
5025 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5026 *
5027 * This refreshes and returns a cached StatusSignal object.
5028 *
5029 * \param refresh Whether to refresh the StatusSignal before returning it;
5030 * defaults to true
5031 * \returns ClosedLoopProportionalOutput Status Signal object
5032 */
5033 StatusSignal<double> &GetClosedLoopProportionalOutput(bool refresh = true) final;
5034
5035 /**
5036 * \brief Closed loop integrated component.
5037 *
5038 * \details The portion of the closed loop output that is proportional
5039 * to the integrated error. Alternatively, the kI contribution of the
5040 * closed loop output.
5041 *
5042 * When using differential control, this applies to the average axis.
5043 *
5044 * Default Rates:
5045 * - CAN 2.0: 4.0 Hz
5046 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5047 *
5048 * This refreshes and returns a cached StatusSignal object.
5049 *
5050 * \param refresh Whether to refresh the StatusSignal before returning it;
5051 * defaults to true
5052 * \returns ClosedLoopIntegratedOutput Status Signal object
5053 */
5054 StatusSignal<double> &GetClosedLoopIntegratedOutput(bool refresh = true) final;
5055
5056 /**
5057 * \brief Feedforward passed by the user.
5058 *
5059 * \details This is the general feedforward that the user provides for
5060 * the closed loop.
5061 *
5062 * When using differential control, this applies to the average axis.
5063 *
5064 * Default Rates:
5065 * - CAN 2.0: 4.0 Hz
5066 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5067 *
5068 * This refreshes and returns a cached StatusSignal object.
5069 *
5070 * \param refresh Whether to refresh the StatusSignal before returning it;
5071 * defaults to true
5072 * \returns ClosedLoopFeedForward Status Signal object
5073 */
5074 StatusSignal<double> &GetClosedLoopFeedForward(bool refresh = true) final;
5075
5076 /**
5077 * \brief Closed loop derivative component.
5078 *
5079 * \details The portion of the closed loop output that is proportional
5080 * to the deriviative of error. Alternatively, the kD contribution of
5081 * the closed loop output.
5082 *
5083 * When using differential control, this applies to the average axis.
5084 *
5085 * Default Rates:
5086 * - CAN 2.0: 4.0 Hz
5087 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5088 *
5089 * This refreshes and returns a cached StatusSignal object.
5090 *
5091 * \param refresh Whether to refresh the StatusSignal before returning it;
5092 * defaults to true
5093 * \returns ClosedLoopDerivativeOutput Status Signal object
5094 */
5095 StatusSignal<double> &GetClosedLoopDerivativeOutput(bool refresh = true) final;
5096
5097 /**
5098 * \brief Closed loop total output.
5099 *
5100 * \details The total output of the closed loop output.
5101 *
5102 * When using differential control, this applies to the average axis.
5103 *
5104 * Default Rates:
5105 * - CAN 2.0: 4.0 Hz
5106 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5107 *
5108 * This refreshes and returns a cached StatusSignal object.
5109 *
5110 * \param refresh Whether to refresh the StatusSignal before returning it;
5111 * defaults to true
5112 * \returns ClosedLoopOutput Status Signal object
5113 */
5114 StatusSignal<double> &GetClosedLoopOutput(bool refresh = true) final;
5115
5116 /**
5117 * \brief Value that the closed loop is targeting.
5118 *
5119 * \details This is the value that the closed loop PID controller
5120 * targets.
5121 *
5122 * When using differential control, this applies to the average axis.
5123 *
5124 * Default Rates:
5125 * - CAN 2.0: 4.0 Hz
5126 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5127 *
5128 * This refreshes and returns a cached StatusSignal object.
5129 *
5130 * \param refresh Whether to refresh the StatusSignal before returning it;
5131 * defaults to true
5132 * \returns ClosedLoopReference Status Signal object
5133 */
5134 StatusSignal<double> &GetClosedLoopReference(bool refresh = true) final;
5135
5136 /**
5137 * \brief Derivative of the target that the closed loop is targeting.
5138 *
5139 * \details This is the change in the closed loop reference. This may
5140 * be used in the feed-forward calculation, the derivative-error, or
5141 * in application of the signage for kS. Typically, this represents
5142 * the target velocity during Motion Magic®.
5143 *
5144 * When using differential control, this applies to the average axis.
5145 *
5146 * Default Rates:
5147 * - CAN 2.0: 4.0 Hz
5148 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5149 *
5150 * This refreshes and returns a cached StatusSignal object.
5151 *
5152 * \param refresh Whether to refresh the StatusSignal before returning it;
5153 * defaults to true
5154 * \returns ClosedLoopReferenceSlope Status Signal object
5155 */
5156 StatusSignal<double> &GetClosedLoopReferenceSlope(bool refresh = true) final;
5157
5158 /**
5159 * \brief The difference between target reference and current
5160 * measurement.
5161 *
5162 * \details This is the value that is treated as the error in the PID
5163 * loop.
5164 *
5165 * When using differential control, this applies to the average axis.
5166 *
5167 * Default Rates:
5168 * - CAN 2.0: 4.0 Hz
5169 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5170 *
5171 * This refreshes and returns a cached StatusSignal object.
5172 *
5173 * \param refresh Whether to refresh the StatusSignal before returning it;
5174 * defaults to true
5175 * \returns ClosedLoopError Status Signal object
5176 */
5177 StatusSignal<double> &GetClosedLoopError(bool refresh = true) final;
5178
5179 /**
5180 * \brief The calculated motor output for differential followers.
5181 *
5182 * \details This is a torque request when using the TorqueCurrentFOC
5183 * control output type, a voltage request when using the Voltage
5184 * control output type, and a duty cycle when using the DutyCycle
5185 * control output type.
5186 *
5187 * Default Rates:
5188 * - CAN 2.0: 100.0 Hz
5189 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5190 *
5191 * This refreshes and returns a cached StatusSignal object.
5192 *
5193 * \param refresh Whether to refresh the StatusSignal before returning it;
5194 * defaults to true
5195 * \returns DifferentialOutput Status Signal object
5196 */
5197 StatusSignal<double> &GetDifferentialOutput(bool refresh = true) final;
5198
5199 /**
5200 * \brief Differential closed loop proportional component.
5201 *
5202 * \details The portion of the differential closed loop output (on the
5203 * difference axis) that is proportional to the error. Alternatively,
5204 * the kP contribution of the closed loop output.
5205 *
5206 * Default Rates:
5207 * - CAN 2.0: 4.0 Hz
5208 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5209 *
5210 * This refreshes and returns a cached StatusSignal object.
5211 *
5212 * \param refresh Whether to refresh the StatusSignal before returning it;
5213 * defaults to true
5214 * \returns DifferentialClosedLoopProportionalOutput Status Signal object
5215 */
5216 StatusSignal<double> &GetDifferentialClosedLoopProportionalOutput(bool refresh = true) final;
5217
5218 /**
5219 * \brief Differential closed loop integrated component.
5220 *
5221 * \details The portion of the differential closed loop output (on the
5222 * difference axis) that is proportional to the integrated error.
5223 * Alternatively, the kI contribution of the closed loop output.
5224 *
5225 * Default Rates:
5226 * - CAN 2.0: 100.0 Hz
5227 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5228 *
5229 * This refreshes and returns a cached StatusSignal object.
5230 *
5231 * \param refresh Whether to refresh the StatusSignal before returning it;
5232 * defaults to true
5233 * \returns DifferentialClosedLoopIntegratedOutput Status Signal object
5234 */
5235 StatusSignal<double> &GetDifferentialClosedLoopIntegratedOutput(bool refresh = true) final;
5236
5237 /**
5238 * \brief Differential Feedforward passed by the user.
5239 *
5240 * \details This is the general feedforward that the user provides for
5241 * the differential closed loop (on the difference axis).
5242 *
5243 * Default Rates:
5244 * - CAN 2.0: 100.0 Hz
5245 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5246 *
5247 * This refreshes and returns a cached StatusSignal object.
5248 *
5249 * \param refresh Whether to refresh the StatusSignal before returning it;
5250 * defaults to true
5251 * \returns DifferentialClosedLoopFeedForward Status Signal object
5252 */
5253 StatusSignal<double> &GetDifferentialClosedLoopFeedForward(bool refresh = true) final;
5254
5255 /**
5256 * \brief Differential closed loop derivative component.
5257 *
5258 * \details The portion of the differential closed loop output (on the
5259 * difference axis) that is proportional to the deriviative of error.
5260 * Alternatively, the kD contribution of the closed loop output.
5261 *
5262 * Default Rates:
5263 * - CAN 2.0: 4.0 Hz
5264 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5265 *
5266 * This refreshes and returns a cached StatusSignal object.
5267 *
5268 * \param refresh Whether to refresh the StatusSignal before returning it;
5269 * defaults to true
5270 * \returns DifferentialClosedLoopDerivativeOutput Status Signal object
5271 */
5272 StatusSignal<double> &GetDifferentialClosedLoopDerivativeOutput(bool refresh = true) final;
5273
5274 /**
5275 * \brief Differential closed loop total output.
5276 *
5277 * \details The total output of the differential closed loop output
5278 * (on the difference axis).
5279 *
5280 * Default Rates:
5281 * - CAN 2.0: 4.0 Hz
5282 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5283 *
5284 * This refreshes and returns a cached StatusSignal object.
5285 *
5286 * \param refresh Whether to refresh the StatusSignal before returning it;
5287 * defaults to true
5288 * \returns DifferentialClosedLoopOutput Status Signal object
5289 */
5290 StatusSignal<double> &GetDifferentialClosedLoopOutput(bool refresh = true) final;
5291
5292 /**
5293 * \brief Value that the differential closed loop is targeting.
5294 *
5295 * \details This is the value that the differential closed loop PID
5296 * controller targets (on the difference axis).
5297 *
5298 * Default Rates:
5299 * - CAN 2.0: 4.0 Hz
5300 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5301 *
5302 * This refreshes and returns a cached StatusSignal object.
5303 *
5304 * \param refresh Whether to refresh the StatusSignal before returning it;
5305 * defaults to true
5306 * \returns DifferentialClosedLoopReference Status Signal object
5307 */
5308 StatusSignal<double> &GetDifferentialClosedLoopReference(bool refresh = true) final;
5309
5310 /**
5311 * \brief Derivative of the target that the differential closed loop
5312 * is targeting.
5313 *
5314 * \details This is the change in the closed loop reference (on the
5315 * difference axis). This may be used in the feed-forward calculation,
5316 * the derivative-error, or in application of the signage for kS.
5317 * Typically, this represents the target velocity during Motion
5318 * Magic®.
5319 *
5320 * Default Rates:
5321 * - CAN 2.0: 4.0 Hz
5322 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5323 *
5324 * This refreshes and returns a cached StatusSignal object.
5325 *
5326 * \param refresh Whether to refresh the StatusSignal before returning it;
5327 * defaults to true
5328 * \returns DifferentialClosedLoopReferenceSlope Status Signal object
5329 */
5330 StatusSignal<double> &GetDifferentialClosedLoopReferenceSlope(bool refresh = true) final;
5331
5332 /**
5333 * \brief The difference between target differential reference and
5334 * current measurement.
5335 *
5336 * \details This is the value that is treated as the error in the
5337 * differential PID loop (on the difference axis).
5338 *
5339 * Default Rates:
5340 * - CAN 2.0: 4.0 Hz
5341 * - CAN FD: 100.0 Hz (TimeSynced with Pro)
5342 *
5343 * This refreshes and returns a cached StatusSignal object.
5344 *
5345 * \param refresh Whether to refresh the StatusSignal before returning it;
5346 * defaults to true
5347 * \returns DifferentialClosedLoopError Status Signal object
5348 */
5349 StatusSignal<double> &GetDifferentialClosedLoopError(bool refresh = true) final;
5350
5351
5352 /**
5353 * \brief Request a specified motor duty cycle.
5354 *
5355 * \details This control mode will output a proportion of the supplied
5356 * voltage which is supplied by the user.
5357 *
5358 * - DutyCycleOut Parameters:
5359 * - Output: Proportion of supply voltage to apply in fractional units between
5360 * -1 and +1
5361 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
5362 * which increases peak power by ~15% on supported devices (see
5363 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
5364 * commutation.
5365 *
5366 * FOC improves motor performance by leveraging torque (current)
5367 * control. However, this may be inconvenient for applications
5368 * that require specifying duty cycle or voltage.
5369 * CTR-Electronics has developed a hybrid method that combines
5370 * the performances gains of FOC while still allowing
5371 * applications to provide duty cycle or voltage demand. This
5372 * not to be confused with simple sinusoidal control or phase
5373 * voltage control which lacks the performance gains.
5374 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
5375 * output is zero (or within deadband). Set to
5376 * false to use the NeutralMode configuration
5377 * setting (default). This flag exists to provide
5378 * the fundamental behavior of this control when
5379 * output is zero, which is to provide 0V to the
5380 * motor.
5381 * - LimitForwardMotion: Set to true to force forward limiting. This allows
5382 * users to use other limit switch sensors connected to
5383 * robot controller. This also allows use of active
5384 * sensors that require external power.
5385 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
5386 * users to use other limit switch sensors connected to
5387 * robot controller. This also allows use of active
5388 * sensors that require external power.
5389 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
5390 * the LimitForwardMotion and LimitReverseMotion
5391 * parameters, instead allowing motion.
5392 *
5393 * This can be useful on mechanisms such as an
5394 * intake/feeder, where a limit switch stops motion
5395 * while intaking but should be ignored when feeding
5396 * to a shooter.
5397 *
5398 * The hardware limit faults and Forward/ReverseLimit
5399 * signals will still report the values of the limit
5400 * switches regardless of this parameter.
5401 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
5402 * allowing motion.
5403 *
5404 * This can be useful when calibrating the zero point
5405 * of a mechanism such as an elevator.
5406 *
5407 * The software limit faults will still report the
5408 * values of the software limits regardless of this
5409 * parameter.
5410 * - UseTimesync: Set to true to delay applying this control request until a
5411 * timesync boundary (requires Phoenix Pro and CANivore). This
5412 * eliminates the impact of nondeterministic network delays in
5413 * exchange for a larger but deterministic control latency.
5414 *
5415 * This requires setting the ControlTimesyncFreqHz config in
5416 * MotorOutputConfigs. Additionally, when this is enabled, the
5417 * UpdateFreqHz of this request should be set to 0 Hz.
5418 *
5419 * \param request Control object to request of the device
5420 * \returns Status Code of the request, 0 is OK
5421 */
5422 ctre::phoenix::StatusCode SetControl(const controls::DutyCycleOut &request) final;
5423
5424 /**
5425 * \brief Request a specified motor current (field oriented control).
5426 *
5427 * \details This control request will drive the motor to the requested
5428 * motor (stator) current value. This leverages field oriented
5429 * control (FOC), which means greater peak power than what is
5430 * documented. This scales to torque based on Motor's kT constant.
5431 *
5432 * - TorqueCurrentFOC Parameters:
5433 * - Output: Amount of motor current in Amperes
5434 * - MaxAbsDutyCycle: The maximum absolute motor output that can be applied,
5435 * which effectively limits the velocity. For example, 0.50
5436 * means no more than 50% output in either direction. This
5437 * is useful for preventing the motor from spinning to its
5438 * terminal velocity when there is no external torque
5439 * applied unto the rotor. Note this is absolute maximum,
5440 * so the value should be between zero and one.
5441 * - Deadband: Deadband in Amperes. If torque request is within deadband, the
5442 * bridge output is neutral. If deadband is set to zero then there
5443 * is effectively no deadband. Note if deadband is zero, a free
5444 * spinning motor will spin for quite a while as the firmware
5445 * attempts to hold the motor's bemf. If user expects motor to
5446 * cease spinning quickly with a demand of zero, we recommend a
5447 * deadband of one Ampere. This value will be converted to an
5448 * integral value of amps.
5449 * - OverrideCoastDurNeutral: Set to true to coast the rotor when output is
5450 * zero (or within deadband). Set to false to use
5451 * the NeutralMode configuration setting (default).
5452 * This flag exists to provide the fundamental
5453 * behavior of this control when output is zero,
5454 * which is to provide 0A (zero torque).
5455 * - LimitForwardMotion: Set to true to force forward limiting. This allows
5456 * users to use other limit switch sensors connected to
5457 * robot controller. This also allows use of active
5458 * sensors that require external power.
5459 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
5460 * users to use other limit switch sensors connected to
5461 * robot controller. This also allows use of active
5462 * sensors that require external power.
5463 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
5464 * the LimitForwardMotion and LimitReverseMotion
5465 * parameters, instead allowing motion.
5466 *
5467 * This can be useful on mechanisms such as an
5468 * intake/feeder, where a limit switch stops motion
5469 * while intaking but should be ignored when feeding
5470 * to a shooter.
5471 *
5472 * The hardware limit faults and Forward/ReverseLimit
5473 * signals will still report the values of the limit
5474 * switches regardless of this parameter.
5475 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
5476 * allowing motion.
5477 *
5478 * This can be useful when calibrating the zero point
5479 * of a mechanism such as an elevator.
5480 *
5481 * The software limit faults will still report the
5482 * values of the software limits regardless of this
5483 * parameter.
5484 * - UseTimesync: Set to true to delay applying this control request until a
5485 * timesync boundary (requires Phoenix Pro and CANivore). This
5486 * eliminates the impact of nondeterministic network delays in
5487 * exchange for a larger but deterministic control latency.
5488 *
5489 * This requires setting the ControlTimesyncFreqHz config in
5490 * MotorOutputConfigs. Additionally, when this is enabled, the
5491 * UpdateFreqHz of this request should be set to 0 Hz.
5492 *
5493 * \param request Control object to request of the device
5494 * \returns Status Code of the request, 0 is OK
5495 */
5496 ctre::phoenix::StatusCode SetControl(const controls::TorqueCurrentFOC &request) final;
5497
5498 /**
5499 * \brief Request a specified voltage.
5500 *
5501 * \details This control mode will attempt to apply the specified
5502 * voltage to the motor. If the supply voltage is below the requested
5503 * voltage, the motor controller will output the supply voltage.
5504 *
5505 * - VoltageOut Parameters:
5506 * - Output: Voltage to attempt to drive at
5507 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
5508 * which increases peak power by ~15% on supported devices (see
5509 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
5510 * commutation.
5511 *
5512 * FOC improves motor performance by leveraging torque (current)
5513 * control. However, this may be inconvenient for applications
5514 * that require specifying duty cycle or voltage.
5515 * CTR-Electronics has developed a hybrid method that combines
5516 * the performances gains of FOC while still allowing
5517 * applications to provide duty cycle or voltage demand. This
5518 * not to be confused with simple sinusoidal control or phase
5519 * voltage control which lacks the performance gains.
5520 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
5521 * output is zero (or within deadband). Set to
5522 * false to use the NeutralMode configuration
5523 * setting (default). This flag exists to provide
5524 * the fundamental behavior of this control when
5525 * output is zero, which is to provide 0V to the
5526 * motor.
5527 * - LimitForwardMotion: Set to true to force forward limiting. This allows
5528 * users to use other limit switch sensors connected to
5529 * robot controller. This also allows use of active
5530 * sensors that require external power.
5531 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
5532 * users to use other limit switch sensors connected to
5533 * robot controller. This also allows use of active
5534 * sensors that require external power.
5535 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
5536 * the LimitForwardMotion and LimitReverseMotion
5537 * parameters, instead allowing motion.
5538 *
5539 * This can be useful on mechanisms such as an
5540 * intake/feeder, where a limit switch stops motion
5541 * while intaking but should be ignored when feeding
5542 * to a shooter.
5543 *
5544 * The hardware limit faults and Forward/ReverseLimit
5545 * signals will still report the values of the limit
5546 * switches regardless of this parameter.
5547 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
5548 * allowing motion.
5549 *
5550 * This can be useful when calibrating the zero point
5551 * of a mechanism such as an elevator.
5552 *
5553 * The software limit faults will still report the
5554 * values of the software limits regardless of this
5555 * parameter.
5556 * - UseTimesync: Set to true to delay applying this control request until a
5557 * timesync boundary (requires Phoenix Pro and CANivore). This
5558 * eliminates the impact of nondeterministic network delays in
5559 * exchange for a larger but deterministic control latency.
5560 *
5561 * This requires setting the ControlTimesyncFreqHz config in
5562 * MotorOutputConfigs. Additionally, when this is enabled, the
5563 * UpdateFreqHz of this request should be set to 0 Hz.
5564 *
5565 * \param request Control object to request of the device
5566 * \returns Status Code of the request, 0 is OK
5567 */
5568 ctre::phoenix::StatusCode SetControl(const controls::VoltageOut &request) final;
5569
5570 /**
5571 * \brief Request PID to target position with duty cycle feedforward.
5572 *
5573 * \details This control mode will set the motor's position setpoint
5574 * to the position specified by the user. In addition, it will apply
5575 * an additional duty cycle as an arbitrary feedforward value.
5576 *
5577 * - PositionDutyCycle Parameters:
5578 * - Position: Position to drive toward in rotations.
5579 * - Velocity: Velocity to drive toward in rotations per second. This is
5580 * typically used for motion profiles generated by the robot
5581 * program.
5582 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
5583 * which increases peak power by ~15% on supported devices (see
5584 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
5585 * commutation.
5586 *
5587 * FOC improves motor performance by leveraging torque (current)
5588 * control. However, this may be inconvenient for applications
5589 * that require specifying duty cycle or voltage.
5590 * CTR-Electronics has developed a hybrid method that combines
5591 * the performances gains of FOC while still allowing
5592 * applications to provide duty cycle or voltage demand. This
5593 * not to be confused with simple sinusoidal control or phase
5594 * voltage control which lacks the performance gains.
5595 * - FeedForward: Feedforward to apply in fractional units between -1 and +1.
5596 * This is added to the output of the onboard feedforward
5597 * terms.
5598 * - Slot: Select which gains are applied by selecting the slot. Use the
5599 * configuration api to set the gain values for the selected slot
5600 * before enabling this feature. Slot must be within [0,2].
5601 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
5602 * output is zero (or within deadband). Set to
5603 * false to use the NeutralMode configuration
5604 * setting (default). This flag exists to provide
5605 * the fundamental behavior of this control when
5606 * output is zero, which is to provide 0V to the
5607 * motor.
5608 * - LimitForwardMotion: Set to true to force forward limiting. This allows
5609 * users to use other limit switch sensors connected to
5610 * robot controller. This also allows use of active
5611 * sensors that require external power.
5612 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
5613 * users to use other limit switch sensors connected to
5614 * robot controller. This also allows use of active
5615 * sensors that require external power.
5616 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
5617 * the LimitForwardMotion and LimitReverseMotion
5618 * parameters, instead allowing motion.
5619 *
5620 * This can be useful on mechanisms such as an
5621 * intake/feeder, where a limit switch stops motion
5622 * while intaking but should be ignored when feeding
5623 * to a shooter.
5624 *
5625 * The hardware limit faults and Forward/ReverseLimit
5626 * signals will still report the values of the limit
5627 * switches regardless of this parameter.
5628 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
5629 * allowing motion.
5630 *
5631 * This can be useful when calibrating the zero point
5632 * of a mechanism such as an elevator.
5633 *
5634 * The software limit faults will still report the
5635 * values of the software limits regardless of this
5636 * parameter.
5637 * - UseTimesync: Set to true to delay applying this control request until a
5638 * timesync boundary (requires Phoenix Pro and CANivore). This
5639 * eliminates the impact of nondeterministic network delays in
5640 * exchange for a larger but deterministic control latency.
5641 *
5642 * This requires setting the ControlTimesyncFreqHz config in
5643 * MotorOutputConfigs. Additionally, when this is enabled, the
5644 * UpdateFreqHz of this request should be set to 0 Hz.
5645 *
5646 * \param request Control object to request of the device
5647 * \returns Status Code of the request, 0 is OK
5648 */
5649 ctre::phoenix::StatusCode SetControl(const controls::PositionDutyCycle &request) final;
5650
5651 /**
5652 * \brief Request PID to target position with voltage feedforward
5653 *
5654 * \details This control mode will set the motor's position setpoint
5655 * to the position specified by the user. In addition, it will apply
5656 * an additional voltage as an arbitrary feedforward value.
5657 *
5658 * - PositionVoltage Parameters:
5659 * - Position: Position to drive toward in rotations.
5660 * - Velocity: Velocity to drive toward in rotations per second. This is
5661 * typically used for motion profiles generated by the robot
5662 * program.
5663 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
5664 * which increases peak power by ~15% on supported devices (see
5665 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
5666 * commutation.
5667 *
5668 * FOC improves motor performance by leveraging torque (current)
5669 * control. However, this may be inconvenient for applications
5670 * that require specifying duty cycle or voltage.
5671 * CTR-Electronics has developed a hybrid method that combines
5672 * the performances gains of FOC while still allowing
5673 * applications to provide duty cycle or voltage demand. This
5674 * not to be confused with simple sinusoidal control or phase
5675 * voltage control which lacks the performance gains.
5676 * - FeedForward: Feedforward to apply in volts. This is added to the output
5677 * of the onboard feedforward terms.
5678 * - Slot: Select which gains are applied by selecting the slot. Use the
5679 * configuration api to set the gain values for the selected slot
5680 * before enabling this feature. Slot must be within [0,2].
5681 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
5682 * output is zero (or within deadband). Set to
5683 * false to use the NeutralMode configuration
5684 * setting (default). This flag exists to provide
5685 * the fundamental behavior of this control when
5686 * output is zero, which is to provide 0V to the
5687 * motor.
5688 * - LimitForwardMotion: Set to true to force forward limiting. This allows
5689 * users to use other limit switch sensors connected to
5690 * robot controller. This also allows use of active
5691 * sensors that require external power.
5692 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
5693 * users to use other limit switch sensors connected to
5694 * robot controller. This also allows use of active
5695 * sensors that require external power.
5696 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
5697 * the LimitForwardMotion and LimitReverseMotion
5698 * parameters, instead allowing motion.
5699 *
5700 * This can be useful on mechanisms such as an
5701 * intake/feeder, where a limit switch stops motion
5702 * while intaking but should be ignored when feeding
5703 * to a shooter.
5704 *
5705 * The hardware limit faults and Forward/ReverseLimit
5706 * signals will still report the values of the limit
5707 * switches regardless of this parameter.
5708 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
5709 * allowing motion.
5710 *
5711 * This can be useful when calibrating the zero point
5712 * of a mechanism such as an elevator.
5713 *
5714 * The software limit faults will still report the
5715 * values of the software limits regardless of this
5716 * parameter.
5717 * - UseTimesync: Set to true to delay applying this control request until a
5718 * timesync boundary (requires Phoenix Pro and CANivore). This
5719 * eliminates the impact of nondeterministic network delays in
5720 * exchange for a larger but deterministic control latency.
5721 *
5722 * This requires setting the ControlTimesyncFreqHz config in
5723 * MotorOutputConfigs. Additionally, when this is enabled, the
5724 * UpdateFreqHz of this request should be set to 0 Hz.
5725 *
5726 * \param request Control object to request of the device
5727 * \returns Status Code of the request, 0 is OK
5728 */
5729 ctre::phoenix::StatusCode SetControl(const controls::PositionVoltage &request) final;
5730
5731 /**
5732 * \brief Request PID to target position with torque current
5733 * feedforward.
5734 *
5735 * \details This control mode will set the motor's position setpoint
5736 * to the position specified by the user. In addition, it will apply
5737 * an additional torque current as an arbitrary feedforward value.
5738 *
5739 * - PositionTorqueCurrentFOC Parameters:
5740 * - Position: Position to drive toward in rotations.
5741 * - Velocity: Velocity to drive toward in rotations per second. This is
5742 * typically used for motion profiles generated by the robot
5743 * program.
5744 * - FeedForward: Feedforward to apply in torque current in Amperes. This is
5745 * added to the output of the onboard feedforward terms.
5746 *
5747 * User can use motor's kT to scale Newton-meter to Amperes.
5748 * - Slot: Select which gains are applied by selecting the slot. Use the
5749 * configuration api to set the gain values for the selected slot
5750 * before enabling this feature. Slot must be within [0,2].
5751 * - OverrideCoastDurNeutral: Set to true to coast the rotor when output is
5752 * zero (or within deadband). Set to false to use
5753 * the NeutralMode configuration setting (default).
5754 * This flag exists to provide the fundamental
5755 * behavior of this control when output is zero,
5756 * which is to provide 0A (zero torque).
5757 * - LimitForwardMotion: Set to true to force forward limiting. This allows
5758 * users to use other limit switch sensors connected to
5759 * robot controller. This also allows use of active
5760 * sensors that require external power.
5761 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
5762 * users to use other limit switch sensors connected to
5763 * robot controller. This also allows use of active
5764 * sensors that require external power.
5765 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
5766 * the LimitForwardMotion and LimitReverseMotion
5767 * parameters, instead allowing motion.
5768 *
5769 * This can be useful on mechanisms such as an
5770 * intake/feeder, where a limit switch stops motion
5771 * while intaking but should be ignored when feeding
5772 * to a shooter.
5773 *
5774 * The hardware limit faults and Forward/ReverseLimit
5775 * signals will still report the values of the limit
5776 * switches regardless of this parameter.
5777 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
5778 * allowing motion.
5779 *
5780 * This can be useful when calibrating the zero point
5781 * of a mechanism such as an elevator.
5782 *
5783 * The software limit faults will still report the
5784 * values of the software limits regardless of this
5785 * parameter.
5786 * - UseTimesync: Set to true to delay applying this control request until a
5787 * timesync boundary (requires Phoenix Pro and CANivore). This
5788 * eliminates the impact of nondeterministic network delays in
5789 * exchange for a larger but deterministic control latency.
5790 *
5791 * This requires setting the ControlTimesyncFreqHz config in
5792 * MotorOutputConfigs. Additionally, when this is enabled, the
5793 * UpdateFreqHz of this request should be set to 0 Hz.
5794 *
5795 * \param request Control object to request of the device
5796 * \returns Status Code of the request, 0 is OK
5797 */
5798 ctre::phoenix::StatusCode SetControl(const controls::PositionTorqueCurrentFOC &request) final;
5799
5800 /**
5801 * \brief Request PID to target velocity with duty cycle feedforward.
5802 *
5803 * \details This control mode will set the motor's velocity setpoint
5804 * to the velocity specified by the user. In addition, it will apply
5805 * an additional voltage as an arbitrary feedforward value.
5806 *
5807 * - VelocityDutyCycle Parameters:
5808 * - Velocity: Velocity to drive toward in rotations per second.
5809 * - Acceleration: Acceleration to drive toward in rotations per second
5810 * squared. This is typically used for motion profiles
5811 * generated by the robot program.
5812 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
5813 * which increases peak power by ~15% on supported devices (see
5814 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
5815 * commutation.
5816 *
5817 * FOC improves motor performance by leveraging torque (current)
5818 * control. However, this may be inconvenient for applications
5819 * that require specifying duty cycle or voltage.
5820 * CTR-Electronics has developed a hybrid method that combines
5821 * the performances gains of FOC while still allowing
5822 * applications to provide duty cycle or voltage demand. This
5823 * not to be confused with simple sinusoidal control or phase
5824 * voltage control which lacks the performance gains.
5825 * - FeedForward: Feedforward to apply in fractional units between -1 and +1.
5826 * This is added to the output of the onboard feedforward
5827 * terms.
5828 * - Slot: Select which gains are applied by selecting the slot. Use the
5829 * configuration api to set the gain values for the selected slot
5830 * before enabling this feature. Slot must be within [0,2].
5831 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
5832 * output is zero (or within deadband). Set to
5833 * false to use the NeutralMode configuration
5834 * setting (default). This flag exists to provide
5835 * the fundamental behavior of this control when
5836 * output is zero, which is to provide 0V to the
5837 * motor.
5838 * - LimitForwardMotion: Set to true to force forward limiting. This allows
5839 * users to use other limit switch sensors connected to
5840 * robot controller. This also allows use of active
5841 * sensors that require external power.
5842 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
5843 * users to use other limit switch sensors connected to
5844 * robot controller. This also allows use of active
5845 * sensors that require external power.
5846 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
5847 * the LimitForwardMotion and LimitReverseMotion
5848 * parameters, instead allowing motion.
5849 *
5850 * This can be useful on mechanisms such as an
5851 * intake/feeder, where a limit switch stops motion
5852 * while intaking but should be ignored when feeding
5853 * to a shooter.
5854 *
5855 * The hardware limit faults and Forward/ReverseLimit
5856 * signals will still report the values of the limit
5857 * switches regardless of this parameter.
5858 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
5859 * allowing motion.
5860 *
5861 * This can be useful when calibrating the zero point
5862 * of a mechanism such as an elevator.
5863 *
5864 * The software limit faults will still report the
5865 * values of the software limits regardless of this
5866 * parameter.
5867 * - UseTimesync: Set to true to delay applying this control request until a
5868 * timesync boundary (requires Phoenix Pro and CANivore). This
5869 * eliminates the impact of nondeterministic network delays in
5870 * exchange for a larger but deterministic control latency.
5871 *
5872 * This requires setting the ControlTimesyncFreqHz config in
5873 * MotorOutputConfigs. Additionally, when this is enabled, the
5874 * UpdateFreqHz of this request should be set to 0 Hz.
5875 *
5876 * \param request Control object to request of the device
5877 * \returns Status Code of the request, 0 is OK
5878 */
5879 ctre::phoenix::StatusCode SetControl(const controls::VelocityDutyCycle &request) final;
5880
5881 /**
5882 * \brief Request PID to target velocity with voltage feedforward.
5883 *
5884 * \details This control mode will set the motor's velocity setpoint
5885 * to the velocity specified by the user. In addition, it will apply
5886 * an additional voltage as an arbitrary feedforward value.
5887 *
5888 * - VelocityVoltage Parameters:
5889 * - Velocity: Velocity to drive toward in rotations per second.
5890 * - Acceleration: Acceleration to drive toward in rotations per second
5891 * squared. This is typically used for motion profiles
5892 * generated by the robot program.
5893 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
5894 * which increases peak power by ~15% on supported devices (see
5895 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
5896 * commutation.
5897 *
5898 * FOC improves motor performance by leveraging torque (current)
5899 * control. However, this may be inconvenient for applications
5900 * that require specifying duty cycle or voltage.
5901 * CTR-Electronics has developed a hybrid method that combines
5902 * the performances gains of FOC while still allowing
5903 * applications to provide duty cycle or voltage demand. This
5904 * not to be confused with simple sinusoidal control or phase
5905 * voltage control which lacks the performance gains.
5906 * - FeedForward: Feedforward to apply in volts This is added to the output of
5907 * the onboard feedforward terms.
5908 * - Slot: Select which gains are applied by selecting the slot. Use the
5909 * configuration api to set the gain values for the selected slot
5910 * before enabling this feature. Slot must be within [0,2].
5911 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
5912 * output is zero (or within deadband). Set to
5913 * false to use the NeutralMode configuration
5914 * setting (default). This flag exists to provide
5915 * the fundamental behavior of this control when
5916 * output is zero, which is to provide 0V to the
5917 * motor.
5918 * - LimitForwardMotion: Set to true to force forward limiting. This allows
5919 * users to use other limit switch sensors connected to
5920 * robot controller. This also allows use of active
5921 * sensors that require external power.
5922 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
5923 * users to use other limit switch sensors connected to
5924 * robot controller. This also allows use of active
5925 * sensors that require external power.
5926 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
5927 * the LimitForwardMotion and LimitReverseMotion
5928 * parameters, instead allowing motion.
5929 *
5930 * This can be useful on mechanisms such as an
5931 * intake/feeder, where a limit switch stops motion
5932 * while intaking but should be ignored when feeding
5933 * to a shooter.
5934 *
5935 * The hardware limit faults and Forward/ReverseLimit
5936 * signals will still report the values of the limit
5937 * switches regardless of this parameter.
5938 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
5939 * allowing motion.
5940 *
5941 * This can be useful when calibrating the zero point
5942 * of a mechanism such as an elevator.
5943 *
5944 * The software limit faults will still report the
5945 * values of the software limits regardless of this
5946 * parameter.
5947 * - UseTimesync: Set to true to delay applying this control request until a
5948 * timesync boundary (requires Phoenix Pro and CANivore). This
5949 * eliminates the impact of nondeterministic network delays in
5950 * exchange for a larger but deterministic control latency.
5951 *
5952 * This requires setting the ControlTimesyncFreqHz config in
5953 * MotorOutputConfigs. Additionally, when this is enabled, the
5954 * UpdateFreqHz of this request should be set to 0 Hz.
5955 *
5956 * \param request Control object to request of the device
5957 * \returns Status Code of the request, 0 is OK
5958 */
5959 ctre::phoenix::StatusCode SetControl(const controls::VelocityVoltage &request) final;
5960
5961 /**
5962 * \brief Request PID to target velocity with torque current
5963 * feedforward.
5964 *
5965 * \details This control mode will set the motor's velocity setpoint
5966 * to the velocity specified by the user. In addition, it will apply
5967 * an additional torque current as an arbitrary feedforward value.
5968 *
5969 * - VelocityTorqueCurrentFOC Parameters:
5970 * - Velocity: Velocity to drive toward in rotations per second.
5971 * - Acceleration: Acceleration to drive toward in rotations per second
5972 * squared. This is typically used for motion profiles
5973 * generated by the robot program.
5974 * - FeedForward: Feedforward to apply in torque current in Amperes. This is
5975 * added to the output of the onboard feedforward terms.
5976 *
5977 * User can use motor's kT to scale Newton-meter to Amperes.
5978 * - Slot: Select which gains are applied by selecting the slot. Use the
5979 * configuration api to set the gain values for the selected slot
5980 * before enabling this feature. Slot must be within [0,2].
5981 * - OverrideCoastDurNeutral: Set to true to coast the rotor when output is
5982 * zero (or within deadband). Set to false to use
5983 * the NeutralMode configuration setting (default).
5984 * This flag exists to provide the fundamental
5985 * behavior of this control when output is zero,
5986 * which is to provide 0A (zero torque).
5987 * - LimitForwardMotion: Set to true to force forward limiting. This allows
5988 * users to use other limit switch sensors connected to
5989 * robot controller. This also allows use of active
5990 * sensors that require external power.
5991 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
5992 * users to use other limit switch sensors connected to
5993 * robot controller. This also allows use of active
5994 * sensors that require external power.
5995 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
5996 * the LimitForwardMotion and LimitReverseMotion
5997 * parameters, instead allowing motion.
5998 *
5999 * This can be useful on mechanisms such as an
6000 * intake/feeder, where a limit switch stops motion
6001 * while intaking but should be ignored when feeding
6002 * to a shooter.
6003 *
6004 * The hardware limit faults and Forward/ReverseLimit
6005 * signals will still report the values of the limit
6006 * switches regardless of this parameter.
6007 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6008 * allowing motion.
6009 *
6010 * This can be useful when calibrating the zero point
6011 * of a mechanism such as an elevator.
6012 *
6013 * The software limit faults will still report the
6014 * values of the software limits regardless of this
6015 * parameter.
6016 * - UseTimesync: Set to true to delay applying this control request until a
6017 * timesync boundary (requires Phoenix Pro and CANivore). This
6018 * eliminates the impact of nondeterministic network delays in
6019 * exchange for a larger but deterministic control latency.
6020 *
6021 * This requires setting the ControlTimesyncFreqHz config in
6022 * MotorOutputConfigs. Additionally, when this is enabled, the
6023 * UpdateFreqHz of this request should be set to 0 Hz.
6024 *
6025 * \param request Control object to request of the device
6026 * \returns Status Code of the request, 0 is OK
6027 */
6028 ctre::phoenix::StatusCode SetControl(const controls::VelocityTorqueCurrentFOC &request) final;
6029
6030 /**
6031 * \brief Requests Motion Magic® to target a final position using a
6032 * motion profile. Users can optionally provide a duty cycle
6033 * feedforward.
6034 *
6035 * \details Motion Magic® produces a motion profile in real-time while
6036 * attempting to honor the Cruise Velocity, Acceleration, and
6037 * (optional) Jerk specified via the Motion Magic® configuration
6038 * values. This control mode does not use the Expo_kV or Expo_kA
6039 * configs.
6040 *
6041 * Target position can be changed on-the-fly and Motion Magic® will do
6042 * its best to adjust the profile. This control mode is duty cycle
6043 * based, so relevant closed-loop gains will use fractional duty cycle
6044 * for the numerator: +1.0 represents full forward output.
6045 *
6046 * - MotionMagicDutyCycle Parameters:
6047 * - Position: Position to drive toward in rotations.
6048 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
6049 * which increases peak power by ~15% on supported devices (see
6050 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
6051 * commutation.
6052 *
6053 * FOC improves motor performance by leveraging torque (current)
6054 * control. However, this may be inconvenient for applications
6055 * that require specifying duty cycle or voltage.
6056 * CTR-Electronics has developed a hybrid method that combines
6057 * the performances gains of FOC while still allowing
6058 * applications to provide duty cycle or voltage demand. This
6059 * not to be confused with simple sinusoidal control or phase
6060 * voltage control which lacks the performance gains.
6061 * - FeedForward: Feedforward to apply in fractional units between -1 and +1.
6062 * This is added to the output of the onboard feedforward
6063 * terms.
6064 * - Slot: Select which gains are applied by selecting the slot. Use the
6065 * configuration api to set the gain values for the selected slot
6066 * before enabling this feature. Slot must be within [0,2].
6067 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
6068 * output is zero (or within deadband). Set to
6069 * false to use the NeutralMode configuration
6070 * setting (default). This flag exists to provide
6071 * the fundamental behavior of this control when
6072 * output is zero, which is to provide 0V to the
6073 * motor.
6074 * - LimitForwardMotion: Set to true to force forward limiting. This allows
6075 * users to use other limit switch sensors connected to
6076 * robot controller. This also allows use of active
6077 * sensors that require external power.
6078 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
6079 * users to use other limit switch sensors connected to
6080 * robot controller. This also allows use of active
6081 * sensors that require external power.
6082 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
6083 * the LimitForwardMotion and LimitReverseMotion
6084 * parameters, instead allowing motion.
6085 *
6086 * This can be useful on mechanisms such as an
6087 * intake/feeder, where a limit switch stops motion
6088 * while intaking but should be ignored when feeding
6089 * to a shooter.
6090 *
6091 * The hardware limit faults and Forward/ReverseLimit
6092 * signals will still report the values of the limit
6093 * switches regardless of this parameter.
6094 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6095 * allowing motion.
6096 *
6097 * This can be useful when calibrating the zero point
6098 * of a mechanism such as an elevator.
6099 *
6100 * The software limit faults will still report the
6101 * values of the software limits regardless of this
6102 * parameter.
6103 * - UseTimesync: Set to true to delay applying this control request until a
6104 * timesync boundary (requires Phoenix Pro and CANivore). This
6105 * eliminates the impact of nondeterministic network delays in
6106 * exchange for a larger but deterministic control latency.
6107 *
6108 * This requires setting the ControlTimesyncFreqHz config in
6109 * MotorOutputConfigs. Additionally, when this is enabled, the
6110 * UpdateFreqHz of this request should be set to 0 Hz.
6111 *
6112 * \param request Control object to request of the device
6113 * \returns Status Code of the request, 0 is OK
6114 */
6115 ctre::phoenix::StatusCode SetControl(const controls::MotionMagicDutyCycle &request) final;
6116
6117 /**
6118 * \brief Requests Motion Magic® to target a final position using a
6119 * motion profile. Users can optionally provide a voltage
6120 * feedforward.
6121 *
6122 * \details Motion Magic® produces a motion profile in real-time while
6123 * attempting to honor the Cruise Velocity, Acceleration, and
6124 * (optional) Jerk specified via the Motion Magic® configuration
6125 * values. This control mode does not use the Expo_kV or Expo_kA
6126 * configs.
6127 *
6128 * Target position can be changed on-the-fly and Motion Magic® will do
6129 * its best to adjust the profile. This control mode is
6130 * voltage-based, so relevant closed-loop gains will use Volts for the
6131 * numerator.
6132 *
6133 * - MotionMagicVoltage Parameters:
6134 * - Position: Position to drive toward in rotations.
6135 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
6136 * which increases peak power by ~15% on supported devices (see
6137 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
6138 * commutation.
6139 *
6140 * FOC improves motor performance by leveraging torque (current)
6141 * control. However, this may be inconvenient for applications
6142 * that require specifying duty cycle or voltage.
6143 * CTR-Electronics has developed a hybrid method that combines
6144 * the performances gains of FOC while still allowing
6145 * applications to provide duty cycle or voltage demand. This
6146 * not to be confused with simple sinusoidal control or phase
6147 * voltage control which lacks the performance gains.
6148 * - FeedForward: Feedforward to apply in volts. This is added to the output
6149 * of the onboard feedforward terms.
6150 * - Slot: Select which gains are applied by selecting the slot. Use the
6151 * configuration api to set the gain values for the selected slot
6152 * before enabling this feature. Slot must be within [0,2].
6153 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
6154 * output is zero (or within deadband). Set to
6155 * false to use the NeutralMode configuration
6156 * setting (default). This flag exists to provide
6157 * the fundamental behavior of this control when
6158 * output is zero, which is to provide 0V to the
6159 * motor.
6160 * - LimitForwardMotion: Set to true to force forward limiting. This allows
6161 * users to use other limit switch sensors connected to
6162 * robot controller. This also allows use of active
6163 * sensors that require external power.
6164 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
6165 * users to use other limit switch sensors connected to
6166 * robot controller. This also allows use of active
6167 * sensors that require external power.
6168 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
6169 * the LimitForwardMotion and LimitReverseMotion
6170 * parameters, instead allowing motion.
6171 *
6172 * This can be useful on mechanisms such as an
6173 * intake/feeder, where a limit switch stops motion
6174 * while intaking but should be ignored when feeding
6175 * to a shooter.
6176 *
6177 * The hardware limit faults and Forward/ReverseLimit
6178 * signals will still report the values of the limit
6179 * switches regardless of this parameter.
6180 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6181 * allowing motion.
6182 *
6183 * This can be useful when calibrating the zero point
6184 * of a mechanism such as an elevator.
6185 *
6186 * The software limit faults will still report the
6187 * values of the software limits regardless of this
6188 * parameter.
6189 * - UseTimesync: Set to true to delay applying this control request until a
6190 * timesync boundary (requires Phoenix Pro and CANivore). This
6191 * eliminates the impact of nondeterministic network delays in
6192 * exchange for a larger but deterministic control latency.
6193 *
6194 * This requires setting the ControlTimesyncFreqHz config in
6195 * MotorOutputConfigs. Additionally, when this is enabled, the
6196 * UpdateFreqHz of this request should be set to 0 Hz.
6197 *
6198 * \param request Control object to request of the device
6199 * \returns Status Code of the request, 0 is OK
6200 */
6201 ctre::phoenix::StatusCode SetControl(const controls::MotionMagicVoltage &request) final;
6202
6203 /**
6204 * \brief Requests Motion Magic® to target a final position using a
6205 * motion profile. Users can optionally provide a torque current
6206 * feedforward.
6207 *
6208 * \details Motion Magic® produces a motion profile in real-time while
6209 * attempting to honor the Cruise Velocity, Acceleration, and
6210 * (optional) Jerk specified via the Motion Magic® configuration
6211 * values. This control mode does not use the Expo_kV or Expo_kA
6212 * configs.
6213 *
6214 * Target position can be changed on-the-fly and Motion Magic® will do
6215 * its best to adjust the profile. This control mode is based on
6216 * torque current, so relevant closed-loop gains will use Amperes for
6217 * the numerator.
6218 *
6219 * - MotionMagicTorqueCurrentFOC Parameters:
6220 * - Position: Position to drive toward in rotations.
6221 * - FeedForward: Feedforward to apply in torque current in Amperes. This is
6222 * added to the output of the onboard feedforward terms.
6223 *
6224 * User can use motor's kT to scale Newton-meter to Amperes.
6225 * - Slot: Select which gains are applied by selecting the slot. Use the
6226 * configuration api to set the gain values for the selected slot
6227 * before enabling this feature. Slot must be within [0,2].
6228 * - OverrideCoastDurNeutral: Set to true to coast the rotor when output is
6229 * zero (or within deadband). Set to false to use
6230 * the NeutralMode configuration setting (default).
6231 * This flag exists to provide the fundamental
6232 * behavior of this control when output is zero,
6233 * which is to provide 0A (zero torque).
6234 * - LimitForwardMotion: Set to true to force forward limiting. This allows
6235 * users to use other limit switch sensors connected to
6236 * robot controller. This also allows use of active
6237 * sensors that require external power.
6238 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
6239 * users to use other limit switch sensors connected to
6240 * robot controller. This also allows use of active
6241 * sensors that require external power.
6242 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
6243 * the LimitForwardMotion and LimitReverseMotion
6244 * parameters, instead allowing motion.
6245 *
6246 * This can be useful on mechanisms such as an
6247 * intake/feeder, where a limit switch stops motion
6248 * while intaking but should be ignored when feeding
6249 * to a shooter.
6250 *
6251 * The hardware limit faults and Forward/ReverseLimit
6252 * signals will still report the values of the limit
6253 * switches regardless of this parameter.
6254 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6255 * allowing motion.
6256 *
6257 * This can be useful when calibrating the zero point
6258 * of a mechanism such as an elevator.
6259 *
6260 * The software limit faults will still report the
6261 * values of the software limits regardless of this
6262 * parameter.
6263 * - UseTimesync: Set to true to delay applying this control request until a
6264 * timesync boundary (requires Phoenix Pro and CANivore). This
6265 * eliminates the impact of nondeterministic network delays in
6266 * exchange for a larger but deterministic control latency.
6267 *
6268 * This requires setting the ControlTimesyncFreqHz config in
6269 * MotorOutputConfigs. Additionally, when this is enabled, the
6270 * UpdateFreqHz of this request should be set to 0 Hz.
6271 *
6272 * \param request Control object to request of the device
6273 * \returns Status Code of the request, 0 is OK
6274 */
6275 ctre::phoenix::StatusCode SetControl(const controls::MotionMagicTorqueCurrentFOC &request) final;
6276
6277 /**
6278 * \brief Request a specified motor duty cycle with a differential
6279 * position closed-loop.
6280 *
6281 * \details This control mode will output a proportion of the supplied
6282 * voltage which is supplied by the user. It will also set the motor's
6283 * differential position setpoint to the specified position.
6284 *
6285 * - DifferentialDutyCycle Parameters:
6286 * - AverageOutput: Proportion of supply voltage to apply on the Average axis
6287 * in fractional units between -1 and +1.
6288 * - DifferentialPosition: Differential position to drive towards in
6289 * rotations.
6290 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
6291 * which increases peak power by ~15% on supported devices (see
6292 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
6293 * commutation.
6294 *
6295 * FOC improves motor performance by leveraging torque (current)
6296 * control. However, this may be inconvenient for applications
6297 * that require specifying duty cycle or voltage.
6298 * CTR-Electronics has developed a hybrid method that combines
6299 * the performances gains of FOC while still allowing
6300 * applications to provide duty cycle or voltage demand. This
6301 * not to be confused with simple sinusoidal control or phase
6302 * voltage control which lacks the performance gains.
6303 * - DifferentialSlot: Select which gains are applied to the differential
6304 * controller by selecting the slot. Use the
6305 * configuration api to set the gain values for the
6306 * selected slot before enabling this feature. Slot must
6307 * be within [0,2].
6308 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
6309 * output is zero (or within deadband). Set to
6310 * false to use the NeutralMode configuration
6311 * setting (default). This flag exists to provide
6312 * the fundamental behavior of this control when
6313 * output is zero, which is to provide 0V to the
6314 * motor.
6315 * - LimitForwardMotion: Set to true to force forward limiting. This allows
6316 * users to use other limit switch sensors connected to
6317 * robot controller. This also allows use of active
6318 * sensors that require external power.
6319 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
6320 * users to use other limit switch sensors connected to
6321 * robot controller. This also allows use of active
6322 * sensors that require external power.
6323 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
6324 * the LimitForwardMotion and LimitReverseMotion
6325 * parameters, instead allowing motion.
6326 *
6327 * This can be useful on mechanisms such as an
6328 * intake/feeder, where a limit switch stops motion
6329 * while intaking but should be ignored when feeding
6330 * to a shooter.
6331 *
6332 * The hardware limit faults and Forward/ReverseLimit
6333 * signals will still report the values of the limit
6334 * switches regardless of this parameter.
6335 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6336 * allowing motion.
6337 *
6338 * This can be useful when calibrating the zero point
6339 * of a mechanism such as an elevator.
6340 *
6341 * The software limit faults will still report the
6342 * values of the software limits regardless of this
6343 * parameter.
6344 * - UseTimesync: Set to true to delay applying this control request until a
6345 * timesync boundary (requires Phoenix Pro and CANivore). This
6346 * eliminates the impact of nondeterministic network delays in
6347 * exchange for a larger but deterministic control latency.
6348 *
6349 * This requires setting the ControlTimesyncFreqHz config in
6350 * MotorOutputConfigs. Additionally, when this is enabled, the
6351 * UpdateFreqHz of this request should be set to 0 Hz.
6352 *
6353 * \param request Control object to request of the device
6354 * \returns Status Code of the request, 0 is OK
6355 */
6356 ctre::phoenix::StatusCode SetControl(const controls::DifferentialDutyCycle &request) final;
6357
6358 /**
6359 * \brief Request a specified voltage with a differential position
6360 * closed-loop.
6361 *
6362 * \details This control mode will attempt to apply the specified
6363 * voltage to the motor. If the supply voltage is below the requested
6364 * voltage, the motor controller will output the supply voltage. It
6365 * will also set the motor's differential position setpoint to the
6366 * specified position.
6367 *
6368 * - DifferentialVoltage Parameters:
6369 * - AverageOutput: Voltage to attempt to drive at on the Average axis.
6370 * - DifferentialPosition: Differential position to drive towards in
6371 * rotations.
6372 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
6373 * which increases peak power by ~15% on supported devices (see
6374 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
6375 * commutation.
6376 *
6377 * FOC improves motor performance by leveraging torque (current)
6378 * control. However, this may be inconvenient for applications
6379 * that require specifying duty cycle or voltage.
6380 * CTR-Electronics has developed a hybrid method that combines
6381 * the performances gains of FOC while still allowing
6382 * applications to provide duty cycle or voltage demand. This
6383 * not to be confused with simple sinusoidal control or phase
6384 * voltage control which lacks the performance gains.
6385 * - DifferentialSlot: Select which gains are applied to the differential
6386 * controller by selecting the slot. Use the
6387 * configuration api to set the gain values for the
6388 * selected slot before enabling this feature. Slot must
6389 * be within [0,2].
6390 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
6391 * output is zero (or within deadband). Set to
6392 * false to use the NeutralMode configuration
6393 * setting (default). This flag exists to provide
6394 * the fundamental behavior of this control when
6395 * output is zero, which is to provide 0V to the
6396 * motor.
6397 * - LimitForwardMotion: Set to true to force forward limiting. This allows
6398 * users to use other limit switch sensors connected to
6399 * robot controller. This also allows use of active
6400 * sensors that require external power.
6401 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
6402 * users to use other limit switch sensors connected to
6403 * robot controller. This also allows use of active
6404 * sensors that require external power.
6405 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
6406 * the LimitForwardMotion and LimitReverseMotion
6407 * parameters, instead allowing motion.
6408 *
6409 * This can be useful on mechanisms such as an
6410 * intake/feeder, where a limit switch stops motion
6411 * while intaking but should be ignored when feeding
6412 * to a shooter.
6413 *
6414 * The hardware limit faults and Forward/ReverseLimit
6415 * signals will still report the values of the limit
6416 * switches regardless of this parameter.
6417 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6418 * allowing motion.
6419 *
6420 * This can be useful when calibrating the zero point
6421 * of a mechanism such as an elevator.
6422 *
6423 * The software limit faults will still report the
6424 * values of the software limits regardless of this
6425 * parameter.
6426 * - UseTimesync: Set to true to delay applying this control request until a
6427 * timesync boundary (requires Phoenix Pro and CANivore). This
6428 * eliminates the impact of nondeterministic network delays in
6429 * exchange for a larger but deterministic control latency.
6430 *
6431 * This requires setting the ControlTimesyncFreqHz config in
6432 * MotorOutputConfigs. Additionally, when this is enabled, the
6433 * UpdateFreqHz of this request should be set to 0 Hz.
6434 *
6435 * \param request Control object to request of the device
6436 * \returns Status Code of the request, 0 is OK
6437 */
6438 ctre::phoenix::StatusCode SetControl(const controls::DifferentialVoltage &request) final;
6439
6440 /**
6441 * \brief Request PID to target position with a differential position
6442 * setpoint.
6443 *
6444 * \details This control mode will set the motor's position setpoint
6445 * to the position specified by the user. It will also set the motor's
6446 * differential position setpoint to the specified position.
6447 *
6448 * - DifferentialPositionDutyCycle Parameters:
6449 * - AveragePosition: Average position to drive toward in rotations.
6450 * - DifferentialPosition: Differential position to drive toward in rotations.
6451 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
6452 * which increases peak power by ~15% on supported devices (see
6453 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
6454 * commutation.
6455 *
6456 * FOC improves motor performance by leveraging torque (current)
6457 * control. However, this may be inconvenient for applications
6458 * that require specifying duty cycle or voltage.
6459 * CTR-Electronics has developed a hybrid method that combines
6460 * the performances gains of FOC while still allowing
6461 * applications to provide duty cycle or voltage demand. This
6462 * not to be confused with simple sinusoidal control or phase
6463 * voltage control which lacks the performance gains.
6464 * - AverageSlot: Select which gains are applied to the average controller by
6465 * selecting the slot. Use the configuration api to set the
6466 * gain values for the selected slot before enabling this
6467 * feature. Slot must be within [0,2].
6468 * - DifferentialSlot: Select which gains are applied to the differential
6469 * controller by selecting the slot. Use the
6470 * configuration api to set the gain values for the
6471 * selected slot before enabling this feature. Slot must
6472 * be within [0,2].
6473 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
6474 * output is zero (or within deadband). Set to
6475 * false to use the NeutralMode configuration
6476 * setting (default). This flag exists to provide
6477 * the fundamental behavior of this control when
6478 * output is zero, which is to provide 0V to the
6479 * motor.
6480 * - LimitForwardMotion: Set to true to force forward limiting. This allows
6481 * users to use other limit switch sensors connected to
6482 * robot controller. This also allows use of active
6483 * sensors that require external power.
6484 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
6485 * users to use other limit switch sensors connected to
6486 * robot controller. This also allows use of active
6487 * sensors that require external power.
6488 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
6489 * the LimitForwardMotion and LimitReverseMotion
6490 * parameters, instead allowing motion.
6491 *
6492 * This can be useful on mechanisms such as an
6493 * intake/feeder, where a limit switch stops motion
6494 * while intaking but should be ignored when feeding
6495 * to a shooter.
6496 *
6497 * The hardware limit faults and Forward/ReverseLimit
6498 * signals will still report the values of the limit
6499 * switches regardless of this parameter.
6500 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6501 * allowing motion.
6502 *
6503 * This can be useful when calibrating the zero point
6504 * of a mechanism such as an elevator.
6505 *
6506 * The software limit faults will still report the
6507 * values of the software limits regardless of this
6508 * parameter.
6509 * - UseTimesync: Set to true to delay applying this control request until a
6510 * timesync boundary (requires Phoenix Pro and CANivore). This
6511 * eliminates the impact of nondeterministic network delays in
6512 * exchange for a larger but deterministic control latency.
6513 *
6514 * This requires setting the ControlTimesyncFreqHz config in
6515 * MotorOutputConfigs. Additionally, when this is enabled, the
6516 * UpdateFreqHz of this request should be set to 0 Hz.
6517 *
6518 * \param request Control object to request of the device
6519 * \returns Status Code of the request, 0 is OK
6520 */
6521 ctre::phoenix::StatusCode SetControl(const controls::DifferentialPositionDutyCycle &request) final;
6522
6523 /**
6524 * \brief Request PID to target position with a differential position
6525 * setpoint
6526 *
6527 * \details This control mode will set the motor's position setpoint
6528 * to the position specified by the user. It will also set the motor's
6529 * differential position setpoint to the specified position.
6530 *
6531 * - DifferentialPositionVoltage Parameters:
6532 * - AveragePosition: Average position to drive toward in rotations.
6533 * - DifferentialPosition: Differential position to drive toward in rotations.
6534 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
6535 * which increases peak power by ~15% on supported devices (see
6536 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
6537 * commutation.
6538 *
6539 * FOC improves motor performance by leveraging torque (current)
6540 * control. However, this may be inconvenient for applications
6541 * that require specifying duty cycle or voltage.
6542 * CTR-Electronics has developed a hybrid method that combines
6543 * the performances gains of FOC while still allowing
6544 * applications to provide duty cycle or voltage demand. This
6545 * not to be confused with simple sinusoidal control or phase
6546 * voltage control which lacks the performance gains.
6547 * - AverageSlot: Select which gains are applied to the average controller by
6548 * selecting the slot. Use the configuration api to set the
6549 * gain values for the selected slot before enabling this
6550 * feature. Slot must be within [0,2].
6551 * - DifferentialSlot: Select which gains are applied to the differential
6552 * controller by selecting the slot. Use the
6553 * configuration api to set the gain values for the
6554 * selected slot before enabling this feature. Slot must
6555 * be within [0,2].
6556 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
6557 * output is zero (or within deadband). Set to
6558 * false to use the NeutralMode configuration
6559 * setting (default). This flag exists to provide
6560 * the fundamental behavior of this control when
6561 * output is zero, which is to provide 0V to the
6562 * motor.
6563 * - LimitForwardMotion: Set to true to force forward limiting. This allows
6564 * users to use other limit switch sensors connected to
6565 * robot controller. This also allows use of active
6566 * sensors that require external power.
6567 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
6568 * users to use other limit switch sensors connected to
6569 * robot controller. This also allows use of active
6570 * sensors that require external power.
6571 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
6572 * the LimitForwardMotion and LimitReverseMotion
6573 * parameters, instead allowing motion.
6574 *
6575 * This can be useful on mechanisms such as an
6576 * intake/feeder, where a limit switch stops motion
6577 * while intaking but should be ignored when feeding
6578 * to a shooter.
6579 *
6580 * The hardware limit faults and Forward/ReverseLimit
6581 * signals will still report the values of the limit
6582 * switches regardless of this parameter.
6583 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6584 * allowing motion.
6585 *
6586 * This can be useful when calibrating the zero point
6587 * of a mechanism such as an elevator.
6588 *
6589 * The software limit faults will still report the
6590 * values of the software limits regardless of this
6591 * parameter.
6592 * - UseTimesync: Set to true to delay applying this control request until a
6593 * timesync boundary (requires Phoenix Pro and CANivore). This
6594 * eliminates the impact of nondeterministic network delays in
6595 * exchange for a larger but deterministic control latency.
6596 *
6597 * This requires setting the ControlTimesyncFreqHz config in
6598 * MotorOutputConfigs. Additionally, when this is enabled, the
6599 * UpdateFreqHz of this request should be set to 0 Hz.
6600 *
6601 * \param request Control object to request of the device
6602 * \returns Status Code of the request, 0 is OK
6603 */
6604 ctre::phoenix::StatusCode SetControl(const controls::DifferentialPositionVoltage &request) final;
6605
6606 /**
6607 * \brief Request PID to target velocity with a differential position
6608 * setpoint.
6609 *
6610 * \details This control mode will set the motor's velocity setpoint
6611 * to the velocity specified by the user. It will also set the motor's
6612 * differential position setpoint to the specified position.
6613 *
6614 * - DifferentialVelocityDutyCycle Parameters:
6615 * - AverageVelocity: Average velocity to drive toward in rotations per
6616 * second.
6617 * - DifferentialPosition: Differential position to drive toward in rotations.
6618 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
6619 * which increases peak power by ~15% on supported devices (see
6620 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
6621 * commutation.
6622 *
6623 * FOC improves motor performance by leveraging torque (current)
6624 * control. However, this may be inconvenient for applications
6625 * that require specifying duty cycle or voltage.
6626 * CTR-Electronics has developed a hybrid method that combines
6627 * the performances gains of FOC while still allowing
6628 * applications to provide duty cycle or voltage demand. This
6629 * not to be confused with simple sinusoidal control or phase
6630 * voltage control which lacks the performance gains.
6631 * - AverageSlot: Select which gains are applied to the average controller by
6632 * selecting the slot. Use the configuration api to set the
6633 * gain values for the selected slot before enabling this
6634 * feature. Slot must be within [0,2].
6635 * - DifferentialSlot: Select which gains are applied to the differential
6636 * controller by selecting the slot. Use the
6637 * configuration api to set the gain values for the
6638 * selected slot before enabling this feature. Slot must
6639 * be within [0,2].
6640 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
6641 * output is zero (or within deadband). Set to
6642 * false to use the NeutralMode configuration
6643 * setting (default). This flag exists to provide
6644 * the fundamental behavior of this control when
6645 * output is zero, which is to provide 0V to the
6646 * motor.
6647 * - LimitForwardMotion: Set to true to force forward limiting. This allows
6648 * users to use other limit switch sensors connected to
6649 * robot controller. This also allows use of active
6650 * sensors that require external power.
6651 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
6652 * users to use other limit switch sensors connected to
6653 * robot controller. This also allows use of active
6654 * sensors that require external power.
6655 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
6656 * the LimitForwardMotion and LimitReverseMotion
6657 * parameters, instead allowing motion.
6658 *
6659 * This can be useful on mechanisms such as an
6660 * intake/feeder, where a limit switch stops motion
6661 * while intaking but should be ignored when feeding
6662 * to a shooter.
6663 *
6664 * The hardware limit faults and Forward/ReverseLimit
6665 * signals will still report the values of the limit
6666 * switches regardless of this parameter.
6667 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6668 * allowing motion.
6669 *
6670 * This can be useful when calibrating the zero point
6671 * of a mechanism such as an elevator.
6672 *
6673 * The software limit faults will still report the
6674 * values of the software limits regardless of this
6675 * parameter.
6676 * - UseTimesync: Set to true to delay applying this control request until a
6677 * timesync boundary (requires Phoenix Pro and CANivore). This
6678 * eliminates the impact of nondeterministic network delays in
6679 * exchange for a larger but deterministic control latency.
6680 *
6681 * This requires setting the ControlTimesyncFreqHz config in
6682 * MotorOutputConfigs. Additionally, when this is enabled, the
6683 * UpdateFreqHz of this request should be set to 0 Hz.
6684 *
6685 * \param request Control object to request of the device
6686 * \returns Status Code of the request, 0 is OK
6687 */
6688 ctre::phoenix::StatusCode SetControl(const controls::DifferentialVelocityDutyCycle &request) final;
6689
6690 /**
6691 * \brief Request PID to target velocity with a differential position
6692 * setpoint.
6693 *
6694 * \details This control mode will set the motor's velocity setpoint
6695 * to the velocity specified by the user. It will also set the motor's
6696 * differential position setpoint to the specified position.
6697 *
6698 * - DifferentialVelocityVoltage Parameters:
6699 * - AverageVelocity: Average velocity to drive toward in rotations per
6700 * second.
6701 * - DifferentialPosition: Differential position to drive toward in rotations.
6702 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
6703 * which increases peak power by ~15% on supported devices (see
6704 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
6705 * commutation.
6706 *
6707 * FOC improves motor performance by leveraging torque (current)
6708 * control. However, this may be inconvenient for applications
6709 * that require specifying duty cycle or voltage.
6710 * CTR-Electronics has developed a hybrid method that combines
6711 * the performances gains of FOC while still allowing
6712 * applications to provide duty cycle or voltage demand. This
6713 * not to be confused with simple sinusoidal control or phase
6714 * voltage control which lacks the performance gains.
6715 * - AverageSlot: Select which gains are applied to the average controller by
6716 * selecting the slot. Use the configuration api to set the
6717 * gain values for the selected slot before enabling this
6718 * feature. Slot must be within [0,2].
6719 * - DifferentialSlot: Select which gains are applied to the differential
6720 * controller by selecting the slot. Use the
6721 * configuration api to set the gain values for the
6722 * selected slot before enabling this feature. Slot must
6723 * be within [0,2].
6724 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
6725 * output is zero (or within deadband). Set to
6726 * false to use the NeutralMode configuration
6727 * setting (default). This flag exists to provide
6728 * the fundamental behavior of this control when
6729 * output is zero, which is to provide 0V to the
6730 * motor.
6731 * - LimitForwardMotion: Set to true to force forward limiting. This allows
6732 * users to use other limit switch sensors connected to
6733 * robot controller. This also allows use of active
6734 * sensors that require external power.
6735 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
6736 * users to use other limit switch sensors connected to
6737 * robot controller. This also allows use of active
6738 * sensors that require external power.
6739 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
6740 * the LimitForwardMotion and LimitReverseMotion
6741 * parameters, instead allowing motion.
6742 *
6743 * This can be useful on mechanisms such as an
6744 * intake/feeder, where a limit switch stops motion
6745 * while intaking but should be ignored when feeding
6746 * to a shooter.
6747 *
6748 * The hardware limit faults and Forward/ReverseLimit
6749 * signals will still report the values of the limit
6750 * switches regardless of this parameter.
6751 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6752 * allowing motion.
6753 *
6754 * This can be useful when calibrating the zero point
6755 * of a mechanism such as an elevator.
6756 *
6757 * The software limit faults will still report the
6758 * values of the software limits regardless of this
6759 * parameter.
6760 * - UseTimesync: Set to true to delay applying this control request until a
6761 * timesync boundary (requires Phoenix Pro and CANivore). This
6762 * eliminates the impact of nondeterministic network delays in
6763 * exchange for a larger but deterministic control latency.
6764 *
6765 * This requires setting the ControlTimesyncFreqHz config in
6766 * MotorOutputConfigs. Additionally, when this is enabled, the
6767 * UpdateFreqHz of this request should be set to 0 Hz.
6768 *
6769 * \param request Control object to request of the device
6770 * \returns Status Code of the request, 0 is OK
6771 */
6772 ctre::phoenix::StatusCode SetControl(const controls::DifferentialVelocityVoltage &request) final;
6773
6774 /**
6775 * \brief Requests Motion Magic® to target a final position using a
6776 * motion profile, and PID to a differential position setpoint.
6777 *
6778 * \details Motion Magic® produces a motion profile in real-time while
6779 * attempting to honor the Cruise Velocity, Acceleration, and
6780 * (optional) Jerk specified via the Motion Magic® configuration
6781 * values. This control mode does not use the Expo_kV or Expo_kA
6782 * configs.
6783 *
6784 * Target position can be changed on-the-fly and Motion Magic® will do
6785 * its best to adjust the profile. This control mode is duty cycle
6786 * based, so relevant closed-loop gains will use fractional duty cycle
6787 * for the numerator: +1.0 represents full forward output.
6788 *
6789 * - DifferentialMotionMagicDutyCycle Parameters:
6790 * - AveragePosition: Average position to drive toward in rotations.
6791 * - DifferentialPosition: Differential position to drive toward in rotations.
6792 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
6793 * which increases peak power by ~15% on supported devices (see
6794 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
6795 * commutation.
6796 *
6797 * FOC improves motor performance by leveraging torque (current)
6798 * control. However, this may be inconvenient for applications
6799 * that require specifying duty cycle or voltage.
6800 * CTR-Electronics has developed a hybrid method that combines
6801 * the performances gains of FOC while still allowing
6802 * applications to provide duty cycle or voltage demand. This
6803 * not to be confused with simple sinusoidal control or phase
6804 * voltage control which lacks the performance gains.
6805 * - AverageSlot: Select which gains are applied to the average controller by
6806 * selecting the slot. Use the configuration api to set the
6807 * gain values for the selected slot before enabling this
6808 * feature. Slot must be within [0,2].
6809 * - DifferentialSlot: Select which gains are applied to the differential
6810 * controller by selecting the slot. Use the
6811 * configuration api to set the gain values for the
6812 * selected slot before enabling this feature. Slot must
6813 * be within [0,2].
6814 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
6815 * output is zero (or within deadband). Set to
6816 * false to use the NeutralMode configuration
6817 * setting (default). This flag exists to provide
6818 * the fundamental behavior of this control when
6819 * output is zero, which is to provide 0V to the
6820 * motor.
6821 * - LimitForwardMotion: Set to true to force forward limiting. This allows
6822 * users to use other limit switch sensors connected to
6823 * robot controller. This also allows use of active
6824 * sensors that require external power.
6825 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
6826 * users to use other limit switch sensors connected to
6827 * robot controller. This also allows use of active
6828 * sensors that require external power.
6829 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
6830 * the LimitForwardMotion and LimitReverseMotion
6831 * parameters, instead allowing motion.
6832 *
6833 * This can be useful on mechanisms such as an
6834 * intake/feeder, where a limit switch stops motion
6835 * while intaking but should be ignored when feeding
6836 * to a shooter.
6837 *
6838 * The hardware limit faults and Forward/ReverseLimit
6839 * signals will still report the values of the limit
6840 * switches regardless of this parameter.
6841 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6842 * allowing motion.
6843 *
6844 * This can be useful when calibrating the zero point
6845 * of a mechanism such as an elevator.
6846 *
6847 * The software limit faults will still report the
6848 * values of the software limits regardless of this
6849 * parameter.
6850 * - UseTimesync: Set to true to delay applying this control request until a
6851 * timesync boundary (requires Phoenix Pro and CANivore). This
6852 * eliminates the impact of nondeterministic network delays in
6853 * exchange for a larger but deterministic control latency.
6854 *
6855 * This requires setting the ControlTimesyncFreqHz config in
6856 * MotorOutputConfigs. Additionally, when this is enabled, the
6857 * UpdateFreqHz of this request should be set to 0 Hz.
6858 *
6859 * \param request Control object to request of the device
6860 * \returns Status Code of the request, 0 is OK
6861 */
6862 ctre::phoenix::StatusCode SetControl(const controls::DifferentialMotionMagicDutyCycle &request) final;
6863
6864 /**
6865 * \brief Requests Motion Magic® to target a final position using a
6866 * motion profile, and PID to a differential position setpoint.
6867 *
6868 * \details Motion Magic® produces a motion profile in real-time while
6869 * attempting to honor the Cruise Velocity, Acceleration, and
6870 * (optional) Jerk specified via the Motion Magic® configuration
6871 * values. This control mode does not use the Expo_kV or Expo_kA
6872 * configs.
6873 *
6874 * Target position can be changed on-the-fly and Motion Magic® will do
6875 * its best to adjust the profile. This control mode is
6876 * voltage-based, so relevant closed-loop gains will use Volts for the
6877 * numerator.
6878 *
6879 * - DifferentialMotionMagicVoltage Parameters:
6880 * - AveragePosition: Average position to drive toward in rotations.
6881 * - DifferentialPosition: Differential position to drive toward in rotations.
6882 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
6883 * which increases peak power by ~15% on supported devices (see
6884 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
6885 * commutation.
6886 *
6887 * FOC improves motor performance by leveraging torque (current)
6888 * control. However, this may be inconvenient for applications
6889 * that require specifying duty cycle or voltage.
6890 * CTR-Electronics has developed a hybrid method that combines
6891 * the performances gains of FOC while still allowing
6892 * applications to provide duty cycle or voltage demand. This
6893 * not to be confused with simple sinusoidal control or phase
6894 * voltage control which lacks the performance gains.
6895 * - AverageSlot: Select which gains are applied to the average controller by
6896 * selecting the slot. Use the configuration api to set the
6897 * gain values for the selected slot before enabling this
6898 * feature. Slot must be within [0,2].
6899 * - DifferentialSlot: Select which gains are applied to the differential
6900 * controller by selecting the slot. Use the
6901 * configuration api to set the gain values for the
6902 * selected slot before enabling this feature. Slot must
6903 * be within [0,2].
6904 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
6905 * output is zero (or within deadband). Set to
6906 * false to use the NeutralMode configuration
6907 * setting (default). This flag exists to provide
6908 * the fundamental behavior of this control when
6909 * output is zero, which is to provide 0V to the
6910 * motor.
6911 * - LimitForwardMotion: Set to true to force forward limiting. This allows
6912 * users to use other limit switch sensors connected to
6913 * robot controller. This also allows use of active
6914 * sensors that require external power.
6915 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
6916 * users to use other limit switch sensors connected to
6917 * robot controller. This also allows use of active
6918 * sensors that require external power.
6919 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
6920 * the LimitForwardMotion and LimitReverseMotion
6921 * parameters, instead allowing motion.
6922 *
6923 * This can be useful on mechanisms such as an
6924 * intake/feeder, where a limit switch stops motion
6925 * while intaking but should be ignored when feeding
6926 * to a shooter.
6927 *
6928 * The hardware limit faults and Forward/ReverseLimit
6929 * signals will still report the values of the limit
6930 * switches regardless of this parameter.
6931 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
6932 * allowing motion.
6933 *
6934 * This can be useful when calibrating the zero point
6935 * of a mechanism such as an elevator.
6936 *
6937 * The software limit faults will still report the
6938 * values of the software limits regardless of this
6939 * parameter.
6940 * - UseTimesync: Set to true to delay applying this control request until a
6941 * timesync boundary (requires Phoenix Pro and CANivore). This
6942 * eliminates the impact of nondeterministic network delays in
6943 * exchange for a larger but deterministic control latency.
6944 *
6945 * This requires setting the ControlTimesyncFreqHz config in
6946 * MotorOutputConfigs. Additionally, when this is enabled, the
6947 * UpdateFreqHz of this request should be set to 0 Hz.
6948 *
6949 * \param request Control object to request of the device
6950 * \returns Status Code of the request, 0 is OK
6951 */
6952 ctre::phoenix::StatusCode SetControl(const controls::DifferentialMotionMagicVoltage &request) final;
6953
6954 /**
6955 * \brief Requests Motion Magic® to target a final position using an
6956 * exponential motion profile, and PID to a differential position
6957 * setpoint.
6958 *
6959 * \details Motion Magic® Expo produces a motion profile in real-time
6960 * while attempting to honor the Cruise Velocity (optional) and the
6961 * mechanism kV and kA, specified via the Motion Magic® configuration
6962 * values. Note that unlike the slot gains, the Expo_kV and Expo_kA
6963 * configs are always in output units of Volts.
6964 *
6965 * Setting Cruise Velocity to 0 will allow the profile to run to the
6966 * max possible velocity based on Expo_kV. This control mode does not
6967 * use the Acceleration or Jerk configs.
6968 *
6969 * Target position can be changed on-the-fly and Motion Magic® will do
6970 * its best to adjust the profile. This control mode is duty cycle
6971 * based, so relevant closed-loop gains will use fractional duty cycle
6972 * for the numerator: +1.0 represents full forward output.
6973 *
6974 * - DifferentialMotionMagicExpoDutyCycle Parameters:
6975 * - AveragePosition: Average position to drive toward in rotations.
6976 * - DifferentialPosition: Differential position to drive toward in rotations.
6977 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
6978 * which increases peak power by ~15% on supported devices (see
6979 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
6980 * commutation.
6981 *
6982 * FOC improves motor performance by leveraging torque (current)
6983 * control. However, this may be inconvenient for applications
6984 * that require specifying duty cycle or voltage.
6985 * CTR-Electronics has developed a hybrid method that combines
6986 * the performances gains of FOC while still allowing
6987 * applications to provide duty cycle or voltage demand. This
6988 * not to be confused with simple sinusoidal control or phase
6989 * voltage control which lacks the performance gains.
6990 * - AverageSlot: Select which gains are applied to the average controller by
6991 * selecting the slot. Use the configuration api to set the
6992 * gain values for the selected slot before enabling this
6993 * feature. Slot must be within [0,2].
6994 * - DifferentialSlot: Select which gains are applied to the differential
6995 * controller by selecting the slot. Use the
6996 * configuration api to set the gain values for the
6997 * selected slot before enabling this feature. Slot must
6998 * be within [0,2].
6999 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
7000 * output is zero (or within deadband). Set to
7001 * false to use the NeutralMode configuration
7002 * setting (default). This flag exists to provide
7003 * the fundamental behavior of this control when
7004 * output is zero, which is to provide 0V to the
7005 * motor.
7006 * - LimitForwardMotion: Set to true to force forward limiting. This allows
7007 * users to use other limit switch sensors connected to
7008 * robot controller. This also allows use of active
7009 * sensors that require external power.
7010 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
7011 * users to use other limit switch sensors connected to
7012 * robot controller. This also allows use of active
7013 * sensors that require external power.
7014 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
7015 * the LimitForwardMotion and LimitReverseMotion
7016 * parameters, instead allowing motion.
7017 *
7018 * This can be useful on mechanisms such as an
7019 * intake/feeder, where a limit switch stops motion
7020 * while intaking but should be ignored when feeding
7021 * to a shooter.
7022 *
7023 * The hardware limit faults and Forward/ReverseLimit
7024 * signals will still report the values of the limit
7025 * switches regardless of this parameter.
7026 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
7027 * allowing motion.
7028 *
7029 * This can be useful when calibrating the zero point
7030 * of a mechanism such as an elevator.
7031 *
7032 * The software limit faults will still report the
7033 * values of the software limits regardless of this
7034 * parameter.
7035 * - UseTimesync: Set to true to delay applying this control request until a
7036 * timesync boundary (requires Phoenix Pro and CANivore). This
7037 * eliminates the impact of nondeterministic network delays in
7038 * exchange for a larger but deterministic control latency.
7039 *
7040 * This requires setting the ControlTimesyncFreqHz config in
7041 * MotorOutputConfigs. Additionally, when this is enabled, the
7042 * UpdateFreqHz of this request should be set to 0 Hz.
7043 *
7044 * \param request Control object to request of the device
7045 * \returns Status Code of the request, 0 is OK
7046 */
7047 ctre::phoenix::StatusCode SetControl(const controls::DifferentialMotionMagicExpoDutyCycle &request) final;
7048
7049 /**
7050 * \brief Requests Motion Magic® to target a final position using an
7051 * exponential motion profile, and PID to a differential position
7052 * setpoint.
7053 *
7054 * \details Motion Magic® Expo produces a motion profile in real-time
7055 * while attempting to honor the Cruise Velocity (optional) and the
7056 * mechanism kV and kA, specified via the Motion Magic® configuration
7057 * values. Note that unlike the slot gains, the Expo_kV and Expo_kA
7058 * configs are always in output units of Volts.
7059 *
7060 * Setting Cruise Velocity to 0 will allow the profile to run to the
7061 * max possible velocity based on Expo_kV. This control mode does not
7062 * use the Acceleration or Jerk configs.
7063 *
7064 * Target position can be changed on-the-fly and Motion Magic® will do
7065 * its best to adjust the profile. This control mode is
7066 * voltage-based, so relevant closed-loop gains will use Volts for the
7067 * numerator.
7068 *
7069 * - DifferentialMotionMagicExpoVoltage Parameters:
7070 * - AveragePosition: Average position to drive toward in rotations.
7071 * - DifferentialPosition: Differential position to drive toward in rotations.
7072 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
7073 * which increases peak power by ~15% on supported devices (see
7074 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
7075 * commutation.
7076 *
7077 * FOC improves motor performance by leveraging torque (current)
7078 * control. However, this may be inconvenient for applications
7079 * that require specifying duty cycle or voltage.
7080 * CTR-Electronics has developed a hybrid method that combines
7081 * the performances gains of FOC while still allowing
7082 * applications to provide duty cycle or voltage demand. This
7083 * not to be confused with simple sinusoidal control or phase
7084 * voltage control which lacks the performance gains.
7085 * - AverageSlot: Select which gains are applied to the average controller by
7086 * selecting the slot. Use the configuration api to set the
7087 * gain values for the selected slot before enabling this
7088 * feature. Slot must be within [0,2].
7089 * - DifferentialSlot: Select which gains are applied to the differential
7090 * controller by selecting the slot. Use the
7091 * configuration api to set the gain values for the
7092 * selected slot before enabling this feature. Slot must
7093 * be within [0,2].
7094 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
7095 * output is zero (or within deadband). Set to
7096 * false to use the NeutralMode configuration
7097 * setting (default). This flag exists to provide
7098 * the fundamental behavior of this control when
7099 * output is zero, which is to provide 0V to the
7100 * motor.
7101 * - LimitForwardMotion: Set to true to force forward limiting. This allows
7102 * users to use other limit switch sensors connected to
7103 * robot controller. This also allows use of active
7104 * sensors that require external power.
7105 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
7106 * users to use other limit switch sensors connected to
7107 * robot controller. This also allows use of active
7108 * sensors that require external power.
7109 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
7110 * the LimitForwardMotion and LimitReverseMotion
7111 * parameters, instead allowing motion.
7112 *
7113 * This can be useful on mechanisms such as an
7114 * intake/feeder, where a limit switch stops motion
7115 * while intaking but should be ignored when feeding
7116 * to a shooter.
7117 *
7118 * The hardware limit faults and Forward/ReverseLimit
7119 * signals will still report the values of the limit
7120 * switches regardless of this parameter.
7121 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
7122 * allowing motion.
7123 *
7124 * This can be useful when calibrating the zero point
7125 * of a mechanism such as an elevator.
7126 *
7127 * The software limit faults will still report the
7128 * values of the software limits regardless of this
7129 * parameter.
7130 * - UseTimesync: Set to true to delay applying this control request until a
7131 * timesync boundary (requires Phoenix Pro and CANivore). This
7132 * eliminates the impact of nondeterministic network delays in
7133 * exchange for a larger but deterministic control latency.
7134 *
7135 * This requires setting the ControlTimesyncFreqHz config in
7136 * MotorOutputConfigs. Additionally, when this is enabled, the
7137 * UpdateFreqHz of this request should be set to 0 Hz.
7138 *
7139 * \param request Control object to request of the device
7140 * \returns Status Code of the request, 0 is OK
7141 */
7142 ctre::phoenix::StatusCode SetControl(const controls::DifferentialMotionMagicExpoVoltage &request) final;
7143
7144 /**
7145 * \brief Requests Motion Magic® to target a final velocity using a
7146 * motion profile, and PID to a differential position setpoint. This
7147 * allows smooth transitions between velocity set points.
7148 *
7149 * \details Motion Magic® Velocity produces a motion profile in
7150 * real-time while attempting to honor the specified Acceleration and
7151 * (optional) Jerk. This control mode does not use the
7152 * CruiseVelocity, Expo_kV, or Expo_kA configs.
7153 *
7154 * Acceleration and jerk are specified in the Motion Magic® persistent
7155 * configuration values. If Jerk is set to zero, Motion Magic® will
7156 * produce a trapezoidal acceleration profile.
7157 *
7158 * Target velocity can also be changed on-the-fly and Motion Magic®
7159 * will do its best to adjust the profile. This control mode is duty
7160 * cycle based, so relevant closed-loop gains will use fractional duty
7161 * cycle for the numerator: +1.0 represents full forward output.
7162 *
7163 * - DifferentialMotionMagicVelocityDutyCycle Parameters:
7164 * - AverageVelocity: Average velocity to drive toward in rotations per
7165 * second.
7166 * - DifferentialPosition: Differential position to drive toward in rotations.
7167 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
7168 * which increases peak power by ~15% on supported devices (see
7169 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
7170 * commutation.
7171 *
7172 * FOC improves motor performance by leveraging torque (current)
7173 * control. However, this may be inconvenient for applications
7174 * that require specifying duty cycle or voltage.
7175 * CTR-Electronics has developed a hybrid method that combines
7176 * the performances gains of FOC while still allowing
7177 * applications to provide duty cycle or voltage demand. This
7178 * not to be confused with simple sinusoidal control or phase
7179 * voltage control which lacks the performance gains.
7180 * - AverageSlot: Select which gains are applied to the average controller by
7181 * selecting the slot. Use the configuration api to set the
7182 * gain values for the selected slot before enabling this
7183 * feature. Slot must be within [0,2].
7184 * - DifferentialSlot: Select which gains are applied to the differential
7185 * controller by selecting the slot. Use the
7186 * configuration api to set the gain values for the
7187 * selected slot before enabling this feature. Slot must
7188 * be within [0,2].
7189 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
7190 * output is zero (or within deadband). Set to
7191 * false to use the NeutralMode configuration
7192 * setting (default). This flag exists to provide
7193 * the fundamental behavior of this control when
7194 * output is zero, which is to provide 0V to the
7195 * motor.
7196 * - LimitForwardMotion: Set to true to force forward limiting. This allows
7197 * users to use other limit switch sensors connected to
7198 * robot controller. This also allows use of active
7199 * sensors that require external power.
7200 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
7201 * users to use other limit switch sensors connected to
7202 * robot controller. This also allows use of active
7203 * sensors that require external power.
7204 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
7205 * the LimitForwardMotion and LimitReverseMotion
7206 * parameters, instead allowing motion.
7207 *
7208 * This can be useful on mechanisms such as an
7209 * intake/feeder, where a limit switch stops motion
7210 * while intaking but should be ignored when feeding
7211 * to a shooter.
7212 *
7213 * The hardware limit faults and Forward/ReverseLimit
7214 * signals will still report the values of the limit
7215 * switches regardless of this parameter.
7216 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
7217 * allowing motion.
7218 *
7219 * This can be useful when calibrating the zero point
7220 * of a mechanism such as an elevator.
7221 *
7222 * The software limit faults will still report the
7223 * values of the software limits regardless of this
7224 * parameter.
7225 * - UseTimesync: Set to true to delay applying this control request until a
7226 * timesync boundary (requires Phoenix Pro and CANivore). This
7227 * eliminates the impact of nondeterministic network delays in
7228 * exchange for a larger but deterministic control latency.
7229 *
7230 * This requires setting the ControlTimesyncFreqHz config in
7231 * MotorOutputConfigs. Additionally, when this is enabled, the
7232 * UpdateFreqHz of this request should be set to 0 Hz.
7233 *
7234 * \param request Control object to request of the device
7235 * \returns Status Code of the request, 0 is OK
7236 */
7237 ctre::phoenix::StatusCode SetControl(const controls::DifferentialMotionMagicVelocityDutyCycle &request) final;
7238
7239 /**
7240 * \brief Requests Motion Magic® to target a final velocity using a
7241 * motion profile, and PID to a differential position setpoint. This
7242 * allows smooth transitions between velocity set points.
7243 *
7244 * \details Motion Magic® Velocity produces a motion profile in
7245 * real-time while attempting to honor the specified Acceleration and
7246 * (optional) Jerk. This control mode does not use the
7247 * CruiseVelocity, Expo_kV, or Expo_kA configs.
7248 *
7249 * Acceleration and jerk are specified in the Motion Magic® persistent
7250 * configuration values. If Jerk is set to zero, Motion Magic® will
7251 * produce a trapezoidal acceleration profile.
7252 *
7253 * Target velocity can also be changed on-the-fly and Motion Magic®
7254 * will do its best to adjust the profile. This control mode is
7255 * voltage-based, so relevant closed-loop gains will use Volts for the
7256 * numerator.
7257 *
7258 * - DifferentialMotionMagicVelocityVoltage Parameters:
7259 * - AverageVelocity: Average velocity to drive toward in rotations per
7260 * second.
7261 * - DifferentialPosition: Differential position to drive toward in rotations.
7262 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
7263 * which increases peak power by ~15% on supported devices (see
7264 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
7265 * commutation.
7266 *
7267 * FOC improves motor performance by leveraging torque (current)
7268 * control. However, this may be inconvenient for applications
7269 * that require specifying duty cycle or voltage.
7270 * CTR-Electronics has developed a hybrid method that combines
7271 * the performances gains of FOC while still allowing
7272 * applications to provide duty cycle or voltage demand. This
7273 * not to be confused with simple sinusoidal control or phase
7274 * voltage control which lacks the performance gains.
7275 * - AverageSlot: Select which gains are applied to the average controller by
7276 * selecting the slot. Use the configuration api to set the
7277 * gain values for the selected slot before enabling this
7278 * feature. Slot must be within [0,2].
7279 * - DifferentialSlot: Select which gains are applied to the differential
7280 * controller by selecting the slot. Use the
7281 * configuration api to set the gain values for the
7282 * selected slot before enabling this feature. Slot must
7283 * be within [0,2].
7284 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
7285 * output is zero (or within deadband). Set to
7286 * false to use the NeutralMode configuration
7287 * setting (default). This flag exists to provide
7288 * the fundamental behavior of this control when
7289 * output is zero, which is to provide 0V to the
7290 * motor.
7291 * - LimitForwardMotion: Set to true to force forward limiting. This allows
7292 * users to use other limit switch sensors connected to
7293 * robot controller. This also allows use of active
7294 * sensors that require external power.
7295 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
7296 * users to use other limit switch sensors connected to
7297 * robot controller. This also allows use of active
7298 * sensors that require external power.
7299 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
7300 * the LimitForwardMotion and LimitReverseMotion
7301 * parameters, instead allowing motion.
7302 *
7303 * This can be useful on mechanisms such as an
7304 * intake/feeder, where a limit switch stops motion
7305 * while intaking but should be ignored when feeding
7306 * to a shooter.
7307 *
7308 * The hardware limit faults and Forward/ReverseLimit
7309 * signals will still report the values of the limit
7310 * switches regardless of this parameter.
7311 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
7312 * allowing motion.
7313 *
7314 * This can be useful when calibrating the zero point
7315 * of a mechanism such as an elevator.
7316 *
7317 * The software limit faults will still report the
7318 * values of the software limits regardless of this
7319 * parameter.
7320 * - UseTimesync: Set to true to delay applying this control request until a
7321 * timesync boundary (requires Phoenix Pro and CANivore). This
7322 * eliminates the impact of nondeterministic network delays in
7323 * exchange for a larger but deterministic control latency.
7324 *
7325 * This requires setting the ControlTimesyncFreqHz config in
7326 * MotorOutputConfigs. Additionally, when this is enabled, the
7327 * UpdateFreqHz of this request should be set to 0 Hz.
7328 *
7329 * \param request Control object to request of the device
7330 * \returns Status Code of the request, 0 is OK
7331 */
7332 ctre::phoenix::StatusCode SetControl(const controls::DifferentialMotionMagicVelocityVoltage &request) final;
7333
7334 /**
7335 * \brief Follow the motor output of another Talon.
7336 *
7337 * \details The follower will atomically change its output type when
7338 * it receives the leader's latest output status signal (DutyCycle,
7339 * MotorVoltage, TorqueCurrent). If Talon is in torque control, the
7340 * torque is copied - which will increase the total torque applied. If
7341 * Talon is in duty cycle output control, the duty cycle is matched.
7342 * If Talon is in voltage output control, the motor voltage is
7343 * matched. Motor direction either matches the leader's configured
7344 * direction or opposes it based on the MotorAlignment.
7345 *
7346 * The leader must ensure the status signal corresponding to its
7347 * control output type (DutyCycle, MotorVoltage, TorqueCurrent) is
7348 * enabled. The update rate of the status signal determines the update
7349 * rate of the follower's output and should be no slower than 20 Hz.
7350 *
7351 * - Follower Parameters:
7352 * - LeaderID: Device ID of the leader to follow.
7353 * - MotorAlignment: Set to Aligned for motor invert to match the leader's
7354 * configured Invert - which is typical when leader and
7355 * follower are mechanically linked and spin in the same
7356 * direction. Set to Opposed for motor invert to oppose the
7357 * leader's configured Invert - this is typical where the
7358 * leader and follower mechanically spin in opposite
7359 * directions.
7360 *
7361 * \param request Control object to request of the device
7362 * \returns Status Code of the request, 0 is OK
7363 */
7364 ctre::phoenix::StatusCode SetControl(const controls::Follower &request) final;
7365
7366 /**
7367 * \brief Follow the motor output of another Talon while ignoring the
7368 * leader's invert setting.
7369 *
7370 * \details The follower will atomically change its output type when
7371 * it receives the leader's latest output status signal (DutyCycle,
7372 * MotorVoltage, TorqueCurrent). If Talon is in torque control, the
7373 * torque is copied - which will increase the total torque applied. If
7374 * Talon is in duty cycle output control, the duty cycle is matched.
7375 * If Talon is in voltage output control, the motor voltage is
7376 * matched. Motor direction is strictly determined by the configured
7377 * invert and not the leader. If you want motor direction to match or
7378 * oppose the leader, use Follower instead.
7379 *
7380 * The leader must ensure the status signal corresponding to its
7381 * control output type (DutyCycle, MotorVoltage, TorqueCurrent) is
7382 * enabled. The update rate of the status signal determines the update
7383 * rate of the follower's output and should be no slower than 20 Hz.
7384 *
7385 * - StrictFollower Parameters:
7386 * - LeaderID: Device ID of the leader to follow.
7387 *
7388 * \param request Control object to request of the device
7389 * \returns Status Code of the request, 0 is OK
7390 */
7391 ctre::phoenix::StatusCode SetControl(const controls::StrictFollower &request) final;
7392
7393 /**
7394 * \brief Follow the differential motor output of another Talon.
7395 *
7396 * \details If Talon is in torque control, the differential torque is
7397 * copied - which will increase the total torque applied. If Talon is
7398 * in duty cycle output control, the differential duty cycle is
7399 * matched. If Talon is in voltage output control, the differential
7400 * motor voltage is matched. Motor direction either matches leader's
7401 * configured direction or opposes it based on the MotorAlignment.
7402 *
7403 * The leader must enable its DifferentialOutput status signal. The
7404 * update rate of the status signal determines the update rate of the
7405 * follower's output and should be no slower than 20 Hz.
7406 *
7407 * - DifferentialFollower Parameters:
7408 * - LeaderID: Device ID of the differential leader to follow.
7409 * - MotorAlignment: Set to Aligned for motor invert to match the leader's
7410 * configured Invert - which is typical when leader and
7411 * follower are mechanically linked and spin in the same
7412 * direction. Set to Opposed for motor invert to oppose the
7413 * leader's configured Invert - this is typical where the
7414 * leader and follower mechanically spin in opposite
7415 * directions.
7416 *
7417 * \param request Control object to request of the device
7418 * \returns Status Code of the request, 0 is OK
7419 */
7420 ctre::phoenix::StatusCode SetControl(const controls::DifferentialFollower &request) final;
7421
7422 /**
7423 * \brief Follow the differential motor output of another Talon while
7424 * ignoring the leader's invert setting.
7425 *
7426 * \details If Talon is in torque control, the differential torque is
7427 * copied - which will increase the total torque applied. If Talon is
7428 * in duty cycle output control, the differential duty cycle is
7429 * matched. If Talon is in voltage output control, the differential
7430 * motor voltage is matched. Motor direction is strictly determined by
7431 * the configured invert and not the leader. If you want motor
7432 * direction to match or oppose the leader, use DifferentialFollower
7433 * instead.
7434 *
7435 * The leader must enable its DifferentialOutput status signal. The
7436 * update rate of the status signal determines the update rate of the
7437 * follower's output and should be no slower than 20 Hz.
7438 *
7439 * - DifferentialStrictFollower Parameters:
7440 * - LeaderID: Device ID of the differential leader to follow.
7441 *
7442 * \param request Control object to request of the device
7443 * \returns Status Code of the request, 0 is OK
7444 */
7445 ctre::phoenix::StatusCode SetControl(const controls::DifferentialStrictFollower &request) final;
7446
7447 /**
7448 * \brief Request neutral output of actuator. The applied brake type
7449 * is determined by the NeutralMode configuration.
7450 *
7451 * - NeutralOut Parameters:
7452 * - UseTimesync: Set to true to delay applying this control request until a
7453 * timesync boundary (requires Phoenix Pro and CANivore). This
7454 * eliminates the impact of nondeterministic network delays in
7455 * exchange for a larger but deterministic control latency.
7456 *
7457 * This requires setting the ControlTimesyncFreqHz config in
7458 * MotorOutputConfigs. Additionally, when this is enabled, the
7459 * UpdateFreqHz of this request should be set to 0 Hz.
7460 *
7461 * \param request Control object to request of the device
7462 * \returns Status Code of the request, 0 is OK
7463 */
7464 ctre::phoenix::StatusCode SetControl(const controls::NeutralOut &request) final;
7465
7466 /**
7467 * \brief Request coast neutral output of actuator. The bridge is
7468 * disabled and the rotor is allowed to coast.
7469 *
7470 * - CoastOut Parameters:
7471 * - UseTimesync: Set to true to delay applying this control request until a
7472 * timesync boundary (requires Phoenix Pro and CANivore). This
7473 * eliminates the impact of nondeterministic network delays in
7474 * exchange for a larger but deterministic control latency.
7475 *
7476 * This requires setting the ControlTimesyncFreqHz config in
7477 * MotorOutputConfigs. Additionally, when this is enabled, the
7478 * UpdateFreqHz of this request should be set to 0 Hz.
7479 *
7480 * \param request Control object to request of the device
7481 * \returns Status Code of the request, 0 is OK
7482 */
7483 ctre::phoenix::StatusCode SetControl(const controls::CoastOut &request) final;
7484
7485 /**
7486 * \brief Applies full neutral-brake by shorting motor leads together.
7487 *
7488 * - StaticBrake Parameters:
7489 * - UseTimesync: Set to true to delay applying this control request until a
7490 * timesync boundary (requires Phoenix Pro and CANivore). This
7491 * eliminates the impact of nondeterministic network delays in
7492 * exchange for a larger but deterministic control latency.
7493 *
7494 * This requires setting the ControlTimesyncFreqHz config in
7495 * MotorOutputConfigs. Additionally, when this is enabled, the
7496 * UpdateFreqHz of this request should be set to 0 Hz.
7497 *
7498 * \param request Control object to request of the device
7499 * \returns Status Code of the request, 0 is OK
7500 */
7501 ctre::phoenix::StatusCode SetControl(const controls::StaticBrake &request) final;
7502
7503 /**
7504 * \brief Plays a single tone at the user specified frequency.
7505 *
7506 * - MusicTone Parameters:
7507 * - AudioFrequency: Sound frequency to play. A value of zero will silence
7508 * the device. The effective frequency range is 10-20000 Hz.
7509 * Any nonzero frequency less than 10 Hz will be capped to
7510 * 10 Hz. Any frequency above 20 kHz will be capped to 20
7511 * kHz.
7512 *
7513 * \param request Control object to request of the device
7514 * \returns Status Code of the request, 0 is OK
7515 */
7516 ctre::phoenix::StatusCode SetControl(const controls::MusicTone &request) final;
7517
7518 /**
7519 * \brief Requests Motion Magic® to target a final velocity using a
7520 * motion profile. This allows smooth transitions between velocity
7521 * set points. Users can optionally provide a duty cycle feedforward.
7522 *
7523 * \details Motion Magic® Velocity produces a motion profile in
7524 * real-time while attempting to honor the specified Acceleration and
7525 * (optional) Jerk. This control mode does not use the
7526 * CruiseVelocity, Expo_kV, or Expo_kA configs.
7527 *
7528 * If the specified acceleration is zero, the Acceleration under
7529 * Motion Magic® configuration parameter is used instead. This allows
7530 * for runtime adjustment of acceleration for advanced users. Jerk is
7531 * also specified in the Motion Magic® persistent configuration
7532 * values. If Jerk is set to zero, Motion Magic® will produce a
7533 * trapezoidal acceleration profile.
7534 *
7535 * Target velocity can also be changed on-the-fly and Motion Magic®
7536 * will do its best to adjust the profile. This control mode is duty
7537 * cycle based, so relevant closed-loop gains will use fractional duty
7538 * cycle for the numerator: +1.0 represents full forward output.
7539 *
7540 * - MotionMagicVelocityDutyCycle Parameters:
7541 * - Velocity: Target velocity to drive toward in rotations per second. This
7542 * can be changed on-the fly.
7543 * - Acceleration: This is the absolute Acceleration to use generating the
7544 * profile. If this parameter is zero, the Acceleration
7545 * persistent configuration parameter is used instead.
7546 * Acceleration is in rotations per second squared. If
7547 * nonzero, the signage does not matter as the absolute value
7548 * is used.
7549 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
7550 * which increases peak power by ~15% on supported devices (see
7551 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
7552 * commutation.
7553 *
7554 * FOC improves motor performance by leveraging torque (current)
7555 * control. However, this may be inconvenient for applications
7556 * that require specifying duty cycle or voltage.
7557 * CTR-Electronics has developed a hybrid method that combines
7558 * the performances gains of FOC while still allowing
7559 * applications to provide duty cycle or voltage demand. This
7560 * not to be confused with simple sinusoidal control or phase
7561 * voltage control which lacks the performance gains.
7562 * - FeedForward: Feedforward to apply in fractional units between -1 and +1.
7563 * This is added to the output of the onboard feedforward
7564 * terms.
7565 * - Slot: Select which gains are applied by selecting the slot. Use the
7566 * configuration api to set the gain values for the selected slot
7567 * before enabling this feature. Slot must be within [0,2].
7568 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
7569 * output is zero (or within deadband). Set to
7570 * false to use the NeutralMode configuration
7571 * setting (default). This flag exists to provide
7572 * the fundamental behavior of this control when
7573 * output is zero, which is to provide 0V to the
7574 * motor.
7575 * - LimitForwardMotion: Set to true to force forward limiting. This allows
7576 * users to use other limit switch sensors connected to
7577 * robot controller. This also allows use of active
7578 * sensors that require external power.
7579 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
7580 * users to use other limit switch sensors connected to
7581 * robot controller. This also allows use of active
7582 * sensors that require external power.
7583 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
7584 * the LimitForwardMotion and LimitReverseMotion
7585 * parameters, instead allowing motion.
7586 *
7587 * This can be useful on mechanisms such as an
7588 * intake/feeder, where a limit switch stops motion
7589 * while intaking but should be ignored when feeding
7590 * to a shooter.
7591 *
7592 * The hardware limit faults and Forward/ReverseLimit
7593 * signals will still report the values of the limit
7594 * switches regardless of this parameter.
7595 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
7596 * allowing motion.
7597 *
7598 * This can be useful when calibrating the zero point
7599 * of a mechanism such as an elevator.
7600 *
7601 * The software limit faults will still report the
7602 * values of the software limits regardless of this
7603 * parameter.
7604 * - UseTimesync: Set to true to delay applying this control request until a
7605 * timesync boundary (requires Phoenix Pro and CANivore). This
7606 * eliminates the impact of nondeterministic network delays in
7607 * exchange for a larger but deterministic control latency.
7608 *
7609 * This requires setting the ControlTimesyncFreqHz config in
7610 * MotorOutputConfigs. Additionally, when this is enabled, the
7611 * UpdateFreqHz of this request should be set to 0 Hz.
7612 *
7613 * \param request Control object to request of the device
7614 * \returns Status Code of the request, 0 is OK
7615 */
7616 ctre::phoenix::StatusCode SetControl(const controls::MotionMagicVelocityDutyCycle &request) final;
7617
7618 /**
7619 * \brief Requests Motion Magic® to target a final velocity using a
7620 * motion profile. This allows smooth transitions between velocity
7621 * set points. Users can optionally provide a torque feedforward.
7622 *
7623 * \details Motion Magic® Velocity produces a motion profile in
7624 * real-time while attempting to honor the specified Acceleration and
7625 * (optional) Jerk. This control mode does not use the
7626 * CruiseVelocity, Expo_kV, or Expo_kA configs.
7627 *
7628 * If the specified acceleration is zero, the Acceleration under
7629 * Motion Magic® configuration parameter is used instead. This allows
7630 * for runtime adjustment of acceleration for advanced users. Jerk is
7631 * also specified in the Motion Magic® persistent configuration
7632 * values. If Jerk is set to zero, Motion Magic® will produce a
7633 * trapezoidal acceleration profile.
7634 *
7635 * Target velocity can also be changed on-the-fly and Motion Magic®
7636 * will do its best to adjust the profile. This control mode is based
7637 * on torque current, so relevant closed-loop gains will use Amperes
7638 * for the numerator.
7639 *
7640 * - MotionMagicVelocityTorqueCurrentFOC Parameters:
7641 * - Velocity: Target velocity to drive toward in rotations per second. This
7642 * can be changed on-the fly.
7643 * - Acceleration: This is the absolute Acceleration to use generating the
7644 * profile. If this parameter is zero, the Acceleration
7645 * persistent configuration parameter is used instead.
7646 * Acceleration is in rotations per second squared. If
7647 * nonzero, the signage does not matter as the absolute value
7648 * is used.
7649 * - FeedForward: Feedforward to apply in torque current in Amperes. This is
7650 * added to the output of the onboard feedforward terms.
7651 *
7652 * User can use motor's kT to scale Newton-meter to Amperes.
7653 * - Slot: Select which gains are applied by selecting the slot. Use the
7654 * configuration api to set the gain values for the selected slot
7655 * before enabling this feature. Slot must be within [0,2].
7656 * - OverrideCoastDurNeutral: Set to true to coast the rotor when output is
7657 * zero (or within deadband). Set to false to use
7658 * the NeutralMode configuration setting (default).
7659 * This flag exists to provide the fundamental
7660 * behavior of this control when output is zero,
7661 * which is to provide 0A (zero torque).
7662 * - LimitForwardMotion: Set to true to force forward limiting. This allows
7663 * users to use other limit switch sensors connected to
7664 * robot controller. This also allows use of active
7665 * sensors that require external power.
7666 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
7667 * users to use other limit switch sensors connected to
7668 * robot controller. This also allows use of active
7669 * sensors that require external power.
7670 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
7671 * the LimitForwardMotion and LimitReverseMotion
7672 * parameters, instead allowing motion.
7673 *
7674 * This can be useful on mechanisms such as an
7675 * intake/feeder, where a limit switch stops motion
7676 * while intaking but should be ignored when feeding
7677 * to a shooter.
7678 *
7679 * The hardware limit faults and Forward/ReverseLimit
7680 * signals will still report the values of the limit
7681 * switches regardless of this parameter.
7682 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
7683 * allowing motion.
7684 *
7685 * This can be useful when calibrating the zero point
7686 * of a mechanism such as an elevator.
7687 *
7688 * The software limit faults will still report the
7689 * values of the software limits regardless of this
7690 * parameter.
7691 * - UseTimesync: Set to true to delay applying this control request until a
7692 * timesync boundary (requires Phoenix Pro and CANivore). This
7693 * eliminates the impact of nondeterministic network delays in
7694 * exchange for a larger but deterministic control latency.
7695 *
7696 * This requires setting the ControlTimesyncFreqHz config in
7697 * MotorOutputConfigs. Additionally, when this is enabled, the
7698 * UpdateFreqHz of this request should be set to 0 Hz.
7699 *
7700 * \param request Control object to request of the device
7701 * \returns Status Code of the request, 0 is OK
7702 */
7703 ctre::phoenix::StatusCode SetControl(const controls::MotionMagicVelocityTorqueCurrentFOC &request) final;
7704
7705 /**
7706 * \brief Requests Motion Magic® to target a final velocity using a
7707 * motion profile. This allows smooth transitions between velocity
7708 * set points. Users can optionally provide a voltage feedforward.
7709 *
7710 * \details Motion Magic® Velocity produces a motion profile in
7711 * real-time while attempting to honor the specified Acceleration and
7712 * (optional) Jerk. This control mode does not use the
7713 * CruiseVelocity, Expo_kV, or Expo_kA configs.
7714 *
7715 * If the specified acceleration is zero, the Acceleration under
7716 * Motion Magic® configuration parameter is used instead. This allows
7717 * for runtime adjustment of acceleration for advanced users. Jerk is
7718 * also specified in the Motion Magic® persistent configuration
7719 * values. If Jerk is set to zero, Motion Magic® will produce a
7720 * trapezoidal acceleration profile.
7721 *
7722 * Target velocity can also be changed on-the-fly and Motion Magic®
7723 * will do its best to adjust the profile. This control mode is
7724 * voltage-based, so relevant closed-loop gains will use Volts for the
7725 * numerator.
7726 *
7727 * - MotionMagicVelocityVoltage Parameters:
7728 * - Velocity: Target velocity to drive toward in rotations per second. This
7729 * can be changed on-the fly.
7730 * - Acceleration: This is the absolute Acceleration to use generating the
7731 * profile. If this parameter is zero, the Acceleration
7732 * persistent configuration parameter is used instead.
7733 * Acceleration is in rotations per second squared. If
7734 * nonzero, the signage does not matter as the absolute value
7735 * is used.
7736 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
7737 * which increases peak power by ~15% on supported devices (see
7738 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
7739 * commutation.
7740 *
7741 * FOC improves motor performance by leveraging torque (current)
7742 * control. However, this may be inconvenient for applications
7743 * that require specifying duty cycle or voltage.
7744 * CTR-Electronics has developed a hybrid method that combines
7745 * the performances gains of FOC while still allowing
7746 * applications to provide duty cycle or voltage demand. This
7747 * not to be confused with simple sinusoidal control or phase
7748 * voltage control which lacks the performance gains.
7749 * - FeedForward: Feedforward to apply in volts. This is added to the output
7750 * of the onboard feedforward terms.
7751 * - Slot: Select which gains are applied by selecting the slot. Use the
7752 * configuration api to set the gain values for the selected slot
7753 * before enabling this feature. Slot must be within [0,2].
7754 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
7755 * output is zero (or within deadband). Set to
7756 * false to use the NeutralMode configuration
7757 * setting (default). This flag exists to provide
7758 * the fundamental behavior of this control when
7759 * output is zero, which is to provide 0V to the
7760 * motor.
7761 * - LimitForwardMotion: Set to true to force forward limiting. This allows
7762 * users to use other limit switch sensors connected to
7763 * robot controller. This also allows use of active
7764 * sensors that require external power.
7765 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
7766 * users to use other limit switch sensors connected to
7767 * robot controller. This also allows use of active
7768 * sensors that require external power.
7769 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
7770 * the LimitForwardMotion and LimitReverseMotion
7771 * parameters, instead allowing motion.
7772 *
7773 * This can be useful on mechanisms such as an
7774 * intake/feeder, where a limit switch stops motion
7775 * while intaking but should be ignored when feeding
7776 * to a shooter.
7777 *
7778 * The hardware limit faults and Forward/ReverseLimit
7779 * signals will still report the values of the limit
7780 * switches regardless of this parameter.
7781 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
7782 * allowing motion.
7783 *
7784 * This can be useful when calibrating the zero point
7785 * of a mechanism such as an elevator.
7786 *
7787 * The software limit faults will still report the
7788 * values of the software limits regardless of this
7789 * parameter.
7790 * - UseTimesync: Set to true to delay applying this control request until a
7791 * timesync boundary (requires Phoenix Pro and CANivore). This
7792 * eliminates the impact of nondeterministic network delays in
7793 * exchange for a larger but deterministic control latency.
7794 *
7795 * This requires setting the ControlTimesyncFreqHz config in
7796 * MotorOutputConfigs. Additionally, when this is enabled, the
7797 * UpdateFreqHz of this request should be set to 0 Hz.
7798 *
7799 * \param request Control object to request of the device
7800 * \returns Status Code of the request, 0 is OK
7801 */
7802 ctre::phoenix::StatusCode SetControl(const controls::MotionMagicVelocityVoltage &request) final;
7803
7804 /**
7805 * \brief Requests Motion Magic® to target a final position using an
7806 * exponential motion profile. Users can optionally provide a duty
7807 * cycle feedforward.
7808 *
7809 * \details Motion Magic® Expo produces a motion profile in real-time
7810 * while attempting to honor the Cruise Velocity (optional) and the
7811 * mechanism kV and kA, specified via the Motion Magic® configuration
7812 * values. Note that unlike the slot gains, the Expo_kV and Expo_kA
7813 * configs are always in output units of Volts.
7814 *
7815 * Setting Cruise Velocity to 0 will allow the profile to run to the
7816 * max possible velocity based on Expo_kV. This control mode does not
7817 * use the Acceleration or Jerk configs.
7818 *
7819 * Target position can be changed on-the-fly and Motion Magic® will do
7820 * its best to adjust the profile. This control mode is duty cycle
7821 * based, so relevant closed-loop gains will use fractional duty cycle
7822 * for the numerator: +1.0 represents full forward output.
7823 *
7824 * - MotionMagicExpoDutyCycle Parameters:
7825 * - Position: Position to drive toward in rotations.
7826 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
7827 * which increases peak power by ~15% on supported devices (see
7828 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
7829 * commutation.
7830 *
7831 * FOC improves motor performance by leveraging torque (current)
7832 * control. However, this may be inconvenient for applications
7833 * that require specifying duty cycle or voltage.
7834 * CTR-Electronics has developed a hybrid method that combines
7835 * the performances gains of FOC while still allowing
7836 * applications to provide duty cycle or voltage demand. This
7837 * not to be confused with simple sinusoidal control or phase
7838 * voltage control which lacks the performance gains.
7839 * - FeedForward: Feedforward to apply in fractional units between -1 and +1.
7840 * This is added to the output of the onboard feedforward
7841 * terms.
7842 * - Slot: Select which gains are applied by selecting the slot. Use the
7843 * configuration api to set the gain values for the selected slot
7844 * before enabling this feature. Slot must be within [0,2].
7845 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
7846 * output is zero (or within deadband). Set to
7847 * false to use the NeutralMode configuration
7848 * setting (default). This flag exists to provide
7849 * the fundamental behavior of this control when
7850 * output is zero, which is to provide 0V to the
7851 * motor.
7852 * - LimitForwardMotion: Set to true to force forward limiting. This allows
7853 * users to use other limit switch sensors connected to
7854 * robot controller. This also allows use of active
7855 * sensors that require external power.
7856 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
7857 * users to use other limit switch sensors connected to
7858 * robot controller. This also allows use of active
7859 * sensors that require external power.
7860 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
7861 * the LimitForwardMotion and LimitReverseMotion
7862 * parameters, instead allowing motion.
7863 *
7864 * This can be useful on mechanisms such as an
7865 * intake/feeder, where a limit switch stops motion
7866 * while intaking but should be ignored when feeding
7867 * to a shooter.
7868 *
7869 * The hardware limit faults and Forward/ReverseLimit
7870 * signals will still report the values of the limit
7871 * switches regardless of this parameter.
7872 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
7873 * allowing motion.
7874 *
7875 * This can be useful when calibrating the zero point
7876 * of a mechanism such as an elevator.
7877 *
7878 * The software limit faults will still report the
7879 * values of the software limits regardless of this
7880 * parameter.
7881 * - UseTimesync: Set to true to delay applying this control request until a
7882 * timesync boundary (requires Phoenix Pro and CANivore). This
7883 * eliminates the impact of nondeterministic network delays in
7884 * exchange for a larger but deterministic control latency.
7885 *
7886 * This requires setting the ControlTimesyncFreqHz config in
7887 * MotorOutputConfigs. Additionally, when this is enabled, the
7888 * UpdateFreqHz of this request should be set to 0 Hz.
7889 *
7890 * \param request Control object to request of the device
7891 * \returns Status Code of the request, 0 is OK
7892 */
7893 ctre::phoenix::StatusCode SetControl(const controls::MotionMagicExpoDutyCycle &request) final;
7894
7895 /**
7896 * \brief Requests Motion Magic® to target a final position using an
7897 * exponential motion profile. Users can optionally provide a voltage
7898 * feedforward.
7899 *
7900 * \details Motion Magic® Expo produces a motion profile in real-time
7901 * while attempting to honor the Cruise Velocity (optional) and the
7902 * mechanism kV and kA, specified via the Motion Magic® configuration
7903 * values. Note that unlike the slot gains, the Expo_kV and Expo_kA
7904 * configs are always in output units of Volts.
7905 *
7906 * Setting Cruise Velocity to 0 will allow the profile to run to the
7907 * max possible velocity based on Expo_kV. This control mode does not
7908 * use the Acceleration or Jerk configs.
7909 *
7910 * Target position can be changed on-the-fly and Motion Magic® will do
7911 * its best to adjust the profile. This control mode is
7912 * voltage-based, so relevant closed-loop gains will use Volts for the
7913 * numerator.
7914 *
7915 * - MotionMagicExpoVoltage Parameters:
7916 * - Position: Position to drive toward in rotations.
7917 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
7918 * which increases peak power by ~15% on supported devices (see
7919 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
7920 * commutation.
7921 *
7922 * FOC improves motor performance by leveraging torque (current)
7923 * control. However, this may be inconvenient for applications
7924 * that require specifying duty cycle or voltage.
7925 * CTR-Electronics has developed a hybrid method that combines
7926 * the performances gains of FOC while still allowing
7927 * applications to provide duty cycle or voltage demand. This
7928 * not to be confused with simple sinusoidal control or phase
7929 * voltage control which lacks the performance gains.
7930 * - FeedForward: Feedforward to apply in volts. This is added to the output
7931 * of the onboard feedforward terms.
7932 * - Slot: Select which gains are applied by selecting the slot. Use the
7933 * configuration api to set the gain values for the selected slot
7934 * before enabling this feature. Slot must be within [0,2].
7935 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
7936 * output is zero (or within deadband). Set to
7937 * false to use the NeutralMode configuration
7938 * setting (default). This flag exists to provide
7939 * the fundamental behavior of this control when
7940 * output is zero, which is to provide 0V to the
7941 * motor.
7942 * - LimitForwardMotion: Set to true to force forward limiting. This allows
7943 * users to use other limit switch sensors connected to
7944 * robot controller. This also allows use of active
7945 * sensors that require external power.
7946 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
7947 * users to use other limit switch sensors connected to
7948 * robot controller. This also allows use of active
7949 * sensors that require external power.
7950 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
7951 * the LimitForwardMotion and LimitReverseMotion
7952 * parameters, instead allowing motion.
7953 *
7954 * This can be useful on mechanisms such as an
7955 * intake/feeder, where a limit switch stops motion
7956 * while intaking but should be ignored when feeding
7957 * to a shooter.
7958 *
7959 * The hardware limit faults and Forward/ReverseLimit
7960 * signals will still report the values of the limit
7961 * switches regardless of this parameter.
7962 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
7963 * allowing motion.
7964 *
7965 * This can be useful when calibrating the zero point
7966 * of a mechanism such as an elevator.
7967 *
7968 * The software limit faults will still report the
7969 * values of the software limits regardless of this
7970 * parameter.
7971 * - UseTimesync: Set to true to delay applying this control request until a
7972 * timesync boundary (requires Phoenix Pro and CANivore). This
7973 * eliminates the impact of nondeterministic network delays in
7974 * exchange for a larger but deterministic control latency.
7975 *
7976 * This requires setting the ControlTimesyncFreqHz config in
7977 * MotorOutputConfigs. Additionally, when this is enabled, the
7978 * UpdateFreqHz of this request should be set to 0 Hz.
7979 *
7980 * \param request Control object to request of the device
7981 * \returns Status Code of the request, 0 is OK
7982 */
7983 ctre::phoenix::StatusCode SetControl(const controls::MotionMagicExpoVoltage &request) final;
7984
7985 /**
7986 * \brief Requests Motion Magic® to target a final position using an
7987 * exponential motion profile. Users can optionally provide a torque
7988 * current feedforward.
7989 *
7990 * \details Motion Magic® Expo produces a motion profile in real-time
7991 * while attempting to honor the Cruise Velocity (optional) and the
7992 * mechanism kV and kA, specified via the Motion Magic® configuration
7993 * values. Note that unlike the slot gains, the Expo_kV and Expo_kA
7994 * configs are always in output units of Volts.
7995 *
7996 * Setting Cruise Velocity to 0 will allow the profile to run to the
7997 * max possible velocity based on Expo_kV. This control mode does not
7998 * use the Acceleration or Jerk configs.
7999 *
8000 * Target position can be changed on-the-fly and Motion Magic® will do
8001 * its best to adjust the profile. This control mode is based on
8002 * torque current, so relevant closed-loop gains will use Amperes for
8003 * the numerator.
8004 *
8005 * - MotionMagicExpoTorqueCurrentFOC Parameters:
8006 * - Position: Position to drive toward in rotations.
8007 * - FeedForward: Feedforward to apply in torque current in Amperes. This is
8008 * added to the output of the onboard feedforward terms.
8009 *
8010 * User can use motor's kT to scale Newton-meter to Amperes.
8011 * - Slot: Select which gains are applied by selecting the slot. Use the
8012 * configuration api to set the gain values for the selected slot
8013 * before enabling this feature. Slot must be within [0,2].
8014 * - OverrideCoastDurNeutral: Set to true to coast the rotor when output is
8015 * zero (or within deadband). Set to false to use
8016 * the NeutralMode configuration setting (default).
8017 * This flag exists to provide the fundamental
8018 * behavior of this control when output is zero,
8019 * which is to provide 0A (zero torque).
8020 * - LimitForwardMotion: Set to true to force forward limiting. This allows
8021 * users to use other limit switch sensors connected to
8022 * robot controller. This also allows use of active
8023 * sensors that require external power.
8024 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
8025 * users to use other limit switch sensors connected to
8026 * robot controller. This also allows use of active
8027 * sensors that require external power.
8028 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
8029 * the LimitForwardMotion and LimitReverseMotion
8030 * parameters, instead allowing motion.
8031 *
8032 * This can be useful on mechanisms such as an
8033 * intake/feeder, where a limit switch stops motion
8034 * while intaking but should be ignored when feeding
8035 * to a shooter.
8036 *
8037 * The hardware limit faults and Forward/ReverseLimit
8038 * signals will still report the values of the limit
8039 * switches regardless of this parameter.
8040 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
8041 * allowing motion.
8042 *
8043 * This can be useful when calibrating the zero point
8044 * of a mechanism such as an elevator.
8045 *
8046 * The software limit faults will still report the
8047 * values of the software limits regardless of this
8048 * parameter.
8049 * - UseTimesync: Set to true to delay applying this control request until a
8050 * timesync boundary (requires Phoenix Pro and CANivore). This
8051 * eliminates the impact of nondeterministic network delays in
8052 * exchange for a larger but deterministic control latency.
8053 *
8054 * This requires setting the ControlTimesyncFreqHz config in
8055 * MotorOutputConfigs. Additionally, when this is enabled, the
8056 * UpdateFreqHz of this request should be set to 0 Hz.
8057 *
8058 * \param request Control object to request of the device
8059 * \returns Status Code of the request, 0 is OK
8060 */
8061 ctre::phoenix::StatusCode SetControl(const controls::MotionMagicExpoTorqueCurrentFOC &request) final;
8062
8063 /**
8064 * \brief Requests Motion Magic® to target a final position using a
8065 * motion profile. This dynamic request allows runtime changes to
8066 * Cruise Velocity, Acceleration, and (optional) Jerk. Users can
8067 * optionally provide a duty cycle feedforward.
8068 *
8069 * \details Motion Magic® produces a motion profile in real-time while
8070 * attempting to honor the specified Cruise Velocity, Acceleration,
8071 * and (optional) Jerk. This control mode does not use the Expo_kV or
8072 * Expo_kA configs.
8073 *
8074 * Target position can be changed on-the-fly and Motion Magic® will do
8075 * its best to adjust the profile. This control mode is duty cycle
8076 * based, so relevant closed-loop gains will use fractional duty cycle
8077 * for the numerator: +1.0 represents full forward output.
8078 *
8079 * - DynamicMotionMagicDutyCycle Parameters:
8080 * - Position: Position to drive toward in rotations.
8081 * - Velocity: Cruise velocity for profiling. The signage does not matter as
8082 * the device will use the absolute value for profile generation.
8083 * - Acceleration: Acceleration for profiling. The signage does not matter as
8084 * the device will use the absolute value for profile
8085 * generation
8086 * - Jerk: Jerk for profiling. The signage does not matter as the device will
8087 * use the absolute value for profile generation.
8088 *
8089 * Jerk is optional; if this is set to zero, then Motion Magic® will
8090 * not apply a Jerk limit.
8091 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
8092 * which increases peak power by ~15% on supported devices (see
8093 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
8094 * commutation.
8095 *
8096 * FOC improves motor performance by leveraging torque (current)
8097 * control. However, this may be inconvenient for applications
8098 * that require specifying duty cycle or voltage.
8099 * CTR-Electronics has developed a hybrid method that combines
8100 * the performances gains of FOC while still allowing
8101 * applications to provide duty cycle or voltage demand. This
8102 * not to be confused with simple sinusoidal control or phase
8103 * voltage control which lacks the performance gains.
8104 * - FeedForward: Feedforward to apply in fractional units between -1 and +1.
8105 * This is added to the output of the onboard feedforward
8106 * terms.
8107 * - Slot: Select which gains are applied by selecting the slot. Use the
8108 * configuration api to set the gain values for the selected slot
8109 * before enabling this feature. Slot must be within [0,2].
8110 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
8111 * output is zero (or within deadband). Set to
8112 * false to use the NeutralMode configuration
8113 * setting (default). This flag exists to provide
8114 * the fundamental behavior of this control when
8115 * output is zero, which is to provide 0V to the
8116 * motor.
8117 * - LimitForwardMotion: Set to true to force forward limiting. This allows
8118 * users to use other limit switch sensors connected to
8119 * robot controller. This also allows use of active
8120 * sensors that require external power.
8121 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
8122 * users to use other limit switch sensors connected to
8123 * robot controller. This also allows use of active
8124 * sensors that require external power.
8125 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
8126 * the LimitForwardMotion and LimitReverseMotion
8127 * parameters, instead allowing motion.
8128 *
8129 * This can be useful on mechanisms such as an
8130 * intake/feeder, where a limit switch stops motion
8131 * while intaking but should be ignored when feeding
8132 * to a shooter.
8133 *
8134 * The hardware limit faults and Forward/ReverseLimit
8135 * signals will still report the values of the limit
8136 * switches regardless of this parameter.
8137 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
8138 * allowing motion.
8139 *
8140 * This can be useful when calibrating the zero point
8141 * of a mechanism such as an elevator.
8142 *
8143 * The software limit faults will still report the
8144 * values of the software limits regardless of this
8145 * parameter.
8146 * - UseTimesync: Set to true to delay applying this control request until a
8147 * timesync boundary (requires Phoenix Pro and CANivore). This
8148 * eliminates the impact of nondeterministic network delays in
8149 * exchange for a larger but deterministic control latency.
8150 *
8151 * This requires setting the ControlTimesyncFreqHz config in
8152 * MotorOutputConfigs. Additionally, when this is enabled, the
8153 * UpdateFreqHz of this request should be set to 0 Hz.
8154 *
8155 * \param request Control object to request of the device
8156 * \returns Status Code of the request, 0 is OK
8157 */
8158 ctre::phoenix::StatusCode SetControl(const controls::DynamicMotionMagicDutyCycle &request) final;
8159
8160 /**
8161 * \brief Requests Motion Magic® to target a final position using a
8162 * motion profile. This dynamic request allows runtime changes to
8163 * Cruise Velocity, Acceleration, and (optional) Jerk. Users can
8164 * optionally provide a voltage feedforward.
8165 *
8166 * \details Motion Magic® produces a motion profile in real-time while
8167 * attempting to honor the specified Cruise Velocity, Acceleration,
8168 * and (optional) Jerk. This control mode does not use the Expo_kV or
8169 * Expo_kA configs.
8170 *
8171 * Target position can be changed on-the-fly and Motion Magic® will do
8172 * its best to adjust the profile. This control mode is
8173 * voltage-based, so relevant closed-loop gains will use Volts for the
8174 * numerator.
8175 *
8176 * - DynamicMotionMagicVoltage Parameters:
8177 * - Position: Position to drive toward in rotations.
8178 * - Velocity: Cruise velocity for profiling. The signage does not matter as
8179 * the device will use the absolute value for profile generation.
8180 * - Acceleration: Acceleration for profiling. The signage does not matter as
8181 * the device will use the absolute value for profile
8182 * generation.
8183 * - Jerk: Jerk for profiling. The signage does not matter as the device will
8184 * use the absolute value for profile generation.
8185 *
8186 * Jerk is optional; if this is set to zero, then Motion Magic® will
8187 * not apply a Jerk limit.
8188 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
8189 * which increases peak power by ~15% on supported devices (see
8190 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
8191 * commutation.
8192 *
8193 * FOC improves motor performance by leveraging torque (current)
8194 * control. However, this may be inconvenient for applications
8195 * that require specifying duty cycle or voltage.
8196 * CTR-Electronics has developed a hybrid method that combines
8197 * the performances gains of FOC while still allowing
8198 * applications to provide duty cycle or voltage demand. This
8199 * not to be confused with simple sinusoidal control or phase
8200 * voltage control which lacks the performance gains.
8201 * - FeedForward: Feedforward to apply in volts. This is added to the output
8202 * of the onboard feedforward terms.
8203 * - Slot: Select which gains are applied by selecting the slot. Use the
8204 * configuration api to set the gain values for the selected slot
8205 * before enabling this feature. Slot must be within [0,2].
8206 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
8207 * output is zero (or within deadband). Set to
8208 * false to use the NeutralMode configuration
8209 * setting (default). This flag exists to provide
8210 * the fundamental behavior of this control when
8211 * output is zero, which is to provide 0V to the
8212 * motor.
8213 * - LimitForwardMotion: Set to true to force forward limiting. This allows
8214 * users to use other limit switch sensors connected to
8215 * robot controller. This also allows use of active
8216 * sensors that require external power.
8217 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
8218 * users to use other limit switch sensors connected to
8219 * robot controller. This also allows use of active
8220 * sensors that require external power.
8221 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
8222 * the LimitForwardMotion and LimitReverseMotion
8223 * parameters, instead allowing motion.
8224 *
8225 * This can be useful on mechanisms such as an
8226 * intake/feeder, where a limit switch stops motion
8227 * while intaking but should be ignored when feeding
8228 * to a shooter.
8229 *
8230 * The hardware limit faults and Forward/ReverseLimit
8231 * signals will still report the values of the limit
8232 * switches regardless of this parameter.
8233 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
8234 * allowing motion.
8235 *
8236 * This can be useful when calibrating the zero point
8237 * of a mechanism such as an elevator.
8238 *
8239 * The software limit faults will still report the
8240 * values of the software limits regardless of this
8241 * parameter.
8242 * - UseTimesync: Set to true to delay applying this control request until a
8243 * timesync boundary (requires Phoenix Pro and CANivore). This
8244 * eliminates the impact of nondeterministic network delays in
8245 * exchange for a larger but deterministic control latency.
8246 *
8247 * This requires setting the ControlTimesyncFreqHz config in
8248 * MotorOutputConfigs. Additionally, when this is enabled, the
8249 * UpdateFreqHz of this request should be set to 0 Hz.
8250 *
8251 * \param request Control object to request of the device
8252 * \returns Status Code of the request, 0 is OK
8253 */
8254 ctre::phoenix::StatusCode SetControl(const controls::DynamicMotionMagicVoltage &request) final;
8255
8256 /**
8257 * \brief Requests Motion Magic® to target a final position using a
8258 * motion profile. This dynamic request allows runtime changes to
8259 * Cruise Velocity, Acceleration, and (optional) Jerk. Users can
8260 * optionally provide a torque current feedforward.
8261 *
8262 * \details Motion Magic® produces a motion profile in real-time while
8263 * attempting to honor the specified Cruise Velocity, Acceleration,
8264 * and (optional) Jerk. This control mode does not use the Expo_kV or
8265 * Expo_kA configs.
8266 *
8267 * Target position can be changed on-the-fly and Motion Magic® will do
8268 * its best to adjust the profile. This control mode is based on
8269 * torque current, so relevant closed-loop gains will use Amperes for
8270 * the numerator.
8271 *
8272 * - DynamicMotionMagicTorqueCurrentFOC Parameters:
8273 * - Position: Position to drive toward in rotations.
8274 * - Velocity: Cruise velocity for profiling. The signage does not matter as
8275 * the device will use the absolute value for profile generation.
8276 * - Acceleration: Acceleration for profiling. The signage does not matter as
8277 * the device will use the absolute value for profile
8278 * generation.
8279 * - Jerk: Jerk for profiling. The signage does not matter as the device will
8280 * use the absolute value for profile generation.
8281 *
8282 * Jerk is optional; if this is set to zero, then Motion Magic® will
8283 * not apply a Jerk limit.
8284 * - FeedForward: Feedforward to apply in torque current in Amperes. This is
8285 * added to the output of the onboard feedforward terms.
8286 *
8287 * User can use motor's kT to scale Newton-meter to Amperes.
8288 * - Slot: Select which gains are applied by selecting the slot. Use the
8289 * configuration api to set the gain values for the selected slot
8290 * before enabling this feature. Slot must be within [0,2].
8291 * - OverrideCoastDurNeutral: Set to true to coast the rotor when output is
8292 * zero (or within deadband). Set to false to use
8293 * the NeutralMode configuration setting (default).
8294 * This flag exists to provide the fundamental
8295 * behavior of this control when output is zero,
8296 * which is to provide 0A (zero torque).
8297 * - LimitForwardMotion: Set to true to force forward limiting. This allows
8298 * users to use other limit switch sensors connected to
8299 * robot controller. This also allows use of active
8300 * sensors that require external power.
8301 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
8302 * users to use other limit switch sensors connected to
8303 * robot controller. This also allows use of active
8304 * sensors that require external power.
8305 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
8306 * the LimitForwardMotion and LimitReverseMotion
8307 * parameters, instead allowing motion.
8308 *
8309 * This can be useful on mechanisms such as an
8310 * intake/feeder, where a limit switch stops motion
8311 * while intaking but should be ignored when feeding
8312 * to a shooter.
8313 *
8314 * The hardware limit faults and Forward/ReverseLimit
8315 * signals will still report the values of the limit
8316 * switches regardless of this parameter.
8317 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
8318 * allowing motion.
8319 *
8320 * This can be useful when calibrating the zero point
8321 * of a mechanism such as an elevator.
8322 *
8323 * The software limit faults will still report the
8324 * values of the software limits regardless of this
8325 * parameter.
8326 * - UseTimesync: Set to true to delay applying this control request until a
8327 * timesync boundary (requires Phoenix Pro and CANivore). This
8328 * eliminates the impact of nondeterministic network delays in
8329 * exchange for a larger but deterministic control latency.
8330 *
8331 * This requires setting the ControlTimesyncFreqHz config in
8332 * MotorOutputConfigs. Additionally, when this is enabled, the
8333 * UpdateFreqHz of this request should be set to 0 Hz.
8334 *
8335 * \param request Control object to request of the device
8336 * \returns Status Code of the request, 0 is OK
8337 */
8338 ctre::phoenix::StatusCode SetControl(const controls::DynamicMotionMagicTorqueCurrentFOC &request) final;
8339
8340 /**
8341 * \brief Requests Motion Magic® Expo to target a final position using
8342 * an exponential motion profile. This dynamic request allows runtime
8343 * changes to the profile kV, kA, and (optional) Cruise Velocity.
8344 * Users can optionally provide a duty cycle feedforward.
8345 *
8346 * \details Motion Magic® Expo produces a motion profile in real-time
8347 * while attempting to honor the specified Cruise Velocity (optional)
8348 * and the mechanism kV and kA. Note that unlike the slot gains, the
8349 * Expo_kV and Expo_kA parameters are always in output units of Volts.
8350 *
8351 * Setting the Cruise Velocity to 0 will allow the profile to run to
8352 * the max possible velocity based on Expo_kV. This control mode does
8353 * not use the Acceleration or Jerk configs.
8354 *
8355 * Target position can be changed on-the-fly and Motion Magic® will do
8356 * its best to adjust the profile. This control mode is duty cycle
8357 * based, so relevant closed-loop gains will use fractional duty cycle
8358 * for the numerator: +1.0 represents full forward output.
8359 *
8360 * - DynamicMotionMagicExpoDutyCycle Parameters:
8361 * - Position: Position to drive toward in rotations.
8362 * - kV: Mechanism kV for profiling. Unlike the kV slot gain, this is always
8363 * in units of V/rps.
8364 *
8365 * This represents the amount of voltage necessary to hold a velocity.
8366 * In terms of the Motion Magic® Expo profile, a higher kV results in a
8367 * slower maximum velocity.
8368 * - kA: Mechanism kA for profiling. Unlike the kA slot gain, this is always
8369 * in units of V/rps².
8370 *
8371 * This represents the amount of voltage necessary to achieve an
8372 * acceleration. In terms of the Motion Magic® Expo profile, a higher
8373 * kA results in a slower acceleration.
8374 * - Velocity: Cruise velocity for profiling. The signage does not matter as
8375 * the device will use the absolute value for profile generation.
8376 * Setting this to 0 will allow the profile to run to the max
8377 * possible velocity based on Expo_kV.
8378 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
8379 * which increases peak power by ~15% on supported devices (see
8380 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
8381 * commutation.
8382 *
8383 * FOC improves motor performance by leveraging torque (current)
8384 * control. However, this may be inconvenient for applications
8385 * that require specifying duty cycle or voltage.
8386 * CTR-Electronics has developed a hybrid method that combines
8387 * the performances gains of FOC while still allowing
8388 * applications to provide duty cycle or voltage demand. This
8389 * not to be confused with simple sinusoidal control or phase
8390 * voltage control which lacks the performance gains.
8391 * - FeedForward: Feedforward to apply in fractional units between -1 and +1.
8392 * This is added to the output of the onboard feedforward
8393 * terms.
8394 * - Slot: Select which gains are applied by selecting the slot. Use the
8395 * configuration api to set the gain values for the selected slot
8396 * before enabling this feature. Slot must be within [0,2].
8397 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
8398 * output is zero (or within deadband). Set to
8399 * false to use the NeutralMode configuration
8400 * setting (default). This flag exists to provide
8401 * the fundamental behavior of this control when
8402 * output is zero, which is to provide 0V to the
8403 * motor.
8404 * - LimitForwardMotion: Set to true to force forward limiting. This allows
8405 * users to use other limit switch sensors connected to
8406 * robot controller. This also allows use of active
8407 * sensors that require external power.
8408 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
8409 * users to use other limit switch sensors connected to
8410 * robot controller. This also allows use of active
8411 * sensors that require external power.
8412 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
8413 * the LimitForwardMotion and LimitReverseMotion
8414 * parameters, instead allowing motion.
8415 *
8416 * This can be useful on mechanisms such as an
8417 * intake/feeder, where a limit switch stops motion
8418 * while intaking but should be ignored when feeding
8419 * to a shooter.
8420 *
8421 * The hardware limit faults and Forward/ReverseLimit
8422 * signals will still report the values of the limit
8423 * switches regardless of this parameter.
8424 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
8425 * allowing motion.
8426 *
8427 * This can be useful when calibrating the zero point
8428 * of a mechanism such as an elevator.
8429 *
8430 * The software limit faults will still report the
8431 * values of the software limits regardless of this
8432 * parameter.
8433 * - UseTimesync: Set to true to delay applying this control request until a
8434 * timesync boundary (requires Phoenix Pro and CANivore). This
8435 * eliminates the impact of nondeterministic network delays in
8436 * exchange for a larger but deterministic control latency.
8437 *
8438 * This requires setting the ControlTimesyncFreqHz config in
8439 * MotorOutputConfigs. Additionally, when this is enabled, the
8440 * UpdateFreqHz of this request should be set to 0 Hz.
8441 *
8442 * \param request Control object to request of the device
8443 * \returns Status Code of the request, 0 is OK
8444 */
8445 ctre::phoenix::StatusCode SetControl(const controls::DynamicMotionMagicExpoDutyCycle &request) final;
8446
8447 /**
8448 * \brief Requests Motion Magic® Expo to target a final position using
8449 * an exponential motion profile. This dynamic request allows runtime
8450 * changes to the profile kV, kA, and (optional) Cruise Velocity.
8451 * Users can optionally provide a voltage feedforward.
8452 *
8453 * \details Motion Magic® Expo produces a motion profile in real-time
8454 * while attempting to honor the specified Cruise Velocity (optional)
8455 * and the mechanism kV and kA. Note that unlike the slot gains, the
8456 * Expo_kV and Expo_kA parameters are always in output units of Volts.
8457 *
8458 * Setting the Cruise Velocity to 0 will allow the profile to run to
8459 * the max possible velocity based on Expo_kV. This control mode does
8460 * not use the Acceleration or Jerk configs.
8461 *
8462 * Target position can be changed on-the-fly and Motion Magic® will do
8463 * its best to adjust the profile. This control mode is
8464 * voltage-based, so relevant closed-loop gains will use Volts for the
8465 * numerator.
8466 *
8467 * - DynamicMotionMagicExpoVoltage Parameters:
8468 * - Position: Position to drive toward in rotations.
8469 * - kV: Mechanism kV for profiling. Unlike the kV slot gain, this is always
8470 * in units of V/rps.
8471 *
8472 * This represents the amount of voltage necessary to hold a velocity.
8473 * In terms of the Motion Magic® Expo profile, a higher kV results in a
8474 * slower maximum velocity.
8475 * - kA: Mechanism kA for profiling. Unlike the kA slot gain, this is always
8476 * in units of V/rps².
8477 *
8478 * This represents the amount of voltage necessary to achieve an
8479 * acceleration. In terms of the Motion Magic® Expo profile, a higher
8480 * kA results in a slower acceleration.
8481 * - Velocity: Cruise velocity for profiling. The signage does not matter as
8482 * the device will use the absolute value for profile generation.
8483 * Setting this to 0 will allow the profile to run to the max
8484 * possible velocity based on Expo_kV.
8485 * - EnableFOC: Set to true to use FOC commutation (requires Phoenix Pro),
8486 * which increases peak power by ~15% on supported devices (see
8487 * hardware#traits#SupportsFOC). Set to false to use trapezoidal
8488 * commutation.
8489 *
8490 * FOC improves motor performance by leveraging torque (current)
8491 * control. However, this may be inconvenient for applications
8492 * that require specifying duty cycle or voltage.
8493 * CTR-Electronics has developed a hybrid method that combines
8494 * the performances gains of FOC while still allowing
8495 * applications to provide duty cycle or voltage demand. This
8496 * not to be confused with simple sinusoidal control or phase
8497 * voltage control which lacks the performance gains.
8498 * - FeedForward: Feedforward to apply in volts. This is added to the output
8499 * of the onboard feedforward terms.
8500 * - Slot: Select which gains are applied by selecting the slot. Use the
8501 * configuration api to set the gain values for the selected slot
8502 * before enabling this feature. Slot must be within [0,2].
8503 * - OverrideBrakeDurNeutral: Set to true to static-brake the rotor when
8504 * output is zero (or within deadband). Set to
8505 * false to use the NeutralMode configuration
8506 * setting (default). This flag exists to provide
8507 * the fundamental behavior of this control when
8508 * output is zero, which is to provide 0V to the
8509 * motor.
8510 * - LimitForwardMotion: Set to true to force forward limiting. This allows
8511 * users to use other limit switch sensors connected to
8512 * robot controller. This also allows use of active
8513 * sensors that require external power.
8514 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
8515 * users to use other limit switch sensors connected to
8516 * robot controller. This also allows use of active
8517 * sensors that require external power.
8518 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
8519 * the LimitForwardMotion and LimitReverseMotion
8520 * parameters, instead allowing motion.
8521 *
8522 * This can be useful on mechanisms such as an
8523 * intake/feeder, where a limit switch stops motion
8524 * while intaking but should be ignored when feeding
8525 * to a shooter.
8526 *
8527 * The hardware limit faults and Forward/ReverseLimit
8528 * signals will still report the values of the limit
8529 * switches regardless of this parameter.
8530 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
8531 * allowing motion.
8532 *
8533 * This can be useful when calibrating the zero point
8534 * of a mechanism such as an elevator.
8535 *
8536 * The software limit faults will still report the
8537 * values of the software limits regardless of this
8538 * parameter.
8539 * - UseTimesync: Set to true to delay applying this control request until a
8540 * timesync boundary (requires Phoenix Pro and CANivore). This
8541 * eliminates the impact of nondeterministic network delays in
8542 * exchange for a larger but deterministic control latency.
8543 *
8544 * This requires setting the ControlTimesyncFreqHz config in
8545 * MotorOutputConfigs. Additionally, when this is enabled, the
8546 * UpdateFreqHz of this request should be set to 0 Hz.
8547 *
8548 * \param request Control object to request of the device
8549 * \returns Status Code of the request, 0 is OK
8550 */
8551 ctre::phoenix::StatusCode SetControl(const controls::DynamicMotionMagicExpoVoltage &request) final;
8552
8553 /**
8554 * \brief Requests Motion Magic® Expo to target a final position using
8555 * an exponential motion profile. This dynamic request allows runtime
8556 * changes to the profile kV, kA, and (optional) Cruise Velocity.
8557 * Users can optionally provide a torque current feedforward.
8558 *
8559 * \details Motion Magic® Expo produces a motion profile in real-time
8560 * while attempting to honor the specified Cruise Velocity (optional)
8561 * and the mechanism kV and kA. Note that unlike the slot gains, the
8562 * Expo_kV and Expo_kA parameters are always in output units of Volts.
8563 *
8564 * Setting the Cruise Velocity to 0 will allow the profile to run to
8565 * the max possible velocity based on Expo_kV. This control mode does
8566 * not use the Acceleration or Jerk configs.
8567 *
8568 * Target position can be changed on-the-fly and Motion Magic® will do
8569 * its best to adjust the profile. This control mode is based on
8570 * torque current, so relevant closed-loop gains will use Amperes for
8571 * the numerator.
8572 *
8573 * - DynamicMotionMagicExpoTorqueCurrentFOC Parameters:
8574 * - Position: Position to drive toward in rotations.
8575 * - kV: Mechanism kV for profiling. Unlike the kV slot gain, this is always
8576 * in units of V/rps.
8577 *
8578 * This represents the amount of voltage necessary to hold a velocity.
8579 * In terms of the Motion Magic® Expo profile, a higher kV results in a
8580 * slower maximum velocity.
8581 * - kA: Mechanism kA for profiling. Unlike the kA slot gain, this is always
8582 * in units of V/rps².
8583 *
8584 * This represents the amount of voltage necessary to achieve an
8585 * acceleration. In terms of the Motion Magic® Expo profile, a higher
8586 * kA results in a slower acceleration.
8587 * - Velocity: Cruise velocity for profiling. The signage does not matter as
8588 * the device will use the absolute value for profile generation.
8589 * Setting this to 0 will allow the profile to run to the max
8590 * possible velocity based on Expo_kV.
8591 * - FeedForward: Feedforward to apply in torque current in Amperes. This is
8592 * added to the output of the onboard feedforward terms.
8593 *
8594 * User can use motor's kT to scale Newton-meter to Amperes.
8595 * - Slot: Select which gains are applied by selecting the slot. Use the
8596 * configuration api to set the gain values for the selected slot
8597 * before enabling this feature. Slot must be within [0,2].
8598 * - OverrideCoastDurNeutral: Set to true to coast the rotor when output is
8599 * zero (or within deadband). Set to false to use
8600 * the NeutralMode configuration setting (default).
8601 * This flag exists to provide the fundamental
8602 * behavior of this control when output is zero,
8603 * which is to provide 0A (zero torque).
8604 * - LimitForwardMotion: Set to true to force forward limiting. This allows
8605 * users to use other limit switch sensors connected to
8606 * robot controller. This also allows use of active
8607 * sensors that require external power.
8608 * - LimitReverseMotion: Set to true to force reverse limiting. This allows
8609 * users to use other limit switch sensors connected to
8610 * robot controller. This also allows use of active
8611 * sensors that require external power.
8612 * - IgnoreHardwareLimits: Set to true to ignore hardware limit switches and
8613 * the LimitForwardMotion and LimitReverseMotion
8614 * parameters, instead allowing motion.
8615 *
8616 * This can be useful on mechanisms such as an
8617 * intake/feeder, where a limit switch stops motion
8618 * while intaking but should be ignored when feeding
8619 * to a shooter.
8620 *
8621 * The hardware limit faults and Forward/ReverseLimit
8622 * signals will still report the values of the limit
8623 * switches regardless of this parameter.
8624 * - IgnoreSoftwareLimits: Set to true to ignore software limits, instead
8625 * allowing motion.
8626 *
8627 * This can be useful when calibrating the zero point
8628 * of a mechanism such as an elevator.
8629 *
8630 * The software limit faults will still report the
8631 * values of the software limits regardless of this
8632 * parameter.
8633 * - UseTimesync: Set to true to delay applying this control request until a
8634 * timesync boundary (requires Phoenix Pro and CANivore). This
8635 * eliminates the impact of nondeterministic network delays in
8636 * exchange for a larger but deterministic control latency.
8637 *
8638 * This requires setting the ControlTimesyncFreqHz config in
8639 * MotorOutputConfigs. Additionally, when this is enabled, the
8640 * UpdateFreqHz of this request should be set to 0 Hz.
8641 *
8642 * \param request Control object to request of the device
8643 * \returns Status Code of the request, 0 is OK
8644 */
8645 ctre::phoenix::StatusCode SetControl(const controls::DynamicMotionMagicExpoTorqueCurrentFOC &request) final;
8646
8647 /**
8648 * \brief Differential control with duty cycle average target and
8649 * position difference target.
8650 *
8651 * - Diff_DutyCycleOut_Position Parameters:
8652 * - AverageRequest: Average DutyCycleOut request of the mechanism.
8653 * - DifferentialRequest: Differential PositionDutyCycle request of the
8654 * mechanism.
8655 *
8656 * \param request Control object to request of the device
8657 * \returns Status Code of the request, 0 is OK
8658 */
8659 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_DutyCycleOut_Position &request) final;
8660
8661 /**
8662 * \brief Differential control with position average target and
8663 * position difference target using duty cycle control.
8664 *
8665 * - Diff_PositionDutyCycle_Position Parameters:
8666 * - AverageRequest: Average PositionDutyCycle request of the mechanism.
8667 * - DifferentialRequest: Differential PositionDutyCycle request of the
8668 * mechanism.
8669 *
8670 * \param request Control object to request of the device
8671 * \returns Status Code of the request, 0 is OK
8672 */
8673 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_PositionDutyCycle_Position &request) final;
8674
8675 /**
8676 * \brief Differential control with velocity average target and
8677 * position difference target using duty cycle control.
8678 *
8679 * - Diff_VelocityDutyCycle_Position Parameters:
8680 * - AverageRequest: Average VelocityDutyCYcle request of the mechanism.
8681 * - DifferentialRequest: Differential PositionDutyCycle request of the
8682 * mechanism.
8683 *
8684 * \param request Control object to request of the device
8685 * \returns Status Code of the request, 0 is OK
8686 */
8687 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VelocityDutyCycle_Position &request) final;
8688
8689 /**
8690 * \brief Differential control with Motion Magic® average target and
8691 * position difference target using duty cycle control.
8692 *
8693 * - Diff_MotionMagicDutyCycle_Position Parameters:
8694 * - AverageRequest: Average MotionMagicDutyCycle request of the mechanism.
8695 * - DifferentialRequest: Differential PositionDutyCycle request of the
8696 * mechanism.
8697 *
8698 * \param request Control object to request of the device
8699 * \returns Status Code of the request, 0 is OK
8700 */
8701 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicDutyCycle_Position &request) final;
8702
8703 /**
8704 * \brief Differential control with Motion Magic® Expo average target
8705 * and position difference target using duty cycle control.
8706 *
8707 * - Diff_MotionMagicExpoDutyCycle_Position Parameters:
8708 * - AverageRequest: Average MotionMagicExpoDutyCycle request of the
8709 * mechanism.
8710 * - DifferentialRequest: Differential PositionDutyCycle request of the
8711 * mechanism.
8712 *
8713 * \param request Control object to request of the device
8714 * \returns Status Code of the request, 0 is OK
8715 */
8716 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicExpoDutyCycle_Position &request) final;
8717
8718 /**
8719 * \brief Differential control with Motion Magic® Velocity average
8720 * target and position difference target using duty cycle control.
8721 *
8722 * - Diff_MotionMagicVelocityDutyCycle_Position Parameters:
8723 * - AverageRequest: Average MotionMagicVelocityDutyCycle request of the
8724 * mechanism.
8725 * - DifferentialRequest: Differential PositionDutyCycle request of the
8726 * mechanism.
8727 *
8728 * \param request Control object to request of the device
8729 * \returns Status Code of the request, 0 is OK
8730 */
8731 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVelocityDutyCycle_Position &request) final;
8732
8733 /**
8734 * \brief Differential control with duty cycle average target and
8735 * velocity difference target.
8736 *
8737 * - Diff_DutyCycleOut_Velocity Parameters:
8738 * - AverageRequest: Average DutyCycleOut request of the mechanism.
8739 * - DifferentialRequest: Differential VelocityDutyCycle request of the
8740 * mechanism.
8741 *
8742 * \param request Control object to request of the device
8743 * \returns Status Code of the request, 0 is OK
8744 */
8745 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_DutyCycleOut_Velocity &request) final;
8746
8747 /**
8748 * \brief Differential control with position average target and
8749 * velocity difference target using duty cycle control.
8750 *
8751 * - Diff_PositionDutyCycle_Velocity Parameters:
8752 * - AverageRequest: Average PositionDutyCycle request of the mechanism.
8753 * - DifferentialRequest: Differential VelocityDutyCycle request of the
8754 * mechanism.
8755 *
8756 * \param request Control object to request of the device
8757 * \returns Status Code of the request, 0 is OK
8758 */
8759 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_PositionDutyCycle_Velocity &request) final;
8760
8761 /**
8762 * \brief Differential control with velocity average target and
8763 * velocity difference target using duty cycle control.
8764 *
8765 * - Diff_VelocityDutyCycle_Velocity Parameters:
8766 * - AverageRequest: Average VelocityDutyCycle request of the mechanism.
8767 * - DifferentialRequest: Differential VelocityDutyCycle request of the
8768 * mechanism.
8769 *
8770 * \param request Control object to request of the device
8771 * \returns Status Code of the request, 0 is OK
8772 */
8773 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VelocityDutyCycle_Velocity &request) final;
8774
8775 /**
8776 * \brief Differential control with Motion Magic® average target and
8777 * velocity difference target using duty cycle control.
8778 *
8779 * - Diff_MotionMagicDutyCycle_Velocity Parameters:
8780 * - AverageRequest: Average MotionMagicDutyCycle request of the mechanism.
8781 * - DifferentialRequest: Differential VelocityDutyCycle request of the
8782 * mechanism.
8783 *
8784 * \param request Control object to request of the device
8785 * \returns Status Code of the request, 0 is OK
8786 */
8787 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicDutyCycle_Velocity &request) final;
8788
8789 /**
8790 * \brief Differential control with Motion Magic® Expo average target
8791 * and velocity difference target using duty cycle control.
8792 *
8793 * - Diff_MotionMagicExpoDutyCycle_Velocity Parameters:
8794 * - AverageRequest: Average MotionMagicExpoDutyCycle request of the
8795 * mechanism.
8796 * - DifferentialRequest: Differential VelocityDutyCycle request of the
8797 * mechanism.
8798 *
8799 * \param request Control object to request of the device
8800 * \returns Status Code of the request, 0 is OK
8801 */
8802 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicExpoDutyCycle_Velocity &request) final;
8803
8804 /**
8805 * \brief Differential control with Motion Magic® Velocity average
8806 * target and velocity difference target using duty cycle control.
8807 *
8808 * - Diff_MotionMagicVelocityDutyCycle_Velocity Parameters:
8809 * - AverageRequest: Average MotionMagicVelocityDutyCycle request of the
8810 * mechanism.
8811 * - DifferentialRequest: Differential VelocityDutyCycle request of the
8812 * mechanism.
8813 *
8814 * \param request Control object to request of the device
8815 * \returns Status Code of the request, 0 is OK
8816 */
8817 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVelocityDutyCycle_Velocity &request) final;
8818
8819 /**
8820 * \brief Differential control with duty cycle average target and duty
8821 * cycle difference target.
8822 *
8823 * - Diff_DutyCycleOut_Open Parameters:
8824 * - AverageRequest: Average DutyCycleOut request of the mechanism.
8825 * - DifferentialRequest: Differential DutyCycleOut request of the mechanism.
8826 *
8827 * \param request Control object to request of the device
8828 * \returns Status Code of the request, 0 is OK
8829 */
8830 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_DutyCycleOut_Open &request) final;
8831
8832 /**
8833 * \brief Differential control with position average target and duty
8834 * cycle difference target.
8835 *
8836 * - Diff_PositionDutyCycle_Open Parameters:
8837 * - AverageRequest: Average PositionDutyCycle request of the mechanism.
8838 * - DifferentialRequest: Differential DutyCycleOut request of the mechanism.
8839 *
8840 * \param request Control object to request of the device
8841 * \returns Status Code of the request, 0 is OK
8842 */
8843 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_PositionDutyCycle_Open &request) final;
8844
8845 /**
8846 * \brief Differential control with velocity average target and duty
8847 * cycle difference target.
8848 *
8849 * - Diff_VelocityDutyCycle_Open Parameters:
8850 * - AverageRequest: Average VelocityDutyCYcle request of the mechanism.
8851 * - DifferentialRequest: Differential DutyCycleOut request of the mechanism.
8852 *
8853 * \param request Control object to request of the device
8854 * \returns Status Code of the request, 0 is OK
8855 */
8856 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VelocityDutyCycle_Open &request) final;
8857
8858 /**
8859 * \brief Differential control with Motion Magic® average target and
8860 * duty cycle difference target.
8861 *
8862 * - Diff_MotionMagicDutyCycle_Open Parameters:
8863 * - AverageRequest: Average MotionMagicDutyCycle request of the mechanism.
8864 * - DifferentialRequest: Differential DutyCycleOut request of the mechanism.
8865 *
8866 * \param request Control object to request of the device
8867 * \returns Status Code of the request, 0 is OK
8868 */
8869 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicDutyCycle_Open &request) final;
8870
8871 /**
8872 * \brief Differential control with Motion Magic® Expo average target
8873 * and duty cycle difference target.
8874 *
8875 * - Diff_MotionMagicExpoDutyCycle_Open Parameters:
8876 * - AverageRequest: Average MotionMagicExpoDutyCycle request of the
8877 * mechanism.
8878 * - DifferentialRequest: Differential DutyCycleOut request of the mechanism.
8879 *
8880 * \param request Control object to request of the device
8881 * \returns Status Code of the request, 0 is OK
8882 */
8883 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicExpoDutyCycle_Open &request) final;
8884
8885 /**
8886 * \brief Differential control with Motion Magic® Velocity average
8887 * target and duty cycle difference target.
8888 *
8889 * - Diff_MotionMagicVelocityDutyCycle_Open Parameters:
8890 * - AverageRequest: Average MotionMagicVelocityDutyCycle request of the
8891 * mechanism.
8892 * - DifferentialRequest: Differential DutyCycleOut request of the mechanism.
8893 *
8894 * \param request Control object to request of the device
8895 * \returns Status Code of the request, 0 is OK
8896 */
8897 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVelocityDutyCycle_Open &request) final;
8898
8899 /**
8900 * \brief Differential control with voltage average target and
8901 * position difference target.
8902 *
8903 * - Diff_VoltageOut_Position Parameters:
8904 * - AverageRequest: Average VoltageOut request of the mechanism.
8905 * - DifferentialRequest: Differential PositionVoltage request of the
8906 * mechanism.
8907 *
8908 * \param request Control object to request of the device
8909 * \returns Status Code of the request, 0 is OK
8910 */
8911 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VoltageOut_Position &request) final;
8912
8913 /**
8914 * \brief Differential control with position average target and
8915 * position difference target using voltage control.
8916 *
8917 * - Diff_PositionVoltage_Position Parameters:
8918 * - AverageRequest: Average PositionVoltage request of the mechanism.
8919 * - DifferentialRequest: Differential PositionVoltage request of the
8920 * mechanism.
8921 *
8922 * \param request Control object to request of the device
8923 * \returns Status Code of the request, 0 is OK
8924 */
8925 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_PositionVoltage_Position &request) final;
8926
8927 /**
8928 * \brief Differential control with velocity average target and
8929 * position difference target using voltage control.
8930 *
8931 * - Diff_VelocityVoltage_Position Parameters:
8932 * - AverageRequest: Average VelocityVoltage request of the mechanism.
8933 * - DifferentialRequest: Differential PositionVoltage request of the
8934 * mechanism.
8935 *
8936 * \param request Control object to request of the device
8937 * \returns Status Code of the request, 0 is OK
8938 */
8939 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VelocityVoltage_Position &request) final;
8940
8941 /**
8942 * \brief Differential control with Motion Magic® average target and
8943 * position difference target using voltage control.
8944 *
8945 * - Diff_MotionMagicVoltage_Position Parameters:
8946 * - AverageRequest: Average MotionMagicVoltage request of the mechanism.
8947 * - DifferentialRequest: Differential PositionVoltage request of the
8948 * mechanism.
8949 *
8950 * \param request Control object to request of the device
8951 * \returns Status Code of the request, 0 is OK
8952 */
8953 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVoltage_Position &request) final;
8954
8955 /**
8956 * \brief Differential control with Motion Magic® Expo average target
8957 * and position difference target using voltage control.
8958 *
8959 * - Diff_MotionMagicExpoVoltage_Position Parameters:
8960 * - AverageRequest: Average MotionMagicExpoVoltage request of the mechanism.
8961 * - DifferentialRequest: Differential PositionVoltage request of the
8962 * mechanism.
8963 *
8964 * \param request Control object to request of the device
8965 * \returns Status Code of the request, 0 is OK
8966 */
8967 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicExpoVoltage_Position &request) final;
8968
8969 /**
8970 * \brief Differential control with Motion Magic® Velocity average
8971 * target and position difference target using voltage control.
8972 *
8973 * - Diff_MotionMagicVelocityVoltage_Position Parameters:
8974 * - AverageRequest: Average MotionMagicVelocityVoltage request of the
8975 * mechanism.
8976 * - DifferentialRequest: Differential PositionVoltage request of the
8977 * mechanism.
8978 *
8979 * \param request Control object to request of the device
8980 * \returns Status Code of the request, 0 is OK
8981 */
8982 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVelocityVoltage_Position &request) final;
8983
8984 /**
8985 * \brief Differential control with voltage average target and
8986 * velocity difference target.
8987 *
8988 * - Diff_VoltageOut_Velocity Parameters:
8989 * - AverageRequest: Average VoltageOut request of the mechanism.
8990 * - DifferentialRequest: Differential VelocityVoltage request of the
8991 * mechanism.
8992 *
8993 * \param request Control object to request of the device
8994 * \returns Status Code of the request, 0 is OK
8995 */
8996 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VoltageOut_Velocity &request) final;
8997
8998 /**
8999 * \brief Differential control with position average target and
9000 * velocity difference target using voltage control.
9001 *
9002 * - Diff_PositionVoltage_Velocity Parameters:
9003 * - AverageRequest: Average PositionVoltage request of the mechanism.
9004 * - DifferentialRequest: Differential VelocityVoltage request of the
9005 * mechanism.
9006 *
9007 * \param request Control object to request of the device
9008 * \returns Status Code of the request, 0 is OK
9009 */
9010 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_PositionVoltage_Velocity &request) final;
9011
9012 /**
9013 * \brief Differential control with velocity average target and
9014 * velocity difference target using voltage control.
9015 *
9016 * - Diff_VelocityVoltage_Velocity Parameters:
9017 * - AverageRequest: Average VelocityVoltage request of the mechanism.
9018 * - DifferentialRequest: Differential VelocityVoltage request of the
9019 * mechanism.
9020 *
9021 * \param request Control object to request of the device
9022 * \returns Status Code of the request, 0 is OK
9023 */
9024 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VelocityVoltage_Velocity &request) final;
9025
9026 /**
9027 * \brief Differential control with Motion Magic® average target and
9028 * velocity difference target using voltage control.
9029 *
9030 * - Diff_MotionMagicVoltage_Velocity Parameters:
9031 * - AverageRequest: Average MotionMagicVoltage request of the mechanism.
9032 * - DifferentialRequest: Differential VelocityVoltage request of the
9033 * mechanism.
9034 *
9035 * \param request Control object to request of the device
9036 * \returns Status Code of the request, 0 is OK
9037 */
9038 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVoltage_Velocity &request) final;
9039
9040 /**
9041 * \brief Differential control with Motion Magic® Expo average target
9042 * and velocity difference target using voltage control.
9043 *
9044 * - Diff_MotionMagicExpoVoltage_Velocity Parameters:
9045 * - AverageRequest: Average MotionMagicExpoVoltage request of the mechanism.
9046 * - DifferentialRequest: Differential VelocityVoltage request of the
9047 * mechanism.
9048 *
9049 * \param request Control object to request of the device
9050 * \returns Status Code of the request, 0 is OK
9051 */
9052 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicExpoVoltage_Velocity &request) final;
9053
9054 /**
9055 * \brief Differential control with Motion Magic® Velocity average
9056 * target and velocity difference target using voltage control.
9057 *
9058 * - Diff_MotionMagicVelocityVoltage_Velocity Parameters:
9059 * - AverageRequest: Average MotionMagicVelocityVoltage request of the
9060 * mechanism.
9061 * - DifferentialRequest: Differential VelocityVoltage request of the
9062 * mechanism.
9063 *
9064 * \param request Control object to request of the device
9065 * \returns Status Code of the request, 0 is OK
9066 */
9067 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVelocityVoltage_Velocity &request) final;
9068
9069 /**
9070 * \brief Differential control with voltage average target and voltage
9071 * difference target.
9072 *
9073 * - Diff_VoltageOut_Open Parameters:
9074 * - AverageRequest: Average VoltageOut request of the mechanism.
9075 * - DifferentialRequest: Differential VoltageOut request of the mechanism.
9076 *
9077 * \param request Control object to request of the device
9078 * \returns Status Code of the request, 0 is OK
9079 */
9080 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VoltageOut_Open &request) final;
9081
9082 /**
9083 * \brief Differential control with position average target and
9084 * voltage difference target.
9085 *
9086 * - Diff_PositionVoltage_Open Parameters:
9087 * - AverageRequest: Average PositionVoltage request of the mechanism.
9088 * - DifferentialRequest: Differential VoltageOut request of the mechanism.
9089 *
9090 * \param request Control object to request of the device
9091 * \returns Status Code of the request, 0 is OK
9092 */
9093 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_PositionVoltage_Open &request) final;
9094
9095 /**
9096 * \brief Differential control with velocity average target and
9097 * voltage difference target.
9098 *
9099 * - Diff_VelocityVoltage_Open Parameters:
9100 * - AverageRequest: Average VelocityVoltage request of the mechanism.
9101 * - DifferentialRequest: Differential VoltageOut request of the mechanism.
9102 *
9103 * \param request Control object to request of the device
9104 * \returns Status Code of the request, 0 is OK
9105 */
9106 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VelocityVoltage_Open &request) final;
9107
9108 /**
9109 * \brief Differential control with Motion Magic® average target and
9110 * voltage difference target.
9111 *
9112 * - Diff_MotionMagicVoltage_Open Parameters:
9113 * - AverageRequest: Average MotionMagicVoltage request of the mechanism.
9114 * - DifferentialRequest: Differential VoltageOut request of the mechanism.
9115 *
9116 * \param request Control object to request of the device
9117 * \returns Status Code of the request, 0 is OK
9118 */
9119 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVoltage_Open &request) final;
9120
9121 /**
9122 * \brief Differential control with Motion Magic® Expo average target
9123 * and voltage difference target.
9124 *
9125 * - Diff_MotionMagicExpoVoltage_Open Parameters:
9126 * - AverageRequest: Average MotionMagicExpoVoltage request of the mechanism.
9127 * - DifferentialRequest: Differential VoltageOut request of the mechanism.
9128 *
9129 * \param request Control object to request of the device
9130 * \returns Status Code of the request, 0 is OK
9131 */
9132 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicExpoVoltage_Open &request) final;
9133
9134 /**
9135 * \brief Differential control with Motion Magic® Velocity average
9136 * target and voltage difference target.
9137 *
9138 * - Diff_MotionMagicVelocityVoltage_Open Parameters:
9139 * - AverageRequest: Average MotionMagicVelocityVoltage request of the
9140 * mechanism.
9141 * - DifferentialRequest: Differential VoltageOut request of the mechanism.
9142 *
9143 * \param request Control object to request of the device
9144 * \returns Status Code of the request, 0 is OK
9145 */
9146 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVelocityVoltage_Open &request) final;
9147
9148 /**
9149 * \brief Differential control with torque current average target and
9150 * position difference target.
9151 *
9152 * - Diff_TorqueCurrentFOC_Position Parameters:
9153 * - AverageRequest: Average TorqueCurrentFOC request of the mechanism.
9154 * - DifferentialRequest: Differential PositionTorqueCurrentFOC request of the
9155 * mechanism.
9156 *
9157 * \param request Control object to request of the device
9158 * \returns Status Code of the request, 0 is OK
9159 */
9160 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_TorqueCurrentFOC_Position &request) final;
9161
9162 /**
9163 * \brief Differential control with position average target and
9164 * position difference target using torque current control.
9165 *
9166 * - Diff_PositionTorqueCurrentFOC_Position Parameters:
9167 * - AverageRequest: Average PositionTorqueCurrentFOC request of the
9168 * mechanism.
9169 * - DifferentialRequest: Differential PositionTorqueCurrentFOC request of the
9170 * mechanism.
9171 *
9172 * \param request Control object to request of the device
9173 * \returns Status Code of the request, 0 is OK
9174 */
9175 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_PositionTorqueCurrentFOC_Position &request) final;
9176
9177 /**
9178 * \brief Differential control with velocity average target and
9179 * position difference target using torque current control.
9180 *
9181 * - Diff_VelocityTorqueCurrentFOC_Position Parameters:
9182 * - AverageRequest: Average VelocityTorqueCurrentFOC request of the
9183 * mechanism.
9184 * - DifferentialRequest: Differential PositionTorqueCurrentFOC request of the
9185 * mechanism.
9186 *
9187 * \param request Control object to request of the device
9188 * \returns Status Code of the request, 0 is OK
9189 */
9190 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VelocityTorqueCurrentFOC_Position &request) final;
9191
9192 /**
9193 * \brief Differential control with Motion Magic® average target and
9194 * position difference target using torque current control.
9195 *
9196 * - Diff_MotionMagicTorqueCurrentFOC_Position Parameters:
9197 * - AverageRequest: Average MotionMagicTorqueCurrentFOC request of the
9198 * mechanism.
9199 * - DifferentialRequest: Differential PositionTorqueCurrentFOC request of the
9200 * mechanism.
9201 *
9202 * \param request Control object to request of the device
9203 * \returns Status Code of the request, 0 is OK
9204 */
9205 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicTorqueCurrentFOC_Position &request) final;
9206
9207 /**
9208 * \brief Differential control with Motion Magic® Expo average target
9209 * and position difference target using torque current control.
9210 *
9211 * - Diff_MotionMagicExpoTorqueCurrentFOC_Position Parameters:
9212 * - AverageRequest: Average MotionMagicExpoTorqueCurrentFOC request of the
9213 * mechanism.
9214 * - DifferentialRequest: Differential PositionTorqueCurrentFOC request of the
9215 * mechanism.
9216 *
9217 * \param request Control object to request of the device
9218 * \returns Status Code of the request, 0 is OK
9219 */
9220 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicExpoTorqueCurrentFOC_Position &request) final;
9221
9222 /**
9223 * \brief Differential control with Motion Magic® Velocity average
9224 * target and position difference target using torque current control.
9225 *
9226 * - Diff_MotionMagicVelocityTorqueCurrentFOC_Position Parameters:
9227 * - AverageRequest: Average MotionMagicVelocityTorqueCurrentFOC request of
9228 * the mechanism.
9229 * - DifferentialRequest: Differential PositionTorqueCurrentFOC request of the
9230 * mechanism.
9231 *
9232 * \param request Control object to request of the device
9233 * \returns Status Code of the request, 0 is OK
9234 */
9235 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVelocityTorqueCurrentFOC_Position &request) final;
9236
9237 /**
9238 * \brief Differential control with torque current average target and
9239 * velocity difference target.
9240 *
9241 * - Diff_TorqueCurrentFOC_Velocity Parameters:
9242 * - AverageRequest: Average TorqueCurrentFOC request of the mechanism.
9243 * - DifferentialRequest: Differential VelocityTorqueCurrentFOC request of the
9244 * mechanism.
9245 *
9246 * \param request Control object to request of the device
9247 * \returns Status Code of the request, 0 is OK
9248 */
9249 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_TorqueCurrentFOC_Velocity &request) final;
9250
9251 /**
9252 * \brief Differential control with position average target and
9253 * velocity difference target using torque current control.
9254 *
9255 * - Diff_PositionTorqueCurrentFOC_Velocity Parameters:
9256 * - AverageRequest: Average PositionTorqueCurrentFOC request of the
9257 * mechanism.
9258 * - DifferentialRequest: Differential VelocityTorqueCurrentFOC request of the
9259 * mechanism.
9260 *
9261 * \param request Control object to request of the device
9262 * \returns Status Code of the request, 0 is OK
9263 */
9264 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_PositionTorqueCurrentFOC_Velocity &request) final;
9265
9266 /**
9267 * \brief Differential control with velocity average target and
9268 * velocity difference target using torque current control.
9269 *
9270 * - Diff_VelocityTorqueCurrentFOC_Velocity Parameters:
9271 * - AverageRequest: Average VelocityTorqueCurrentFOC request of the
9272 * mechanism.
9273 * - DifferentialRequest: Differential VelocityTorqueCurrentFOC request of the
9274 * mechanism.
9275 *
9276 * \param request Control object to request of the device
9277 * \returns Status Code of the request, 0 is OK
9278 */
9279 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VelocityTorqueCurrentFOC_Velocity &request) final;
9280
9281 /**
9282 * \brief Differential control with Motion Magic® average target and
9283 * velocity difference target using torque current control.
9284 *
9285 * - Diff_MotionMagicTorqueCurrentFOC_Velocity Parameters:
9286 * - AverageRequest: Average MotionMagicTorqueCurrentFOC request of the
9287 * mechanism.
9288 * - DifferentialRequest: Differential VelocityTorqueCurrentFOC request of the
9289 * mechanism.
9290 *
9291 * \param request Control object to request of the device
9292 * \returns Status Code of the request, 0 is OK
9293 */
9294 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicTorqueCurrentFOC_Velocity &request) final;
9295
9296 /**
9297 * \brief Differential control with Motion Magic® Expo average target
9298 * and velocity difference target using torque current control.
9299 *
9300 * - Diff_MotionMagicExpoTorqueCurrentFOC_Velocity Parameters:
9301 * - AverageRequest: Average MotionMagicExpoTorqueCurrentFOC request of the
9302 * mechanism.
9303 * - DifferentialRequest: Differential VelocityTorqueCurrentFOC request of the
9304 * mechanism.
9305 *
9306 * \param request Control object to request of the device
9307 * \returns Status Code of the request, 0 is OK
9308 */
9309 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicExpoTorqueCurrentFOC_Velocity &request) final;
9310
9311 /**
9312 * \brief Differential control with Motion Magic® Velocity average
9313 * target and velocity difference target using torque current control.
9314 *
9315 * - Diff_MotionMagicVelocityTorqueCurrentFOC_Velocity Parameters:
9316 * - AverageRequest: Average MotionMagicVelocityTorqueCurrentFOC request of
9317 * the mechanism.
9318 * - DifferentialRequest: Differential VelocityTorqueCurrentFOC request of the
9319 * mechanism.
9320 *
9321 * \param request Control object to request of the device
9322 * \returns Status Code of the request, 0 is OK
9323 */
9324 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVelocityTorqueCurrentFOC_Velocity &request) final;
9325
9326 /**
9327 * \brief Differential control with torque current average target and
9328 * torque current difference target.
9329 *
9330 * - Diff_TorqueCurrentFOC_Open Parameters:
9331 * - AverageRequest: Average TorqueCurrentFOC request of the mechanism.
9332 * - DifferentialRequest: Differential TorqueCurrentFOC request of the
9333 * mechanism.
9334 *
9335 * \param request Control object to request of the device
9336 * \returns Status Code of the request, 0 is OK
9337 */
9338 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_TorqueCurrentFOC_Open &request) final;
9339
9340 /**
9341 * \brief Differential control with position average target and torque
9342 * current difference target.
9343 *
9344 * - Diff_PositionTorqueCurrentFOC_Open Parameters:
9345 * - AverageRequest: Average PositionTorqueCurrentFOC request of the
9346 * mechanism.
9347 * - DifferentialRequest: Differential TorqueCurrentFOC request of the
9348 * mechanism.
9349 *
9350 * \param request Control object to request of the device
9351 * \returns Status Code of the request, 0 is OK
9352 */
9353 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_PositionTorqueCurrentFOC_Open &request) final;
9354
9355 /**
9356 * \brief Differential control with velocity average target and torque
9357 * current difference target.
9358 *
9359 * - Diff_VelocityTorqueCurrentFOC_Open Parameters:
9360 * - AverageRequest: Average VelocityTorqueCurrentFOC request of the
9361 * mechanism.
9362 * - DifferentialRequest: Differential TorqueCurrentFOC request of the
9363 * mechanism.
9364 *
9365 * \param request Control object to request of the device
9366 * \returns Status Code of the request, 0 is OK
9367 */
9368 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_VelocityTorqueCurrentFOC_Open &request) final;
9369
9370 /**
9371 * \brief Differential control with Motion Magic® average target and
9372 * torque current difference target.
9373 *
9374 * - Diff_MotionMagicTorqueCurrentFOC_Open Parameters:
9375 * - AverageRequest: Average MotionMagicTorqueCurrentFOC request of the
9376 * mechanism.
9377 * - DifferentialRequest: Differential TorqueCurrentFOC request of the
9378 * mechanism.
9379 *
9380 * \param request Control object to request of the device
9381 * \returns Status Code of the request, 0 is OK
9382 */
9383 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicTorqueCurrentFOC_Open &request) final;
9384
9385 /**
9386 * \brief Differential control with Motion Magic® Expo average target
9387 * and torque current difference target.
9388 *
9389 * - Diff_MotionMagicExpoTorqueCurrentFOC_Open Parameters:
9390 * - AverageRequest: Average MotionMagicExpoTorqueCurrentFOC request of the
9391 * mechanism.
9392 * - DifferentialRequest: Differential TorqueCurrentFOC request of the
9393 * mechanism.
9394 *
9395 * \param request Control object to request of the device
9396 * \returns Status Code of the request, 0 is OK
9397 */
9398 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicExpoTorqueCurrentFOC_Open &request) final;
9399
9400 /**
9401 * \brief Differential control with Motion Magic® Velocity average
9402 * target and torque current difference target.
9403 *
9404 * - Diff_MotionMagicVelocityTorqueCurrentFOC_Open Parameters:
9405 * - AverageRequest: Average MotionMagicVelocityTorqueCurrentFOC request of
9406 * the mechanism.
9407 * - DifferentialRequest: Differential TorqueCurrentFOC request of the
9408 * mechanism.
9409 *
9410 * \param request Control object to request of the device
9411 * \returns Status Code of the request, 0 is OK
9412 */
9413 ctre::phoenix::StatusCode SetControl(const controls::compound::Diff_MotionMagicVelocityTorqueCurrentFOC_Open &request) final;
9414
9415 /**
9416 * \brief Control device with generic control request object. User must make
9417 * sure the specified object is castable to a valid control request,
9418 * otherwise this function will fail at run-time and return the NotSupported
9419 * StatusCode
9420 *
9421 * \param request Control object to request of the device
9422 * \returns Status Code of the request, 0 is OK
9423 */
9424 ctre::phoenix::StatusCode SetControl(controls::ControlRequest const &request) final;
9425
9426
9427 /**
9428 * \brief Sets the mechanism position of the device in mechanism
9429 * rotations.
9430 *
9431 * \param newValue Value to set to. Units are in rotations.
9432 * \param timeoutSeconds Maximum time to wait up to in seconds.
9433 * \returns StatusCode of the set command
9434 */
9435 ctre::phoenix::StatusCode SetPosition(units::angle::turn_t newValue, units::time::second_t timeoutSeconds) final
9436 {
9437 return GetConfigurator().SetPosition(newValue, timeoutSeconds);
9438 }
9439 /**
9440 * \brief Sets the mechanism position of the device in mechanism
9441 * rotations.
9442 *
9443 * This will wait up to 0.100 seconds (100ms) by default.
9444 *
9445 * \param newValue Value to set to. Units are in rotations.
9446 * \returns StatusCode of the set command
9447 */
9448 ctre::phoenix::StatusCode SetPosition(units::angle::turn_t newValue) final
9449 {
9450 return SetPosition(newValue, 0.100_s);
9451 }
9452
9453 /**
9454 * \brief Clear the sticky faults in the device.
9455 *
9456 * \details This typically has no impact on the device functionality.
9457 * Instead, it just clears telemetry faults that are accessible via
9458 * API and Tuner Self-Test.
9459 *
9460 * \param timeoutSeconds Maximum time to wait up to in seconds.
9461 * \returns StatusCode of the set command
9462 */
9463 ctre::phoenix::StatusCode ClearStickyFaults(units::time::second_t timeoutSeconds) final
9464 {
9465 return GetConfigurator().ClearStickyFaults(timeoutSeconds);
9466 }
9467 /**
9468 * \brief Clear the sticky faults in the device.
9469 *
9470 * \details This typically has no impact on the device functionality.
9471 * Instead, it just clears telemetry faults that are accessible via
9472 * API and Tuner Self-Test.
9473 *
9474 * This will wait up to 0.100 seconds (100ms) by default.
9475 *
9476 * \returns StatusCode of the set command
9477 */
9479 {
9480 return ClearStickyFaults(0.100_s);
9481 }
9482
9483 /**
9484 * \brief Clear sticky fault: Hardware fault occurred
9485 *
9486 * \param timeoutSeconds Maximum time to wait up to in seconds.
9487 * \returns StatusCode of the set command
9488 */
9489 ctre::phoenix::StatusCode ClearStickyFault_Hardware(units::time::second_t timeoutSeconds) final
9490 {
9491 return GetConfigurator().ClearStickyFault_Hardware(timeoutSeconds);
9492 }
9493 /**
9494 * \brief Clear sticky fault: Hardware fault occurred
9495 *
9496 * This will wait up to 0.100 seconds (100ms) by default.
9497 *
9498 * \returns StatusCode of the set command
9499 */
9501 {
9502 return ClearStickyFault_Hardware(0.100_s);
9503 }
9504
9505 /**
9506 * \brief Clear sticky fault: Processor temperature exceeded limit
9507 *
9508 * \param timeoutSeconds Maximum time to wait up to in seconds.
9509 * \returns StatusCode of the set command
9510 */
9511 ctre::phoenix::StatusCode ClearStickyFault_ProcTemp(units::time::second_t timeoutSeconds) final
9512 {
9513 return GetConfigurator().ClearStickyFault_ProcTemp(timeoutSeconds);
9514 }
9515 /**
9516 * \brief Clear sticky fault: Processor temperature exceeded limit
9517 *
9518 * This will wait up to 0.100 seconds (100ms) by default.
9519 *
9520 * \returns StatusCode of the set command
9521 */
9523 {
9524 return ClearStickyFault_ProcTemp(0.100_s);
9525 }
9526
9527 /**
9528 * \brief Clear sticky fault: Device temperature exceeded limit
9529 *
9530 * \param timeoutSeconds Maximum time to wait up to in seconds.
9531 * \returns StatusCode of the set command
9532 */
9533 ctre::phoenix::StatusCode ClearStickyFault_DeviceTemp(units::time::second_t timeoutSeconds) final
9534 {
9535 return GetConfigurator().ClearStickyFault_DeviceTemp(timeoutSeconds);
9536 }
9537 /**
9538 * \brief Clear sticky fault: Device temperature exceeded limit
9539 *
9540 * This will wait up to 0.100 seconds (100ms) by default.
9541 *
9542 * \returns StatusCode of the set command
9543 */
9545 {
9546 return ClearStickyFault_DeviceTemp(0.100_s);
9547 }
9548
9549 /**
9550 * \brief Clear sticky fault: Device supply voltage dropped to near
9551 * brownout levels
9552 *
9553 * \param timeoutSeconds Maximum time to wait up to in seconds.
9554 * \returns StatusCode of the set command
9555 */
9556 ctre::phoenix::StatusCode ClearStickyFault_Undervoltage(units::time::second_t timeoutSeconds) final
9557 {
9558 return GetConfigurator().ClearStickyFault_Undervoltage(timeoutSeconds);
9559 }
9560 /**
9561 * \brief Clear sticky fault: Device supply voltage dropped to near
9562 * brownout levels
9563 *
9564 * This will wait up to 0.100 seconds (100ms) by default.
9565 *
9566 * \returns StatusCode of the set command
9567 */
9569 {
9570 return ClearStickyFault_Undervoltage(0.100_s);
9571 }
9572
9573 /**
9574 * \brief Clear sticky fault: Device boot while detecting the enable
9575 * signal
9576 *
9577 * \param timeoutSeconds Maximum time to wait up to in seconds.
9578 * \returns StatusCode of the set command
9579 */
9580 ctre::phoenix::StatusCode ClearStickyFault_BootDuringEnable(units::time::second_t timeoutSeconds) final
9581 {
9582 return GetConfigurator().ClearStickyFault_BootDuringEnable(timeoutSeconds);
9583 }
9584 /**
9585 * \brief Clear sticky fault: Device boot while detecting the enable
9586 * signal
9587 *
9588 * This will wait up to 0.100 seconds (100ms) by default.
9589 *
9590 * \returns StatusCode of the set command
9591 */
9593 {
9594 return ClearStickyFault_BootDuringEnable(0.100_s);
9595 }
9596
9597 /**
9598 * \brief Clear sticky fault: An unlicensed feature is in use, device
9599 * may not behave as expected.
9600 *
9601 * \param timeoutSeconds Maximum time to wait up to in seconds.
9602 * \returns StatusCode of the set command
9603 */
9604 ctre::phoenix::StatusCode ClearStickyFault_UnlicensedFeatureInUse(units::time::second_t timeoutSeconds) final
9605 {
9606 return GetConfigurator().ClearStickyFault_UnlicensedFeatureInUse(timeoutSeconds);
9607 }
9608 /**
9609 * \brief Clear sticky fault: An unlicensed feature is in use, device
9610 * may not behave as expected.
9611 *
9612 * This will wait up to 0.100 seconds (100ms) by default.
9613 *
9614 * \returns StatusCode of the set command
9615 */
9617 {
9618 return ClearStickyFault_UnlicensedFeatureInUse(0.100_s);
9619 }
9620
9621 /**
9622 * \brief Clear sticky fault: Bridge was disabled most likely due to
9623 * supply voltage dropping too low.
9624 *
9625 * \param timeoutSeconds Maximum time to wait up to in seconds.
9626 * \returns StatusCode of the set command
9627 */
9628 ctre::phoenix::StatusCode ClearStickyFault_BridgeBrownout(units::time::second_t timeoutSeconds) final
9629 {
9630 return GetConfigurator().ClearStickyFault_BridgeBrownout(timeoutSeconds);
9631 }
9632 /**
9633 * \brief Clear sticky fault: Bridge was disabled most likely due to
9634 * supply voltage dropping too low.
9635 *
9636 * This will wait up to 0.100 seconds (100ms) by default.
9637 *
9638 * \returns StatusCode of the set command
9639 */
9641 {
9642 return ClearStickyFault_BridgeBrownout(0.100_s);
9643 }
9644
9645 /**
9646 * \brief Clear sticky fault: The remote sensor has reset.
9647 *
9648 * \param timeoutSeconds Maximum time to wait up to in seconds.
9649 * \returns StatusCode of the set command
9650 */
9651 ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorReset(units::time::second_t timeoutSeconds) final
9652 {
9653 return GetConfigurator().ClearStickyFault_RemoteSensorReset(timeoutSeconds);
9654 }
9655 /**
9656 * \brief Clear sticky fault: The remote sensor has reset.
9657 *
9658 * This will wait up to 0.100 seconds (100ms) by default.
9659 *
9660 * \returns StatusCode of the set command
9661 */
9663 {
9664 return ClearStickyFault_RemoteSensorReset(0.100_s);
9665 }
9666
9667 /**
9668 * \brief Clear sticky fault: The remote Talon used for differential
9669 * control is not present on CAN Bus.
9670 *
9671 * \param timeoutSeconds Maximum time to wait up to in seconds.
9672 * \returns StatusCode of the set command
9673 */
9674 ctre::phoenix::StatusCode ClearStickyFault_MissingDifferentialFX(units::time::second_t timeoutSeconds) final
9675 {
9676 return GetConfigurator().ClearStickyFault_MissingDifferentialFX(timeoutSeconds);
9677 }
9678 /**
9679 * \brief Clear sticky fault: The remote Talon used for differential
9680 * control is not present on CAN Bus.
9681 *
9682 * This will wait up to 0.100 seconds (100ms) by default.
9683 *
9684 * \returns StatusCode of the set command
9685 */
9687 {
9688 return ClearStickyFault_MissingDifferentialFX(0.100_s);
9689 }
9690
9691 /**
9692 * \brief Clear sticky fault: The remote sensor position has
9693 * overflowed. Because of the nature of remote sensors, it is possible
9694 * for the remote sensor position to overflow beyond what is supported
9695 * by the status signal frame. However, this is rare and cannot occur
9696 * over the course of an FRC match under normal use.
9697 *
9698 * \param timeoutSeconds Maximum time to wait up to in seconds.
9699 * \returns StatusCode of the set command
9700 */
9702 {
9703 return GetConfigurator().ClearStickyFault_RemoteSensorPosOverflow(timeoutSeconds);
9704 }
9705 /**
9706 * \brief Clear sticky fault: The remote sensor position has
9707 * overflowed. Because of the nature of remote sensors, it is possible
9708 * for the remote sensor position to overflow beyond what is supported
9709 * by the status signal frame. However, this is rare and cannot occur
9710 * over the course of an FRC match under normal use.
9711 *
9712 * This will wait up to 0.100 seconds (100ms) by default.
9713 *
9714 * \returns StatusCode of the set command
9715 */
9717 {
9718 return ClearStickyFault_RemoteSensorPosOverflow(0.100_s);
9719 }
9720
9721 /**
9722 * \brief Clear sticky fault: Supply Voltage has exceeded the maximum
9723 * voltage rating of device.
9724 *
9725 * \param timeoutSeconds Maximum time to wait up to in seconds.
9726 * \returns StatusCode of the set command
9727 */
9728 ctre::phoenix::StatusCode ClearStickyFault_OverSupplyV(units::time::second_t timeoutSeconds) final
9729 {
9730 return GetConfigurator().ClearStickyFault_OverSupplyV(timeoutSeconds);
9731 }
9732 /**
9733 * \brief Clear sticky fault: Supply Voltage has exceeded the maximum
9734 * voltage rating of device.
9735 *
9736 * This will wait up to 0.100 seconds (100ms) by default.
9737 *
9738 * \returns StatusCode of the set command
9739 */
9741 {
9742 return ClearStickyFault_OverSupplyV(0.100_s);
9743 }
9744
9745 /**
9746 * \brief Clear sticky fault: Supply Voltage is unstable. Ensure you
9747 * are using a battery and current limited power supply.
9748 *
9749 * \param timeoutSeconds Maximum time to wait up to in seconds.
9750 * \returns StatusCode of the set command
9751 */
9752 ctre::phoenix::StatusCode ClearStickyFault_UnstableSupplyV(units::time::second_t timeoutSeconds) final
9753 {
9754 return GetConfigurator().ClearStickyFault_UnstableSupplyV(timeoutSeconds);
9755 }
9756 /**
9757 * \brief Clear sticky fault: Supply Voltage is unstable. Ensure you
9758 * are using a battery and current limited power supply.
9759 *
9760 * This will wait up to 0.100 seconds (100ms) by default.
9761 *
9762 * \returns StatusCode of the set command
9763 */
9765 {
9766 return ClearStickyFault_UnstableSupplyV(0.100_s);
9767 }
9768
9769 /**
9770 * \brief Clear sticky fault: Reverse limit switch has been asserted.
9771 * Output is set to neutral.
9772 *
9773 * \param timeoutSeconds Maximum time to wait up to in seconds.
9774 * \returns StatusCode of the set command
9775 */
9776 ctre::phoenix::StatusCode ClearStickyFault_ReverseHardLimit(units::time::second_t timeoutSeconds) final
9777 {
9778 return GetConfigurator().ClearStickyFault_ReverseHardLimit(timeoutSeconds);
9779 }
9780 /**
9781 * \brief Clear sticky fault: Reverse limit switch has been asserted.
9782 * Output is set to neutral.
9783 *
9784 * This will wait up to 0.100 seconds (100ms) by default.
9785 *
9786 * \returns StatusCode of the set command
9787 */
9789 {
9790 return ClearStickyFault_ReverseHardLimit(0.100_s);
9791 }
9792
9793 /**
9794 * \brief Clear sticky fault: Forward limit switch has been asserted.
9795 * Output is set to neutral.
9796 *
9797 * \param timeoutSeconds Maximum time to wait up to in seconds.
9798 * \returns StatusCode of the set command
9799 */
9800 ctre::phoenix::StatusCode ClearStickyFault_ForwardHardLimit(units::time::second_t timeoutSeconds) final
9801 {
9802 return GetConfigurator().ClearStickyFault_ForwardHardLimit(timeoutSeconds);
9803 }
9804 /**
9805 * \brief Clear sticky fault: Forward limit switch has been asserted.
9806 * Output is set to neutral.
9807 *
9808 * This will wait up to 0.100 seconds (100ms) by default.
9809 *
9810 * \returns StatusCode of the set command
9811 */
9813 {
9814 return ClearStickyFault_ForwardHardLimit(0.100_s);
9815 }
9816
9817 /**
9818 * \brief Clear sticky fault: Reverse soft limit has been asserted.
9819 * Output is set to neutral.
9820 *
9821 * \param timeoutSeconds Maximum time to wait up to in seconds.
9822 * \returns StatusCode of the set command
9823 */
9824 ctre::phoenix::StatusCode ClearStickyFault_ReverseSoftLimit(units::time::second_t timeoutSeconds) final
9825 {
9826 return GetConfigurator().ClearStickyFault_ReverseSoftLimit(timeoutSeconds);
9827 }
9828 /**
9829 * \brief Clear sticky fault: Reverse soft limit has been asserted.
9830 * Output is set to neutral.
9831 *
9832 * This will wait up to 0.100 seconds (100ms) by default.
9833 *
9834 * \returns StatusCode of the set command
9835 */
9837 {
9838 return ClearStickyFault_ReverseSoftLimit(0.100_s);
9839 }
9840
9841 /**
9842 * \brief Clear sticky fault: Forward soft limit has been asserted.
9843 * Output is set to neutral.
9844 *
9845 * \param timeoutSeconds Maximum time to wait up to in seconds.
9846 * \returns StatusCode of the set command
9847 */
9848 ctre::phoenix::StatusCode ClearStickyFault_ForwardSoftLimit(units::time::second_t timeoutSeconds) final
9849 {
9850 return GetConfigurator().ClearStickyFault_ForwardSoftLimit(timeoutSeconds);
9851 }
9852 /**
9853 * \brief Clear sticky fault: Forward soft limit has been asserted.
9854 * Output is set to neutral.
9855 *
9856 * This will wait up to 0.100 seconds (100ms) by default.
9857 *
9858 * \returns StatusCode of the set command
9859 */
9861 {
9862 return ClearStickyFault_ForwardSoftLimit(0.100_s);
9863 }
9864
9865 /**
9866 * \brief Clear sticky fault: The remote soft limit device is not
9867 * present on CAN Bus.
9868 *
9869 * \param timeoutSeconds Maximum time to wait up to in seconds.
9870 * \returns StatusCode of the set command
9871 */
9872 ctre::phoenix::StatusCode ClearStickyFault_MissingSoftLimitRemote(units::time::second_t timeoutSeconds) final
9873 {
9874 return GetConfigurator().ClearStickyFault_MissingSoftLimitRemote(timeoutSeconds);
9875 }
9876 /**
9877 * \brief Clear sticky fault: The remote soft limit device is not
9878 * present on CAN Bus.
9879 *
9880 * This will wait up to 0.100 seconds (100ms) by default.
9881 *
9882 * \returns StatusCode of the set command
9883 */
9885 {
9886 return ClearStickyFault_MissingSoftLimitRemote(0.100_s);
9887 }
9888
9889 /**
9890 * \brief Clear sticky fault: The remote limit switch device is not
9891 * present on CAN Bus.
9892 *
9893 * \param timeoutSeconds Maximum time to wait up to in seconds.
9894 * \returns StatusCode of the set command
9895 */
9896 ctre::phoenix::StatusCode ClearStickyFault_MissingHardLimitRemote(units::time::second_t timeoutSeconds) final
9897 {
9898 return GetConfigurator().ClearStickyFault_MissingHardLimitRemote(timeoutSeconds);
9899 }
9900 /**
9901 * \brief Clear sticky fault: The remote limit switch device is not
9902 * present on CAN Bus.
9903 *
9904 * This will wait up to 0.100 seconds (100ms) by default.
9905 *
9906 * \returns StatusCode of the set command
9907 */
9909 {
9910 return ClearStickyFault_MissingHardLimitRemote(0.100_s);
9911 }
9912
9913 /**
9914 * \brief Clear sticky fault: The remote sensor's data is no longer
9915 * trusted. This can happen if the remote sensor disappears from the
9916 * CAN bus or if the remote sensor indicates its data is no longer
9917 * valid, such as when a CANcoder's magnet strength falls into the
9918 * "red" range.
9919 *
9920 * \param timeoutSeconds Maximum time to wait up to in seconds.
9921 * \returns StatusCode of the set command
9922 */
9924 {
9925 return GetConfigurator().ClearStickyFault_RemoteSensorDataInvalid(timeoutSeconds);
9926 }
9927 /**
9928 * \brief Clear sticky fault: The remote sensor's data is no longer
9929 * trusted. This can happen if the remote sensor disappears from the
9930 * CAN bus or if the remote sensor indicates its data is no longer
9931 * valid, such as when a CANcoder's magnet strength falls into the
9932 * "red" range.
9933 *
9934 * This will wait up to 0.100 seconds (100ms) by default.
9935 *
9936 * \returns StatusCode of the set command
9937 */
9939 {
9940 return ClearStickyFault_RemoteSensorDataInvalid(0.100_s);
9941 }
9942
9943 /**
9944 * \brief Clear sticky fault: The remote sensor used for fusion has
9945 * fallen out of sync to the local sensor. A re-synchronization has
9946 * occurred, which may cause a discontinuity. This typically happens
9947 * if there is significant slop in the mechanism, or if the
9948 * RotorToSensorRatio configuration parameter is incorrect.
9949 *
9950 * \param timeoutSeconds Maximum time to wait up to in seconds.
9951 * \returns StatusCode of the set command
9952 */
9953 ctre::phoenix::StatusCode ClearStickyFault_FusedSensorOutOfSync(units::time::second_t timeoutSeconds) final
9954 {
9955 return GetConfigurator().ClearStickyFault_FusedSensorOutOfSync(timeoutSeconds);
9956 }
9957 /**
9958 * \brief Clear sticky fault: The remote sensor used for fusion has
9959 * fallen out of sync to the local sensor. A re-synchronization has
9960 * occurred, which may cause a discontinuity. This typically happens
9961 * if there is significant slop in the mechanism, or if the
9962 * RotorToSensorRatio configuration parameter is incorrect.
9963 *
9964 * This will wait up to 0.100 seconds (100ms) by default.
9965 *
9966 * \returns StatusCode of the set command
9967 */
9969 {
9970 return ClearStickyFault_FusedSensorOutOfSync(0.100_s);
9971 }
9972
9973 /**
9974 * \brief Clear sticky fault: Stator current limit occured.
9975 *
9976 * \param timeoutSeconds Maximum time to wait up to in seconds.
9977 * \returns StatusCode of the set command
9978 */
9979 ctre::phoenix::StatusCode ClearStickyFault_StatorCurrLimit(units::time::second_t timeoutSeconds) final
9980 {
9981 return GetConfigurator().ClearStickyFault_StatorCurrLimit(timeoutSeconds);
9982 }
9983 /**
9984 * \brief Clear sticky fault: Stator current limit occured.
9985 *
9986 * This will wait up to 0.100 seconds (100ms) by default.
9987 *
9988 * \returns StatusCode of the set command
9989 */
9991 {
9992 return ClearStickyFault_StatorCurrLimit(0.100_s);
9993 }
9994
9995 /**
9996 * \brief Clear sticky fault: Supply current limit occured.
9997 *
9998 * \param timeoutSeconds Maximum time to wait up to in seconds.
9999 * \returns StatusCode of the set command
10000 */
10001 ctre::phoenix::StatusCode ClearStickyFault_SupplyCurrLimit(units::time::second_t timeoutSeconds) final
10002 {
10003 return GetConfigurator().ClearStickyFault_SupplyCurrLimit(timeoutSeconds);
10004 }
10005 /**
10006 * \brief Clear sticky fault: Supply current limit occured.
10007 *
10008 * This will wait up to 0.100 seconds (100ms) by default.
10009 *
10010 * \returns StatusCode of the set command
10011 */
10013 {
10014 return ClearStickyFault_SupplyCurrLimit(0.100_s);
10015 }
10016
10017 /**
10018 * \brief Clear sticky fault: Using Fused CANcoder feature while
10019 * unlicensed. Device has fallen back to remote CANcoder.
10020 *
10021 * \param timeoutSeconds Maximum time to wait up to in seconds.
10022 * \returns StatusCode of the set command
10023 */
10025 {
10026 return GetConfigurator().ClearStickyFault_UsingFusedCANcoderWhileUnlicensed(timeoutSeconds);
10027 }
10028 /**
10029 * \brief Clear sticky fault: Using Fused CANcoder feature while
10030 * unlicensed. Device has fallen back to remote CANcoder.
10031 *
10032 * This will wait up to 0.100 seconds (100ms) by default.
10033 *
10034 * \returns StatusCode of the set command
10035 */
10037 {
10038 return ClearStickyFault_UsingFusedCANcoderWhileUnlicensed(0.100_s);
10039 }
10040
10041 /**
10042 * \brief Clear sticky fault: Static brake was momentarily disabled
10043 * due to excessive braking current while disabled.
10044 *
10045 * \param timeoutSeconds Maximum time to wait up to in seconds.
10046 * \returns StatusCode of the set command
10047 */
10048 ctre::phoenix::StatusCode ClearStickyFault_StaticBrakeDisabled(units::time::second_t timeoutSeconds) final
10049 {
10050 return GetConfigurator().ClearStickyFault_StaticBrakeDisabled(timeoutSeconds);
10051 }
10052 /**
10053 * \brief Clear sticky fault: Static brake was momentarily disabled
10054 * due to excessive braking current while disabled.
10055 *
10056 * This will wait up to 0.100 seconds (100ms) by default.
10057 *
10058 * \returns StatusCode of the set command
10059 */
10061 {
10062 return ClearStickyFault_StaticBrakeDisabled(0.100_s);
10063 }
10064
10065 /**
10066 * \brief Clear sticky fault: Trips if a major mechanical or ESD event
10067 * caused a brief loss of position data triggering a recovery while
10068 * not in motion. If the event occurs often, inspect for excess axial
10069 * force or sources of ESD at the rotor.
10070 *
10071 * \param timeoutSeconds Maximum time to wait up to in seconds.
10072 * \returns StatusCode of the set command
10073 */
10074 ctre::phoenix::StatusCode ClearStickyFault_RotorFault1(units::time::second_t timeoutSeconds) final
10075 {
10076 return GetConfigurator().ClearStickyFault_RotorFault1(timeoutSeconds);
10077 }
10078 /**
10079 * \brief Clear sticky fault: Trips if a major mechanical or ESD event
10080 * caused a brief loss of position data triggering a recovery while
10081 * not in motion. If the event occurs often, inspect for excess axial
10082 * force or sources of ESD at the rotor.
10083 *
10084 * This will wait up to 0.100 seconds (100ms) by default.
10085 *
10086 * \returns StatusCode of the set command
10087 */
10089 {
10090 return ClearStickyFault_RotorFault1(0.100_s);
10091 }
10092
10093 /**
10094 * \brief Clear sticky fault: Trips if a major mechanical or ESD event
10095 * caused a brief loss of position data triggering a recovery while in
10096 * motion. If the event occurs often, inspect for excess axial force
10097 * or sources of ESD at the rotor.
10098 *
10099 * \param timeoutSeconds Maximum time to wait up to in seconds.
10100 * \returns StatusCode of the set command
10101 */
10102 ctre::phoenix::StatusCode ClearStickyFault_RotorFault2(units::time::second_t timeoutSeconds) final
10103 {
10104 return GetConfigurator().ClearStickyFault_RotorFault2(timeoutSeconds);
10105 }
10106 /**
10107 * \brief Clear sticky fault: Trips if a major mechanical or ESD event
10108 * caused a brief loss of position data triggering a recovery while in
10109 * motion. If the event occurs often, inspect for excess axial force
10110 * or sources of ESD at the rotor.
10111 *
10112 * This will wait up to 0.100 seconds (100ms) by default.
10113 *
10114 * \returns StatusCode of the set command
10115 */
10117 {
10118 return ClearStickyFault_RotorFault2(0.100_s);
10119 }
10120};
10121
10122#if defined(_WIN32) || defined(_WIN64)
10123#pragma warning(pop)
10124#endif
10125
10126}
10127}
10128
10129}
10130}
10131
Class for getting information about an available CAN bus.
Definition CANBus.hpp:19
Represents a status signal with data of type T, and operations available to retrieve information abou...
Definition StatusSignal.hpp:470
Configs that affect audible components of the device.
Definition AudioConfigs.hpp:23
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
std::string Serialize() const final
Configs that affect general behavior during closed-looping.
Definition ClosedLoopGeneralConfigs.hpp:24
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Configs that affect the closed-loop control of this motor controller.
Definition ClosedLoopRampsConfigs.hpp:24
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Configs that directly affect current limiting features.
Definition CurrentLimitsConfigs.hpp:25
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Custom Params.
Definition CustomParamsConfigs.hpp:23
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Configs related to constants used for differential control of a mechanism.
Definition DifferentialConstantsConfigs.hpp:26
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Configs related to sensors used for differential control of a mechanism.
Definition DifferentialSensorsConfigs.hpp:25
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Configs that affect the feedback of this motor controller.
Definition FeedbackConfigs.hpp:31
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
std::string Serialize() const final
Configs that change how the motor controller behaves under different limit switch states.
Definition HardwareLimitSwitchConfigs.hpp:30
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Configs for Motion Magic®.
Definition MotionMagicConfigs.hpp:27
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Configs that directly affect motor output.
Definition MotorOutputConfigs.hpp:26
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Configs that affect the open-loop control of this motor controller.
Definition OpenLoopRampsConfigs.hpp:24
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Definition Configuration.hpp:17
Definition Configurator.hpp:18
Gains for the specified slot.
Definition Slot0Configs.hpp:26
std::string Serialize() const final
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Gains for the specified slot.
Definition Slot1Configs.hpp:26
std::string Serialize() const final
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Gains for the specified slot.
Definition Slot2Configs.hpp:26
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
std::string Serialize() const final
Gains for the specified slot.
Definition SlotConfigs.hpp:26
std::string Serialize() const final
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Configs that affect how software-limit switches behave.
Definition SoftwareLimitSwitchConfigs.hpp:24
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Class description for the Talon FX integrated motor controller.
Definition CoreTalonFX.hpp:158
TorqueCurrentConfigs TorqueCurrent
Configs that affect Torque Current control types.
Definition CoreTalonFX.hpp:243
constexpr TalonFXConfiguration & WithTorqueCurrent(TorqueCurrentConfigs newTorqueCurrent)
Modifies this configuration's TorqueCurrent parameter and returns itself for method-chaining and easi...
Definition CoreTalonFX.hpp:597
MotorOutputConfigs MotorOutput
Configs that directly affect motor output.
Definition CoreTalonFX.hpp:194
constexpr TalonFXConfiguration & WithAudio(AudioConfigs newAudio)
Modifies this configuration's Audio parameter and returns itself for method-chaining and easier to us...
Definition CoreTalonFX.hpp:787
constexpr TalonFXConfiguration & WithOpenLoopRamps(OpenLoopRampsConfigs newOpenLoopRamps)
Modifies this configuration's OpenLoopRamps parameter and returns itself for method-chaining and easi...
Definition CoreTalonFX.hpp:702
bool FutureProofConfigs
True if we should factory default newer unsupported configs, false to leave newer unsupported configs...
Definition CoreTalonFX.hpp:175
constexpr TalonFXConfiguration & WithSlot1(Slot1Configs newSlot1)
Modifies this configuration's Slot1 parameter and returns itself for method-chaining and easier to us...
Definition CoreTalonFX.hpp:954
constexpr TalonFXConfiguration & WithHardwareLimitSwitch(HardwareLimitSwitchConfigs newHardwareLimitSwitch)
Modifies this configuration's HardwareLimitSwitch parameter and returns itself for method-chaining an...
Definition CoreTalonFX.hpp:763
constexpr TalonFXConfiguration & WithFeedback(FeedbackConfigs newFeedback)
Modifies this configuration's Feedback parameter and returns itself for method-chaining and easier to...
Definition CoreTalonFX.hpp:627
std::string ToString() const override
Get the string representation of this configuration.
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Take a string and deserialize it to this configuration.
constexpr TalonFXConfiguration & WithClosedLoopRamps(ClosedLoopRampsConfigs newClosedLoopRamps)
Modifies this configuration's ClosedLoopRamps parameter and returns itself for method-chaining and ea...
Definition CoreTalonFX.hpp:727
constexpr TalonFXConfiguration & WithMotionMagic(MotionMagicConfigs newMotionMagic)
Modifies this configuration's MotionMagic parameter and returns itself for method-chaining and easier...
Definition CoreTalonFX.hpp:840
constexpr TalonFXConfiguration & WithDifferentialConstants(DifferentialConstantsConfigs newDifferentialConstants)
Modifies this configuration's DifferentialConstants parameter and returns itself for method-chaining ...
Definition CoreTalonFX.hpp:678
constexpr TalonFXConfiguration & WithClosedLoopGeneral(ClosedLoopGeneralConfigs newClosedLoopGeneral)
Modifies this configuration's ClosedLoopGeneral parameter and returns itself for method-chaining and ...
Definition CoreTalonFX.hpp:888
constexpr TalonFXConfiguration & WithCustomParams(CustomParamsConfigs newCustomParams)
Modifies this configuration's CustomParams parameter and returns itself for method-chaining and easie...
Definition CoreTalonFX.hpp:863
constexpr TalonFXConfiguration & WithSlot2(Slot2Configs newSlot2)
Modifies this configuration's Slot2 parameter and returns itself for method-chaining and easier to us...
Definition CoreTalonFX.hpp:987
DifferentialConstantsConfigs DifferentialConstants
Configs related to constants used for differential control of a mechanism.
Definition CoreTalonFX.hpp:294
constexpr TalonFXConfiguration & WithDifferentialSensors(DifferentialSensorsConfigs newDifferentialSensors)
Modifies this configuration's DifferentialSensors parameter and returns itself for method-chaining an...
Definition CoreTalonFX.hpp:653
VoltageConfigs Voltage
Configs that affect Voltage control types.
Definition CoreTalonFX.hpp:227
HardwareLimitSwitchConfigs HardwareLimitSwitch
Configs that change how the motor controller behaves under different limit switch states.
Definition CoreTalonFX.hpp:350
constexpr TalonFXConfiguration & WithCurrentLimits(CurrentLimitsConfigs newCurrentLimits)
Modifies this configuration's CurrentLimits parameter and returns itself for method-chaining and easi...
Definition CoreTalonFX.hpp:546
ClosedLoopRampsConfigs ClosedLoopRamps
Configs that affect the closed-loop control of this motor controller.
Definition CoreTalonFX.hpp:324
Slot2Configs Slot2
Gains for the specified slot.
Definition CoreTalonFX.hpp:494
OpenLoopRampsConfigs OpenLoopRamps
Configs that affect the open-loop control of this motor controller.
Definition CoreTalonFX.hpp:309
SoftwareLimitSwitchConfigs SoftwareLimitSwitch
Configs that affect how software-limit switches behave.
Definition CoreTalonFX.hpp:380
MotionMagicConfigs MotionMagic
Configs for Motion Magic®.
Definition CoreTalonFX.hpp:397
FeedbackConfigs Feedback
Configs that affect the feedback of this motor controller.
Definition CoreTalonFX.hpp:263
Slot0Configs Slot0
Gains for the specified slot.
Definition CoreTalonFX.hpp:448
constexpr TalonFXConfiguration & WithSlot0(Slot0Configs newSlot0)
Modifies this configuration's Slot0 parameter and returns itself for method-chaining and easier to us...
Definition CoreTalonFX.hpp:921
AudioConfigs Audio
Configs that affect audible components of the device.
Definition CoreTalonFX.hpp:364
DifferentialSensorsConfigs DifferentialSensors
Configs related to sensors used for differential control of a mechanism.
Definition CoreTalonFX.hpp:279
CurrentLimitsConfigs CurrentLimits
Configs that directly affect current limiting features.
Definition CoreTalonFX.hpp:212
constexpr TalonFXConfiguration & WithMotorOutput(MotorOutputConfigs newMotorOutput)
Modifies this configuration's MotorOutput parameter and returns itself for method-chaining and easier...
Definition CoreTalonFX.hpp:518
CustomParamsConfigs CustomParams
Custom Params.
Definition CoreTalonFX.hpp:410
std::string Serialize() const final
Get the serialized form of this configuration.
ClosedLoopGeneralConfigs ClosedLoopGeneral
Configs that affect general behavior during closed-looping.
Definition CoreTalonFX.hpp:425
constexpr TalonFXConfiguration & WithVoltage(VoltageConfigs newVoltage)
Modifies this configuration's Voltage parameter and returns itself for method-chaining and easier to ...
Definition CoreTalonFX.hpp:571
Slot1Configs Slot1
Gains for the specified slot.
Definition CoreTalonFX.hpp:471
constexpr TalonFXConfiguration & WithSoftwareLimitSwitch(SoftwareLimitSwitchConfigs newSoftwareLimitSwitch)
Modifies this configuration's SoftwareLimitSwitch parameter and returns itself for method-chaining an...
Definition CoreTalonFX.hpp:813
Class description for the Talon FX integrated motor controller.
Definition CoreTalonFX.hpp:1014
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorDataInvalid()
Clear sticky fault: The remote sensor's data is no longer trusted.
Definition CoreTalonFX.hpp:2909
ctre::phoenix::StatusCode Refresh(AudioConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1695
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorPosOverflow(units::time::second_t timeoutSeconds)
Clear sticky fault: The remote sensor position has overflowed.
ctre::phoenix::StatusCode ClearStickyFault_ForwardSoftLimit()
Clear sticky fault: Forward soft limit has been asserted.
Definition CoreTalonFX.hpp:2807
ctre::phoenix::StatusCode ClearStickyFault_MissingHardLimitRemote(units::time::second_t timeoutSeconds)
Clear sticky fault: The remote limit switch device is not present on CAN Bus.
ctre::phoenix::StatusCode Refresh(Slot1Configs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:2068
ctre::phoenix::StatusCode SetPosition(units::angle::turn_t newValue)
Sets the mechanism position of the device in mechanism rotations.
Definition CoreTalonFX.hpp:2241
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorDataInvalid(units::time::second_t timeoutSeconds)
Clear sticky fault: The remote sensor's data is no longer trusted.
ctre::phoenix::StatusCode ClearStickyFaults()
Clear the sticky faults in the device.
Definition CoreTalonFX.hpp:2278
ctre::phoenix::StatusCode Apply(const DifferentialConstantsConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1500
ctre::phoenix::StatusCode Refresh(OpenLoopRampsConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1515
ctre::phoenix::StatusCode Apply(const AudioConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1726
ctre::phoenix::StatusCode Refresh(FeedbackConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1335
ctre::phoenix::StatusCode Apply(const Slot0Configs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:2040
ctre::phoenix::StatusCode Refresh(Slot0Configs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1995
ctre::phoenix::StatusCode Refresh(ClosedLoopGeneralConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1948
ctre::phoenix::StatusCode Refresh(SoftwareLimitSwitchConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1755
ctre::phoenix::StatusCode Apply(const TalonFXConfiguration &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1065
ctre::phoenix::StatusCode Apply(const MotionMagicConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1846
ctre::phoenix::StatusCode ClearStickyFault_ProcTemp(units::time::second_t timeoutSeconds)
Clear sticky fault: Processor temperature exceeded limit.
ctre::phoenix::StatusCode Apply(const DifferentialSensorsConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1426
ctre::phoenix::StatusCode Refresh(Slot2Configs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:2128
ctre::phoenix::StatusCode ClearStickyFault_BridgeBrownout(units::time::second_t timeoutSeconds)
Clear sticky fault: Bridge was disabled most likely due to supply voltage dropping too low.
ctre::phoenix::StatusCode Refresh(ClosedLoopRampsConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1588
ctre::phoenix::StatusCode ClearStickyFault_Undervoltage()
Clear sticky fault: Device supply voltage dropped to near brownout levels.
Definition CoreTalonFX.hpp:2407
ctre::phoenix::StatusCode Refresh(MotionMagicConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1815
ctre::phoenix::StatusCode Apply(const Slot2Configs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:2160
ctre::phoenix::StatusCode ClearStickyFault_OverSupplyV(units::time::second_t timeoutSeconds)
Clear sticky fault: Supply Voltage has exceeded the maximum voltage rating of device.
ctre::phoenix::StatusCode ClearStickyFault_StaticBrakeDisabled(units::time::second_t timeoutSeconds)
Clear sticky fault: Static brake was momentarily disabled due to excessive braking current while disa...
ctre::phoenix::StatusCode Apply(const DifferentialConstantsConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1486
ctre::phoenix::StatusCode Refresh(VoltageConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1228
ctre::phoenix::StatusCode ClearStickyFault_ProcTemp()
Clear sticky fault: Processor temperature exceeded limit.
Definition CoreTalonFX.hpp:2344
ctre::phoenix::StatusCode Refresh(SlotConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:2175
ctre::phoenix::StatusCode Refresh(Slot1Configs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:2055
ctre::phoenix::StatusCode Refresh(CustomParamsConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1875
ctre::phoenix::StatusCode ClearStickyFault_DeviceTemp()
Clear sticky fault: Device temperature exceeded limit.
Definition CoreTalonFX.hpp:2375
ctre::phoenix::StatusCode ClearStickyFault_ForwardSoftLimit(units::time::second_t timeoutSeconds)
Clear sticky fault: Forward soft limit has been asserted.
ctre::phoenix::StatusCode Apply(const CustomParamsConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1920
ctre::phoenix::StatusCode Refresh(ClosedLoopGeneralConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1935
ctre::phoenix::StatusCode Refresh(Slot2Configs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:2115
ctre::phoenix::StatusCode ClearStickyFault_StaticBrakeDisabled()
Clear sticky fault: Static brake was momentarily disabled due to excessive braking current while disa...
Definition CoreTalonFX.hpp:3079
ctre::phoenix::StatusCode SetPosition(units::angle::turn_t newValue, units::time::second_t timeoutSeconds)
Sets the mechanism position of the device in mechanism rotations.
ctre::phoenix::StatusCode ClearStickyFault_Hardware()
Clear sticky fault: Hardware fault occurred.
Definition CoreTalonFX.hpp:2313
ctre::phoenix::StatusCode Apply(const SlotConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:2220
ctre::phoenix::StatusCode Apply(const OpenLoopRampsConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1546
ctre::phoenix::StatusCode ClearStickyFault_RotorFault1(units::time::second_t timeoutSeconds)
Clear sticky fault: Trips if a major mechanical or ESD event caused a brief loss of position data tri...
ctre::phoenix::StatusCode Apply(const Slot1Configs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:2100
ctre::phoenix::StatusCode ClearStickyFault_ReverseSoftLimit(units::time::second_t timeoutSeconds)
Clear sticky fault: Reverse soft limit has been asserted.
ctre::phoenix::StatusCode ClearStickyFault_ReverseSoftLimit()
Clear sticky fault: Reverse soft limit has been asserted.
Definition CoreTalonFX.hpp:2774
ctre::phoenix::StatusCode Refresh(VoltageConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1215
ctre::phoenix::StatusCode Refresh(FeedbackConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1348
ctre::phoenix::StatusCode Apply(const ClosedLoopRampsConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1606
ctre::phoenix::StatusCode Apply(const TalonFXConfiguration &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1079
ctre::phoenix::StatusCode Apply(const ClosedLoopRampsConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1620
ctre::phoenix::StatusCode ClearStickyFault_UnlicensedFeatureInUse()
Clear sticky fault: An unlicensed feature is in use, device may not behave as expected.
Definition CoreTalonFX.hpp:2473
ctre::phoenix::StatusCode Apply(const SoftwareLimitSwitchConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1800
ctre::phoenix::StatusCode Apply(const Slot0Configs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:2026
ctre::phoenix::StatusCode Apply(const CustomParamsConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1906
ctre::phoenix::StatusCode ClearStickyFault_RotorFault1()
Clear sticky fault: Trips if a major mechanical or ESD event caused a brief loss of position data tri...
Definition CoreTalonFX.hpp:3114
ctre::phoenix::StatusCode Apply(const TorqueCurrentConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1320
ctre::phoenix::StatusCode ClearStickyFault_FusedSensorOutOfSync(units::time::second_t timeoutSeconds)
Clear sticky fault: The remote sensor used for fusion has fallen out of sync to the local sensor.
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorPosOverflow()
Clear sticky fault: The remote sensor position has overflowed.
Definition CoreTalonFX.hpp:2606
ctre::phoenix::StatusCode ClearStickyFault_Hardware(units::time::second_t timeoutSeconds)
Clear sticky fault: Hardware fault occurred.
ctre::phoenix::StatusCode Apply(const ClosedLoopGeneralConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1966
ctre::phoenix::StatusCode ClearStickyFault_Undervoltage(units::time::second_t timeoutSeconds)
Clear sticky fault: Device supply voltage dropped to near brownout levels.
ctre::phoenix::StatusCode Apply(const ClosedLoopGeneralConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1980
ctre::phoenix::StatusCode Refresh(CustomParamsConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1888
ctre::phoenix::StatusCode Refresh(SoftwareLimitSwitchConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1768
ctre::phoenix::StatusCode Apply(const MotorOutputConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1126
ctre::phoenix::StatusCode Apply(const Slot2Configs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:2146
ctre::phoenix::StatusCode Apply(const MotionMagicConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1860
ctre::phoenix::StatusCode ClearStickyFaults(units::time::second_t timeoutSeconds)
Clear the sticky faults in the device.
ctre::phoenix::StatusCode ClearStickyFault_UnstableSupplyV(units::time::second_t timeoutSeconds)
Clear sticky fault: Supply Voltage is unstable.
ctre::phoenix::StatusCode Refresh(AudioConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1708
ctre::phoenix::StatusCode Apply(const VoltageConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1260
ctre::phoenix::StatusCode Refresh(MotorOutputConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1108
ctre::phoenix::StatusCode Refresh(CurrentLimitsConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1155
ctre::phoenix::StatusCode ClearStickyFault_BootDuringEnable()
Clear sticky fault: Device boot while detecting the enable signal.
Definition CoreTalonFX.hpp:2440
ctre::phoenix::StatusCode ClearStickyFault_OverSupplyV()
Clear sticky fault: Supply Voltage has exceeded the maximum voltage rating of device.
Definition CoreTalonFX.hpp:2642
ctre::phoenix::StatusCode Refresh(TalonFXConfiguration &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1047
ctre::phoenix::StatusCode Refresh(DifferentialSensorsConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1395
ctre::phoenix::StatusCode ClearStickyFault_UsingFusedCANcoderWhileUnlicensed()
Clear sticky fault: Using Fused CANcoder feature while unlicensed.
Definition CoreTalonFX.hpp:3046
ctre::phoenix::StatusCode Refresh(TorqueCurrentConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1275
ctre::phoenix::StatusCode ClearStickyFault_BridgeBrownout()
Clear sticky fault: Bridge was disabled most likely due to supply voltage dropping too low.
Definition CoreTalonFX.hpp:2506
ctre::phoenix::StatusCode Apply(const SlotConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:2206
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorReset(units::time::second_t timeoutSeconds)
Clear sticky fault: The remote sensor has reset.
ctre::phoenix::StatusCode ClearStickyFault_UnlicensedFeatureInUse(units::time::second_t timeoutSeconds)
Clear sticky fault: An unlicensed feature is in use, device may not behave as expected.
ctre::phoenix::StatusCode ClearStickyFault_SupplyCurrLimit()
Clear sticky fault: Supply current limit occured.
Definition CoreTalonFX.hpp:3014
ctre::phoenix::StatusCode ClearStickyFault_UnstableSupplyV()
Clear sticky fault: Supply Voltage is unstable.
Definition CoreTalonFX.hpp:2675
ctre::phoenix::StatusCode Refresh(OpenLoopRampsConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1528
ctre::phoenix::StatusCode Apply(const Slot1Configs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:2086
ctre::phoenix::StatusCode Apply(const SoftwareLimitSwitchConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1786
ctre::phoenix::StatusCode Refresh(DifferentialSensorsConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1408
ctre::phoenix::StatusCode ClearStickyFault_MissingDifferentialFX(units::time::second_t timeoutSeconds)
Clear sticky fault: The remote Talon used for differential control is not present on CAN Bus.
ctre::phoenix::StatusCode ClearStickyFault_ForwardHardLimit()
Clear sticky fault: Forward limit switch has been asserted.
Definition CoreTalonFX.hpp:2741
ctre::phoenix::StatusCode ClearStickyFault_RotorFault2()
Clear sticky fault: Trips if a major mechanical or ESD event caused a brief loss of position data tri...
Definition CoreTalonFX.hpp:3151
ctre::phoenix::StatusCode ClearStickyFault_StatorCurrLimit(units::time::second_t timeoutSeconds)
Clear sticky fault: Stator current limit occured.
ctre::phoenix::StatusCode ClearStickyFault_MissingHardLimitRemote()
Clear sticky fault: The remote limit switch device is not present on CAN Bus.
Definition CoreTalonFX.hpp:2873
ctre::phoenix::StatusCode ClearStickyFault_StatorCurrLimit()
Clear sticky fault: Stator current limit occured.
Definition CoreTalonFX.hpp:2983
ctre::phoenix::StatusCode Apply(const HardwareLimitSwitchConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1666
ctre::phoenix::StatusCode ClearStickyFault_FusedSensorOutOfSync()
Clear sticky fault: The remote sensor used for fusion has fallen out of sync to the local sensor.
Definition CoreTalonFX.hpp:2948
ctre::phoenix::StatusCode ClearStickyFault_DeviceTemp(units::time::second_t timeoutSeconds)
Clear sticky fault: Device temperature exceeded limit.
ctre::phoenix::StatusCode Apply(const CurrentLimitsConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1200
ctre::phoenix::StatusCode ClearStickyFault_MissingSoftLimitRemote()
Clear sticky fault: The remote soft limit device is not present on CAN Bus.
Definition CoreTalonFX.hpp:2840
ctre::phoenix::StatusCode ClearStickyFault_ReverseHardLimit(units::time::second_t timeoutSeconds)
Clear sticky fault: Reverse limit switch has been asserted.
ctre::phoenix::StatusCode ClearStickyFault_UsingFusedCANcoderWhileUnlicensed(units::time::second_t timeoutSeconds)
Clear sticky fault: Using Fused CANcoder feature while unlicensed.
ctre::phoenix::StatusCode Refresh(DifferentialConstantsConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1468
ctre::phoenix::StatusCode ClearStickyFault_BootDuringEnable(units::time::second_t timeoutSeconds)
Clear sticky fault: Device boot while detecting the enable signal.
ctre::phoenix::StatusCode Apply(const HardwareLimitSwitchConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1680
ctre::phoenix::StatusCode Apply(const VoltageConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1246
ctre::phoenix::StatusCode Apply(const FeedbackConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1366
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorReset()
Clear sticky fault: The remote sensor has reset.
Definition CoreTalonFX.hpp:2538
ctre::phoenix::StatusCode Refresh(DifferentialConstantsConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1455
ctre::phoenix::StatusCode ClearStickyFault_MissingDifferentialFX()
Clear sticky fault: The remote Talon used for differential control is not present on CAN Bus.
Definition CoreTalonFX.hpp:2570
ctre::phoenix::StatusCode Refresh(Slot0Configs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:2008
ctre::phoenix::StatusCode Refresh(TalonFXConfiguration &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1033
ctre::phoenix::StatusCode Apply(const TorqueCurrentConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1306
ctre::phoenix::StatusCode Apply(const DifferentialSensorsConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1440
ctre::phoenix::StatusCode ClearStickyFault_MissingSoftLimitRemote(units::time::second_t timeoutSeconds)
Clear sticky fault: The remote soft limit device is not present on CAN Bus.
ctre::phoenix::StatusCode Refresh(HardwareLimitSwitchConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1648
ctre::phoenix::StatusCode Apply(const MotorOutputConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1140
ctre::phoenix::StatusCode ClearStickyFault_ReverseHardLimit()
Clear sticky fault: Reverse limit switch has been asserted.
Definition CoreTalonFX.hpp:2708
ctre::phoenix::StatusCode Refresh(SlotConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:2188
ctre::phoenix::StatusCode Refresh(ClosedLoopRampsConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1575
ctre::phoenix::StatusCode Refresh(MotorOutputConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1095
ctre::phoenix::StatusCode Apply(const OpenLoopRampsConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1560
ctre::phoenix::StatusCode Refresh(MotionMagicConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1828
ctre::phoenix::StatusCode Apply(const FeedbackConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1380
ctre::phoenix::StatusCode Refresh(CurrentLimitsConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1168
ctre::phoenix::StatusCode Apply(const AudioConfigs &configs, units::time::second_t timeoutSeconds)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1740
ctre::phoenix::StatusCode ClearStickyFault_SupplyCurrLimit(units::time::second_t timeoutSeconds)
Clear sticky fault: Supply current limit occured.
ctre::phoenix::StatusCode Apply(const CurrentLimitsConfigs &configs)
Applies the contents of the specified config to the device.
Definition CoreTalonFX.hpp:1186
ctre::phoenix::StatusCode Refresh(TorqueCurrentConfigs &configs, units::time::second_t timeoutSeconds) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1288
ctre::phoenix::StatusCode ClearStickyFault_RotorFault2(units::time::second_t timeoutSeconds)
Clear sticky fault: Trips if a major mechanical or ESD event caused a brief loss of position data tri...
ctre::phoenix::StatusCode Refresh(HardwareLimitSwitchConfigs &configs) const
Refreshes the values of the specified config group.
Definition CoreTalonFX.hpp:1635
ctre::phoenix::StatusCode ClearStickyFault_ForwardHardLimit(units::time::second_t timeoutSeconds)
Clear sticky fault: Forward limit switch has been asserted.
Configs that affect Torque Current control types.
Definition TorqueCurrentConfigs.hpp:25
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Configs that affect Voltage control types.
Definition VoltageConfigs.hpp:25
std::string Serialize() const final
ctre::phoenix::StatusCode Deserialize(std::string const &to_deserialize) final
Definition DeviceIdentifier.hpp:16
Parent class for all devices.
Definition ParentDevice.hpp:23
Class description for the Talon FX integrated motor controller.
Definition CoreTalonFX.hpp:3187
ctre::phoenix::StatusCode ClearStickyFault_UsingFusedCANcoderWhileUnlicensed(units::time::second_t timeoutSeconds) final
Clear sticky fault: Using Fused CANcoder feature while unlicensed.
Definition CoreTalonFX.hpp:10024
ctre::phoenix::StatusCode ClearStickyFault_Undervoltage(units::time::second_t timeoutSeconds) final
Clear sticky fault: Device supply voltage dropped to near brownout levels.
Definition CoreTalonFX.hpp:9556
ctre::phoenix::StatusCode ClearStickyFault_UnlicensedFeatureInUse(units::time::second_t timeoutSeconds) final
Clear sticky fault: An unlicensed feature is in use, device may not behave as expected.
Definition CoreTalonFX.hpp:9604
ctre::phoenix::StatusCode ClearStickyFault_StatorCurrLimit(units::time::second_t timeoutSeconds) final
Clear sticky fault: Stator current limit occured.
Definition CoreTalonFX.hpp:9979
ctre::phoenix::StatusCode ClearStickyFault_MissingDifferentialFX() final
Clear sticky fault: The remote Talon used for differential control is not present on CAN Bus.
Definition CoreTalonFX.hpp:9686
ctre::phoenix::StatusCode ClearStickyFault_Hardware(units::time::second_t timeoutSeconds) final
Clear sticky fault: Hardware fault occurred.
Definition CoreTalonFX.hpp:9489
ctre::phoenix::StatusCode ClearStickyFault_MissingSoftLimitRemote(units::time::second_t timeoutSeconds) final
Clear sticky fault: The remote soft limit device is not present on CAN Bus.
Definition CoreTalonFX.hpp:9872
ctre::phoenix::StatusCode ClearStickyFault_SupplyCurrLimit() final
Clear sticky fault: Supply current limit occured.
Definition CoreTalonFX.hpp:10012
ctre::phoenix::StatusCode ClearStickyFault_RotorFault1() final
Clear sticky fault: Trips if a major mechanical or ESD event caused a brief loss of position data tri...
Definition CoreTalonFX.hpp:10088
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorPosOverflow(units::time::second_t timeoutSeconds) final
Clear sticky fault: The remote sensor position has overflowed.
Definition CoreTalonFX.hpp:9701
ctre::phoenix::StatusCode ClearStickyFault_StaticBrakeDisabled() final
Clear sticky fault: Static brake was momentarily disabled due to excessive braking current while disa...
Definition CoreTalonFX.hpp:10060
configs::TalonFXConfigurator const & GetConfigurator() const
Gets the configurator for this TalonFX.
Definition CoreTalonFX.hpp:3243
ctre::phoenix::StatusCode SetPosition(units::angle::turn_t newValue) final
Sets the mechanism position of the device in mechanism rotations.
Definition CoreTalonFX.hpp:9448
ctre::phoenix::StatusCode ClearStickyFault_UnstableSupplyV() final
Clear sticky fault: Supply Voltage is unstable.
Definition CoreTalonFX.hpp:9764
ctre::phoenix::StatusCode ClearStickyFault_FusedSensorOutOfSync(units::time::second_t timeoutSeconds) final
Clear sticky fault: The remote sensor used for fusion has fallen out of sync to the local sensor.
Definition CoreTalonFX.hpp:9953
ctre::phoenix::StatusCode ClearStickyFault_ReverseSoftLimit(units::time::second_t timeoutSeconds) final
Clear sticky fault: Reverse soft limit has been asserted.
Definition CoreTalonFX.hpp:9824
ctre::phoenix::StatusCode ClearStickyFault_RotorFault1(units::time::second_t timeoutSeconds) final
Clear sticky fault: Trips if a major mechanical or ESD event caused a brief loss of position data tri...
Definition CoreTalonFX.hpp:10074
ctre::phoenix::StatusCode ClearStickyFault_BridgeBrownout(units::time::second_t timeoutSeconds) final
Clear sticky fault: Bridge was disabled most likely due to supply voltage dropping too low.
Definition CoreTalonFX.hpp:9628
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorPosOverflow() final
Clear sticky fault: The remote sensor position has overflowed.
Definition CoreTalonFX.hpp:9716
ctre::phoenix::StatusCode ClearStickyFault_MissingSoftLimitRemote() final
Clear sticky fault: The remote soft limit device is not present on CAN Bus.
Definition CoreTalonFX.hpp:9884
ctre::phoenix::StatusCode ClearStickyFault_RotorFault2() final
Clear sticky fault: Trips if a major mechanical or ESD event caused a brief loss of position data tri...
Definition CoreTalonFX.hpp:10116
ctre::phoenix::StatusCode ClearStickyFault_MissingHardLimitRemote(units::time::second_t timeoutSeconds) final
Clear sticky fault: The remote limit switch device is not present on CAN Bus.
Definition CoreTalonFX.hpp:9896
ctre::phoenix::StatusCode ClearStickyFault_ProcTemp(units::time::second_t timeoutSeconds) final
Clear sticky fault: Processor temperature exceeded limit.
Definition CoreTalonFX.hpp:9511
ctre::phoenix::StatusCode ClearStickyFault_OverSupplyV() final
Clear sticky fault: Supply Voltage has exceeded the maximum voltage rating of device.
Definition CoreTalonFX.hpp:9740
ctre::phoenix::StatusCode ClearStickyFault_Undervoltage() final
Clear sticky fault: Device supply voltage dropped to near brownout levels.
Definition CoreTalonFX.hpp:9568
ctre::phoenix::StatusCode ClearStickyFault_ForwardHardLimit() final
Clear sticky fault: Forward limit switch has been asserted.
Definition CoreTalonFX.hpp:9812
ctre::phoenix::StatusCode ClearStickyFault_MissingDifferentialFX(units::time::second_t timeoutSeconds) final
Clear sticky fault: The remote Talon used for differential control is not present on CAN Bus.
Definition CoreTalonFX.hpp:9674
ctre::phoenix::StatusCode ClearStickyFault_OverSupplyV(units::time::second_t timeoutSeconds) final
Clear sticky fault: Supply Voltage has exceeded the maximum voltage rating of device.
Definition CoreTalonFX.hpp:9728
ctre::phoenix::StatusCode ClearStickyFault_DeviceTemp(units::time::second_t timeoutSeconds) final
Clear sticky fault: Device temperature exceeded limit.
Definition CoreTalonFX.hpp:9533
ctre::phoenix::StatusCode ClearStickyFault_DeviceTemp() final
Clear sticky fault: Device temperature exceeded limit.
Definition CoreTalonFX.hpp:9544
CoreTalonFX(int deviceId, std::string canbus)
Constructs a new Talon FX motor controller object.
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorDataInvalid(units::time::second_t timeoutSeconds) final
Clear sticky fault: The remote sensor's data is no longer trusted.
Definition CoreTalonFX.hpp:9923
ctre::phoenix::StatusCode ClearStickyFault_FusedSensorOutOfSync() final
Clear sticky fault: The remote sensor used for fusion has fallen out of sync to the local sensor.
Definition CoreTalonFX.hpp:9968
ctre::phoenix::StatusCode ClearStickyFault_RotorFault2(units::time::second_t timeoutSeconds) final
Clear sticky fault: Trips if a major mechanical or ESD event caused a brief loss of position data tri...
Definition CoreTalonFX.hpp:10102
ctre::phoenix::StatusCode ClearStickyFault_ReverseSoftLimit() final
Clear sticky fault: Reverse soft limit has been asserted.
Definition CoreTalonFX.hpp:9836
configs::TalonFXConfigurator & GetConfigurator()
Gets the configurator for this TalonFX.
Definition CoreTalonFX.hpp:3231
ctre::phoenix::StatusCode ClearStickyFault_ReverseHardLimit() final
Clear sticky fault: Reverse limit switch has been asserted.
Definition CoreTalonFX.hpp:9788
ctre::phoenix::StatusCode ClearStickyFault_ForwardSoftLimit(units::time::second_t timeoutSeconds) final
Clear sticky fault: Forward soft limit has been asserted.
Definition CoreTalonFX.hpp:9848
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorReset(units::time::second_t timeoutSeconds) final
Clear sticky fault: The remote sensor has reset.
Definition CoreTalonFX.hpp:9651
ctre::phoenix::StatusCode ClearStickyFault_MissingHardLimitRemote() final
Clear sticky fault: The remote limit switch device is not present on CAN Bus.
Definition CoreTalonFX.hpp:9908
ctre::phoenix::StatusCode ClearStickyFault_UnstableSupplyV(units::time::second_t timeoutSeconds) final
Clear sticky fault: Supply Voltage is unstable.
Definition CoreTalonFX.hpp:9752
ctre::phoenix::StatusCode ClearStickyFault_Hardware() final
Clear sticky fault: Hardware fault occurred.
Definition CoreTalonFX.hpp:9500
ctre::phoenix::StatusCode ClearStickyFault_BootDuringEnable() final
Clear sticky fault: Device boot while detecting the enable signal.
Definition CoreTalonFX.hpp:9592
ctre::phoenix::StatusCode ClearStickyFault_UnlicensedFeatureInUse() final
Clear sticky fault: An unlicensed feature is in use, device may not behave as expected.
Definition CoreTalonFX.hpp:9616
ctre::phoenix::StatusCode ClearStickyFault_ForwardSoftLimit() final
Clear sticky fault: Forward soft limit has been asserted.
Definition CoreTalonFX.hpp:9860
ctre::phoenix::StatusCode ClearStickyFault_ForwardHardLimit(units::time::second_t timeoutSeconds) final
Clear sticky fault: Forward limit switch has been asserted.
Definition CoreTalonFX.hpp:9800
ctre::phoenix::StatusCode ClearStickyFault_StaticBrakeDisabled(units::time::second_t timeoutSeconds) final
Clear sticky fault: Static brake was momentarily disabled due to excessive braking current while disa...
Definition CoreTalonFX.hpp:10048
ctre::phoenix::StatusCode ClearStickyFault_SupplyCurrLimit(units::time::second_t timeoutSeconds) final
Clear sticky fault: Supply current limit occured.
Definition CoreTalonFX.hpp:10001
ctre::phoenix::StatusCode ClearStickyFault_UsingFusedCANcoderWhileUnlicensed() final
Clear sticky fault: Using Fused CANcoder feature while unlicensed.
Definition CoreTalonFX.hpp:10036
ctre::phoenix::StatusCode ClearStickyFault_BootDuringEnable(units::time::second_t timeoutSeconds) final
Clear sticky fault: Device boot while detecting the enable signal.
Definition CoreTalonFX.hpp:9580
ctre::phoenix::StatusCode ClearStickyFault_BridgeBrownout() final
Clear sticky fault: Bridge was disabled most likely due to supply voltage dropping too low.
Definition CoreTalonFX.hpp:9640
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorReset() final
Clear sticky fault: The remote sensor has reset.
Definition CoreTalonFX.hpp:9662
StatusSignal< int > & GetVersionMajor(bool refresh=true) final
App Major Version number.
ctre::phoenix::StatusCode ClearStickyFault_StatorCurrLimit() final
Clear sticky fault: Stator current limit occured.
Definition CoreTalonFX.hpp:9990
CoreTalonFX(int deviceId, CANBus canbus={})
Constructs a new Talon FX motor controller object.
ctre::phoenix::StatusCode ClearStickyFault_ProcTemp() final
Clear sticky fault: Processor temperature exceeded limit.
Definition CoreTalonFX.hpp:9522
sim::TalonFXSimState & GetSimState()
Get the simulation state for this device.
Definition CoreTalonFX.hpp:3261
ctre::phoenix::StatusCode ClearStickyFaults() final
Clear the sticky faults in the device.
Definition CoreTalonFX.hpp:9478
ctre::phoenix::StatusCode ClearStickyFault_RemoteSensorDataInvalid() final
Clear sticky fault: The remote sensor's data is no longer trusted.
Definition CoreTalonFX.hpp:9938
ctre::phoenix::StatusCode ClearStickyFault_ReverseHardLimit(units::time::second_t timeoutSeconds) final
Clear sticky fault: Reverse limit switch has been asserted.
Definition CoreTalonFX.hpp:9776
ctre::phoenix::StatusCode ClearStickyFaults(units::time::second_t timeoutSeconds) final
Clear the sticky faults in the device.
Definition CoreTalonFX.hpp:9463
Contains everything common between Talon motor controllers that support FOC (requires Phoenix Pro).
Definition CommonTalonWithFOC.hpp:28
Class to control the state of a simulated hardware::TalonFX.
Definition TalonFXSimState.hpp:40
Status codes reported by APIs, including OK, warnings, and errors.
Definition StatusCodes.h:28
Definition motor_constants.h:14