1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
pub mod errors;
#[repr(u8)]
#[derive(Debug, Ord, PartialOrd, Eq, PartialEq, Copy, Clone)]
pub enum Axis {
Zero = 0,
One = 1,
}
#[repr(u8)]
#[derive(Debug, Ord, PartialOrd, Eq, PartialEq, Copy, Clone)]
pub enum AxisState {
Undefined = 0,
Idle = 1,
StartupSequence = 2,
FullCalibrationSequence = 3,
MotorCalibration = 4,
SensorlessControl = 5,
EncoderIndexSearch = 6,
EncoderOffsetCalibration = 7,
ClosedLoopControl = 8,
}
#[repr(u8)]
#[derive(Debug, Ord, PartialOrd, Eq, PartialEq, Copy, Clone)]
pub enum MotorType {
HighCurrent = 0,
MotorTypeGimbal = 2,
}
#[repr(u8)]
#[derive(Debug, Ord, PartialOrd, Eq, PartialEq, Copy, Clone)]
pub enum ControlMode {
VoltageControl = 0,
CurrentControl = 1,
VelocityControl = 2,
PositionControl = 3,
TrajectoryControl = 4,
}
#[repr(u8)]
#[derive(Debug, Ord, PartialOrd, Eq, PartialEq, Copy, Clone)]
pub enum EncoderMode {
EncoderModeIncremental = 0,
EncoderModeHall = 1,
}