-
-
Notifications
You must be signed in to change notification settings - Fork 398
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ERR: Setting up pin [gpio.19] failed. Details: Pin is already used #309
Comments
My config file...
|
Sorry, and here's my original machine file from esp32 grbl.
|
Try removing the reset_pin: definition from the x motor1, y motor0 and z motor0 sections. |
FluidNC lets you define a per-motor reset pin but not a shared one, whereas Grbl_Esp32 only had a shared one. That is the cause of the confusion. We need to think about what to do about this. So far you are the first person to notice it, which just shows how rarely the stepper reset feature is used. |
Thanks for that. I have done that. I'm getting something different now.. "An umexpected command" at the bottom.
|
What terminal are you using. Is that part of a gcode sender? I don't think that error text comes from FluidNC. It might be that the sender got an extra "ok" that it was not expecting. Did you also have the WebUI open? |
Ok thanks guys, I'm still seeing some odd stuff. I got another GPIO 19 error so I deleted reset_pin: gpio.19 in motor0 as well as the others.
Not sure what to make of this yet. |
Not sure why it rebooted, but you have some errors and warnings in your config file. That could be the cause. Can you post your current config file here? |
Sure thanks.
```
name: XXYZ_4XInput_4XInput_Relay_Spindle_5VOutput_ExtSteppers2
board: 6-pack
kinematics:
Cartesian:
stepping:
engine: I2S_stream
idle_ms: 250
dir_delay_us: 0
pulse_us: 4
disable_delay_us: 0
axes:
x:
steps_per_mm: 100.000
max_rate_mm_per_min: 1000.000
acceleration_mm_per_sec2: 200.000
max_travel_mm: 300.000
soft_limits: false
motor0:
limit_all_pin: gpio.33:low
hard_limits: false
stepstick:
direction_pin: i2so.1
step_pin: i2so.2
disable_pin: i2so.0
motor1:
stepstick:
direction_pin: i2so.4
step_pin: i2so.5
disable_pin: i2so.7
y:
steps_per_mm: 100.000
max_rate_mm_per_min: 1000.000
acceleration_mm_per_sec2: 200.000
max_travel_mm: 300.000
soft_limits: false
motor0:
limit_all_pin: gpio.32:low
hard_limits: false
stepstick:
direction_pin: i2so.9
step_pin: i2so.10
disable_pin: i2so.8
motor1:
null_motor:
z:
steps_per_mm: 100.000
max_rate_mm_per_min: 1000.000
acceleration_mm_per_sec2: 200.000
max_travel_mm: 300.000
soft_limits: false
motor0:
limit_all_pin: gpio.35:low
hard_limits: false
stepstick:
direction_pin: i2so.12
step_pin: i2so.13
disable_pin: i2so.15
motor1:
null_motor:
a:
steps_per_mm: 100.000
max_rate_mm_per_min: 1000.000
acceleration_mm_per_sec2: 200.000
max_travel_mm: 300.000
soft_limits: false
motor0:
null_motor:
motor1:
null_motor:
b:
steps_per_mm: 100.000
max_rate_mm_per_min: 1000.000
acceleration_mm_per_sec2: 200.000
max_travel_mm: 300.000
soft_limits: false
motor0:
null_motor:
motor1:
null_motor:
c:
steps_per_mm: 100.000
max_rate_mm_per_min: 1000.000
acceleration_mm_per_sec2: 200.000
max_travel_mm: 300.000
soft_limits: false
motor0:
null_motor:
motor1:
null_motor:
i2so:
bck_pin: gpio.22
data_pin: gpio.21
ws_pin: gpio.17
spi:
miso_pin: gpio.19
mosi_pin: gpio.23
sck_pin: gpio.18
sdcard:
cs_pin: gpio.5
control:
coolant:
flood_pin: i2so.27
mist_pin: i2so.26
delay_ms: 1000.000
probe:
pin: gpio.34:pu
check_mode_start: false
macros:
startup_line0:
startup_line1:
macro0:
macro1:
macro2:
macro3:
start:
must_home: true
check_limits: true
deactivate_parking: false
user_outputs:
laser:
spinup_ms: 0
spindown_ms: 0
tool_num: 0
speeds: 0=0.0% 1000=100.0%
direction_pin: gpio.0
disable_with_s0: false
s0_with_disable: false
pwm_hz: 0
arc_tolerance_mm: 0.002
junction_deviation_mm: 0.010
verbose_errors: false
report_inches: false
enable_parking_override_control: false
use_line_numbers: false
```
|
The crash was do to the pwm_hz: 0. I fixed it by enforcing a range for that value. See this branch https://github.com/bdring/FluidNC/tree/ConstrainConfigValues |
* Constrain config values Laser pwm_hz was not range checked and constrained. That caused crashes when it was 0. Added a constrain with message to handler.item. unit32_t and float Updated the classes that were separately constraining to use this method. * Use hardware limiting values for PWM frequency. Co-authored-by: bdring <barton.dring@gmail.com>
What's with the 's' at the end of that line? |
Added axes/shared_stepper_reset_pin #309
Read this wiki page. https://github.com/bdring/FluidNC/wiki/FluidNC-Homing#axis-squaring It is best to define the switches of the neg or pos pins, depending on the homing direction. |
Thanks, I have the ganged motors with one switch so it looks like I need to add another switch. Is that correct? |
If you want it to square, yes. |
* Constrain config values Laser pwm_hz was not range checked and constrained. That caused crashes when it was 0. Added a constrain with message to handler.item. unit32_t and float Updated the classes that were separately constraining to use this method. * Use hardware limiting values for PWM frequency. Co-authored-by: bdring <barton.dring@gmail.com>
Guys thanks for the progressive work on FluidNC. I'm moving from esp32 grbl and have my automated config.yaml (made from your automated service) uploaded however I'm getting some errors.
I'm also using the precompiled method for simplicity.
I might be missing a step. I have so far:
What am I missing thanks.
The text was updated successfully, but these errors were encountered: