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