Enum ctre_sys::ErrorCode[][src]

#[repr(i32)]
pub enum ErrorCode { OK, CAN_MSG_STALE, TxFailed, InvalidParamValue, RxTimeout, TxTimeout, UnexpectedArbId, BufferFull, CAN_OVERFLOW, SensorNotPresent, FirmwareTooOld, CouldNotChangePeriod, GeneralError, SigNotUpdated, NotAllPIDValuesUpdated, GEN_PORT_ERROR, PORT_MODULE_TYPE_MISMATCH, GEN_MODULE_ERROR, MODULE_NOT_INIT_SET_ERROR, MODULE_NOT_INIT_GET_ERROR, WheelRadiusTooSmall, TicksPerRevZero, DistanceBetweenWheelsTooSmall, GainsAreNotSet, IncompatibleMode, InvalidHandle, FeatureRequiresHigherFirm, TalonFeatureRequiresHigherFirm, PulseWidthSensorNotPresent, GeneralWarning, FeatureNotSupported, NotImplemented, FirmVersionCouldNotBeRetrieved, FeaturesNotAvailableYet, ControlModeNotValid, ControlModeNotSupportedYet, AuxiliaryPIDNotSupportedYet, RemoteSensorsNotSupportedYet, MotProfFirmThreshold, MotProfFirmThreshold2, }

Variants

No Error - Function executed as expected

Could not transmit the CAN frame.

Caller passed an invalid param

CAN frame has not been received within specified period of time.

Not used.

Specified CAN Id is invalid.

Caller attempted to insert data into a buffer that is full.

Sensor is not present

User Specified General Error

Have not received an value response for signal.

Handle does not match stored map of handles

Special Code for "isSensorPresent"

feature not implement in the API or firmware

feature not implement in the API

feature will be release in an upcoming release

Current control mode of motor controller not valid for this call

Methods

impl ErrorCode
[src]

Returns true if the error code is OK.

Returns true if the error code is not OK.

Returns err if self is OK, otherwise returns self. Intended for use by the ctre crate only.

Returns an Ok if the error code is OK, or an Err otherwise.

Trait Implementations

impl Debug for ErrorCode
[src]

Formats the value using the given formatter. Read more

impl Copy for ErrorCode
[src]

impl Clone for ErrorCode
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl PartialEq for ErrorCode
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl Eq for ErrorCode
[src]

impl Hash for ErrorCode
[src]

Feeds this value into the given [Hasher]. Read more

Feeds a slice of this type into the given [Hasher]. Read more

impl Error for ErrorCode
[src]

This method is soft-deprecated. Read more

The lower-level cause of this error, if any. Read more

impl Display for ErrorCode
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl Send for ErrorCode

impl Sync for ErrorCode