-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathids.py
69 lines (43 loc) · 1.07 KB
/
ids.py
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
import enum
@enum.unique
class TalonId(enum.IntEnum):
"""CAN ID for CTRE Talon motor controllers (e.g. Talon FX, Talon SRX)."""
DRIVE_FL = 1
STEER_FL = 5
DRIVE_RL = 2
STEER_RL = 6
DRIVE_RR = 3
STEER_RR = 7
DRIVE_FR = 4
STEER_FR = 8
FLYWHEEL_1 = 9
FLYWHEEL_2 = 10
@enum.unique
class CancoderId(enum.IntEnum):
"""CAN ID for CTRE CANcoder."""
SWERVE_FL = 1
SWERVE_RL = 2
SWERVE_RR = 3
SWERVE_FR = 4
@enum.unique
class SparkId(enum.IntEnum):
"""CAN ID for REV SPARK motor controllers (Spark Max, Spark Flex)."""
CORAL_PLACER = 20
INJECTOR_1 = 10
INJECTOR_2 = 11
WRIST = 5
@enum.unique
class DioChannel(enum.IntEnum):
"""roboRIO Digital I/O channel number."""
VISION_ENCODER = 1
ALGAE_INTAKE_SWITCH = 2
WRIST_LIMIT_SWITCH = 3
@enum.unique
class PwmChannel(enum.IntEnum):
"""roboRIO PWM output channel number."""
VISION_SERVO = 0
@enum.unique
class RioSerialNumber(enum.StrEnum):
"""roboRIO serial number"""
TEST_BOT = "0305cc42"
COMP_BOT = "03062898"