mirror of
https://github.com/odriverobotics/ODrive.git
synced 2026-09-21 23:44:48 +08:00
Set default configuration of endstops to configuration 4
This commit is contained in:
@@ -10,7 +10,7 @@ class Endstop {
|
||||
uint16_t gpio_num = 0;
|
||||
bool enabled = false;
|
||||
bool is_active_high = false;
|
||||
bool pullup = false;
|
||||
bool pullup = true;
|
||||
};
|
||||
|
||||
explicit Endstop(Endstop::Config_t& config);
|
||||
|
||||
+8
-4
@@ -12,10 +12,11 @@ Each axis supports two endstops: `min_endstop` and `max_endstop`. For each ends
|
||||
Name | Type | Default
|
||||
--- | -- | --
|
||||
gpio_num | int | 0
|
||||
enabled | boolean | False
|
||||
offset | int | 0
|
||||
debounce_ms | float | 100.0
|
||||
is_active_high | boolean | False
|
||||
offset | float | 0.0
|
||||
debounce_ms | float | 50.0
|
||||
enabled | boolean | false
|
||||
is_active_high | boolean | false
|
||||
pullup | boolean | true
|
||||
|
||||
### gpio_num
|
||||
The GPIO pin number, according to the silkscreen labels on ODrive. Set with these commands:
|
||||
@@ -53,6 +54,9 @@ This is how you configure the endstop to be either "NPN" or "PNP". An "NPN" con
|
||||
|
||||
3D printer endstops (like those that come with a RAMPS 1.4) are typically configuration **4**.
|
||||
|
||||
### pullup
|
||||
Match the pullup value to the configuration. If `true`, it enables the GPIO pullup resistor. If `false`, it enables the GPIO pull*down* resistor.
|
||||
|
||||

|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user