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