Commit d9e16a6
authored
Cleaned up mrc_port (wpilibsuite#257)
* In mrc_port.ts.
- Added constants for port types.
- Added constants for field prefixes.
- Added constants for visible port labels.
- Removed type MrcPortType, ports_ from PortMixin, and ports from PortExtraState.
- Renamed PortMixin portType_ to mrcPortType.
- Added mrcPortCount to PortMixin.
- Rewrote loadExtraState to create the appropriate fields for the portType.
- Removed updateShape.
- Simplified the code in pythonFromBlock that collects the ports.
- Generate code for CompoundPort without trailing backslashes.
- Changed Order.ATOMIC to Order.FUNCTION_CALL.
- Updated createPort to specify the field values.
In field_number_dropdown.ts:
Removed defaultVal parameter in createFieldNumberDropdown function.
In external_samples/port.py:
Replace PortType enum value BASE_COMPOUND with a module variable named _base_compound.
Removed PortType enum value SERVO_PORT.
Added PortType enum value USB_HUB_PORT.
Removed external_samples/servo.py.
* Changed _base_compound to _BASE_COMPOUND.
* Removed SMART_MOTOR_PORT. Added a TODO comment about adding port for MotionCore.1 parent f002bce commit d9e16a6
File tree
6 files changed
+168
-419
lines changed- external_samples
- python_tools
- src
- blocks
- utils/generated
- fields
6 files changed
+168
-419
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
20 | | - | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
21 | 23 | | |
22 | 24 | | |
| 25 | + | |
23 | 26 | | |
24 | 27 | | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
31 | 36 | | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
36 | 41 | | |
37 | 42 | | |
38 | 43 | | |
| |||
58 | 63 | | |
59 | 64 | | |
60 | 65 | | |
61 | | - | |
| 66 | + | |
62 | 67 | | |
63 | 68 | | |
64 | 69 | | |
| |||
80 | 85 | | |
81 | 86 | | |
82 | 87 | | |
83 | | - | |
| 88 | + | |
84 | 89 | | |
85 | 90 | | |
86 | 91 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
66 | | - | |
67 | 66 | | |
68 | 67 | | |
69 | 68 | | |
| |||
126 | 125 | | |
127 | 126 | | |
128 | 127 | | |
129 | | - | |
130 | 128 | | |
131 | 129 | | |
132 | 130 | | |
| |||
0 commit comments