Wiki Search Terms
door homing
Controller Board
6x CNC Controller
Machine Description
4 axis CNC using stepperonline NEMA 23 closed loop motors with CL57T-V41 drivers, with 1.5kW china spindle on a Siemens V20 VFD
Input Circuits
homing limit switches on all axis normally open
safety door pin on a "stop switch", normally open
resume button on cyclestartpin, normally openhoming working fine, safety door action working in normal operation as expected.
Configuration file
board: 6 Pack CNC by Bart Dring
name: JaRa CNC
meta: 2025-05-15 RMk RS485 + FLuidDialmacros:
after_homing: G53G00X520Y-165Z130
control:
STOP Taste
safetydoorpin: gpio.35:low
Start Taste:
cyclestartpin: gpio.34:low
#Home Taste:
homingbuttonpin: gpio.39:low
FU + Motortreiber WARN
fault_pin: gpio.2:low:pu resetpin: NOPIN
fault_pin: gpio.36
feedholdpin: gpio.2:low:pu
status_outputs:
LED Start
hold_pin: I2SO.23
LED Home:
run_pin: I2SO.21i2so:
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:
carddetectpin: NO_PIN
cs_pin: gpio.5
start:
must_home: true
parking:
enable: true
axis: Z
pulloutdistancemm: 20.000
pulloutratemmpermin: 250.000
targetmposmm: 120.000
ratemmper_min: 800.000
UART for FluidDial
uart2:
txd_pin: gpio.27
rxd_pin: gpio.25
rtspin: NOPIN
ctspin: NOPIN
baud: 1000000
mode: 8N1uart_channel1:
reportintervalms: 200
uart_num: 2
message_level: debug
#UART for RS485
#uart1:
txd_pin: gpio.15
rxd_pin: gpio.16
rts_pin: gpio.14
ctspin: NOPIN
baud: 9600
mode: 8E1
#use correct UART!
#ModbusVFD:
see https://support.industry.siemens.com/cs/mdm/109824500?c=160470548491&dl=nl&lc=en-US
debug: 3
uart_num: 1
modbus_id: 1
model: SiemensV20
ccw_cmd: 06 00 63 0c 7f > echo
cw_cmd: 06 00 63 04 7f > echo # maybe ccw and cw are flipped
off_cmd: 06 00 63 0c 7e > echo
setrpmcmd: 06 00 64 rpm > echo
getrpmcmd: 03 00 6e 00 01 > 03 02 rpm
getmaxrpm_cmd: 03 00 0F 00 01 > 03 02 maxrpm*6/10 # this uses the base RPM and works
getmaxrpm_cmd: 03 10 82 00 01 > 03 02 rpm*60/100
getminrpm_cmd: 03 10 80 00 01 > 03 02 rpm*60/100
getmaxrpm_cmd: 03 01 69 00 01 > 03 02 maxrpm*6/10
getminrpm_cmd: 03 01 68 00 01 > 03 02 minrpm*6/10
speed_map: 0=0% 1=12.5% 3000=37.5% 9000=37.5% 24000=100%
offonalarm: true
SiemensV20:
debug: 3
uart:
txd_pin: gpio.15
rxd_pin: gpio.16
rts_pin: gpio.14
baud: 9600
mode: 8E1
modbus_id: 1
tool_num: 0
spinup_ms: 5000
spindown_ms: 10000
speed_map: 0=0% 1=12.5% 3000=37.5% 9000=37.5% 24000=100%
offonalarm: true
poll_ms: 2000 # to be changed later, we use 2s right now only to reduce the debug output
disablewiths0: true
s0withdisable: true
#10V:
forwardpin: NOPIN
reversepin: NOPIN
pwm_hz: 15000
output_pin: gpio.13
enable_pin: gpio.15
direction_pin: gpio.14:low
disablewiths0: false
s0withdisable: true
spinup_ms: 1500
spindown_ms: 1500
tool_num: 0
speed_map: 0=0.000% 1000=0.000% 24000=100.000%
speed_map: 0=0% 1=12.5% 3000=37.5% 9000=37.5% 24000=100%
offonalarm: true
stepping:
engine: I2S_STREAM
#we never disable the output pins automatically, so set to 255
idle_ms: 255
the CL57T can handle stepping frequencies up to 200 kHz, so in theory 2.5us pulses should be possible.
other sources claim 500kHz, so we could go with 1us pulses
5 limits to 100kHz
pulse_us: 6
dirdelayus: 6
disabledelayus: 0
segments: 6axes:
sharedstepperdisablepin: NOPIN
homing_runs: 2
x:
stepspermm: 1000.0
maxratemmpermin: 2200.000
accelerationmmper_sec2: 50.000
maxtravelmm: 555.000
soft_limits: true
homing:
cycle: 2
positive_direction: false
mpos_mm: 0.000
feedmmper_min: 50.000
seekmmper_min: 500.000
settle_ms: 250
seek_scaler: 1.100
feed_scaler: 1.100
motor0:
limitnegpin: gpio.33:low:pu
limitpospin: NO_PIN
limitallpin: NO_PIN
hard_limits: false
pulloff_mm: 1.500
standard_stepper:
step_pin: I2SO.2
direction_pin: I2SO.1
disable_pin: I2SO.0
y:
stepspermm: 1000.000
maxratemmpermin: 2000.000
accelerationmmper_sec2: 50.000
maxtravelmm: 410.000
soft_limits: true
homing:
cycle: 2
positive_direction: true
mpos_mm: 0.000
feedmmper_min: 50.000
seekmmper_min: 500.000
settle_ms: 250
seek_scaler: 1.100
feed_scaler: 1.100
motor0:
limitnegpin: gpio.26:low:pu
limitpospin: NO_PIN
limitallpin: NO_PIN
hard_limits: false
pulloff_mm: 1.500
standard_stepper:
step_pin: I2SO.5
direction_pin: I2SO.4
disable_pin: I2SO.7
z:
stepspermm: 1000.000
maxratemmpermin: 2000.000
accelerationmmper_sec2: 25.000
maxtravelmm: 380.000
soft_limits: true
homing:
cycle: 1
positive_direction: true
mpos_mm: 140.000
feedmmper_min: 50.000
seekmmper_min: 400.000
settle_ms: 250
seek_scaler: 1.100
feed_scaler: 1.100
motor0:
limitnegpin: NO_PIN
limitpospin: gpio.32:low:pu
limitallpin: NO_PIN
hard_limits: false
pulloff_mm: 1.500
standard_stepper:
step_pin: I2SO.10
direction_pin: I2SO.9
disable_pin: I2SO.8
a:
stepspermm: 142.22222222222222
maxratemmpermin: 2000.000
accelerationmmper_sec2: 100.000
maxtravelmm: 960.000
soft_limits: false
homing:
cycle: -1
motor0:
limitnegpin: NO_PIN
limitpospin: NO_PIN
limitallpin: NO_PIN
hard_limits: false
pulloff_mm: 1.500
standard_stepper:
step_pin: I2SO.13
direction_pin: I2SO.12
disable_pin: I2SO.15
Startup Messages
$G
[GC:G0 G54 G17 G21 G90 G94 M5 M9 T0 F0 S0]
ok
$SS
[MSG:INFO: FluidNC v3.9.6 (Test_1489-9f00d07f-dirty) git@github.com:ramack/FluidNC.git]
[MSG:INFO: Compiled with ESP32 SDK:v4.4.7-dirty]
[MSG:INFO: Local filesystem type is littlefs]
[MSG:INFO: Configuration file:JaRa_CNC.yaml]
[MSG:DBG: Running after-parse tasks]
[MSG:DBG: Checking configuration]
[MSG:INFO: Machine JaRa CNC]
[MSG:INFO: Board 6 Pack CNC by Bart Dring]
[MSG:INFO: UART2 Tx:gpio.27 Rx:gpio.25 RTS:NO_PIN Baud:1000000]
[MSG:INFO: uart_channel2 created at report interval: 200]
[MSG:INFO: I2SO BCK:gpio.22 WS:gpio.17 DATA:gpio.21Min Pulse:2us]
[MSG:INFO: SPI SCK:gpio.18 MOSI:gpio.23 MISO:gpio.19]
[MSG:INFO: SD Card cspin:gpio.5 detect:NOPIN freq:8000000]
[MSG:INFO: Stepping:I2S_STREAM Pulse:6us Dsbl Delay:0us Dir Delay:6us Idle Delay:255ms]
[MSG:INFO: Axis count 4]
[MSG:INFO: Axis X (0.000,555.000)]
[MSG:INFO: Motor0]
[MSG:INFO: standard_stepper Step:I2SO.2 Dir:I2SO.1 Disable:I2SO.0]
[MSG:INFO: Neg Limit gpio.33:low:pu]
[MSG:INFO: Axis Y (-410.000,0.000)]
[MSG:INFO: Motor0]
[MSG:INFO: standard_stepper Step:I2SO.5 Dir:I2SO.4 Disable:I2SO.7]
[MSG:INFO: Neg Limit gpio.26:low:pu]
[MSG:INFO: Axis Z (-240.000,140.000)]
[MSG:INFO: Motor0]
[MSG:INFO: standard_stepper Step:I2SO.10 Dir:I2SO.9 Disable:I2SO.8]
[MSG:INFO: Pos Limit gpio.32:low:pu]
[MSG:INFO: Axis A (-960.000,0.000)]
[MSG:INFO: Motor0]
[MSG:INFO: standard_stepper Step:I2SO.13 Dir:I2SO.12 Disable:I2SO.15]
[MSG:INFO: safetydoorpin gpio.35:low]
[MSG:INFO: cyclestartpin gpio.34:low]
[MSG:INFO: fault_pin gpio.2:low:pu]
[MSG:INFO: homingbuttonpin gpio.39:low]
[MSG:INFO: Kinematic system: Cartesian]
[MSG:INFO: Connecting to STA SSID:PalimPalim]
[MSG:INFO: Connecting.]
[MSG:INFO: Connecting..]
[MSG:INFO: Connected - IP is 192.168.0.77]
[MSG:INFO: WiFi on]
[MSG:INFO: Start mDNS with hostname:http://fluidnc.local/]
[MSG:INFO: HTTP started on port 80]
[MSG:INFO: Telnet started on port 23]
[MSG:INFO: Status outputs Interval:500 Idle:NOPIN Cycle:I2SO.21 Hold:I2SO.23 Alarm:NOPINDoor:NO_PIN]
[MSG:INFO: UART1 Tx:gpio.15 Rx:gpio.16 RTS:gpio.14 Baud:9600]
[MSG:INFO: SiemensV20 Spindle Tx:gpio.15 Rx:gpio.16 RTS:gpio.14 Baud:9600]
[MSG:INFO: RS485 Tx: 01 03 00 6E 00 01 E5 D7]
[MSG:DBG: SiemensV20: setState:5 SpindleSpeed:0]
[MSG:DBG: Synced speed. Requested:0 current:0]
ok
User Interface Software
WebUI, FluidDial pendant
What happened?
When activating the button on the safety door pin (opening the DOOR) before the machine is homed FluidNC tries to move to parking position and during the pullout (or later) it crashed our z-axis and even ignored the limit switch.
Before homing the machine should not move due to door opening, and definitely consider the limit switch to stop there.
GCode File
No response
Other Information
maybe also for macros should be checked if the limit switches are considered
评论 (5)
#2 – ramack 于 2025-05-21
For reproducing we tried three cases:
A) power on, fluidnc in unhomes Alarm, open door
B) power on, fluidnc in unhomes Alarm, clear alarm in WebUI, Idle state, open door
C) change config to have hard_limits: true power on, fluidnc in unhomes Alarm, clear alarm in WebUI, Idle state, open door, manually activate the limit switch
with A all is fine, no movement
with B the “unexpected” overrun of the limit switch occurs
with C also all fine, movement starts and stops at hard_limit
So basically it was a configuration issue on our side with the wrong expectation that a configured limit switch would also be a safety limit. Would be cool if you could document this a bit more explicitly – searching in the wiki for “hard_limits” did not even bring up a helpful result.
For the sake of completeness here is the log for B is:
“[MSG:INFO: FluidNC v3.9.6 (Test_1489-9f00d07f-dirty) git@github.com:ramack/FluidNC.git]“
[MSG:INFO: Compiled with ESP32 SDK:v4.4.7-dirty]
[MSG:INFO: Local filesystem type is littlefs]
[MSG:INFO: Configuration file:JaRa_CNC.yaml]
[MSG:DBG: Running after-parse tasks]
[MSG:DBG: Checking configuration]
[MSG:INFO: Machine JaRa CNC]
[MSG:INFO: Board 6 Pack CNC by Bart Dring]
[MSG:INFO: UART2 Tx:gpio.27 Rx:gpio.25 RTS:NO_PIN Baud:1000000]
[MSG:INFO: uart_channel2 created at report interval: 200]
[MSG:INFO: I2SO BCK:gpio.22 WS:gpio.17 DATA:gpio.21Min Pulse:2us]
[MSG:INFO: SPI SCK:gpio.18 MOSI:gpio.23 MISO:gpio.19]
[MSG:INFO: SD Card cspin:gpio.5 detect:NOPIN freq:8000000]
[MSG:INFO: Stepping:I2S_STREAM Pulse:6us Dsbl Delay:0us Dir Delay:6us Idle Delay:255ms]
[MSG:INFO: Axis count 4]
[MSG:INFO: Axis X (0.000,555.000)]
[MSG:INFO: Motor0]
[MSG:INFO: standard_stepper Step:I2SO.2 Dir:I2SO.1 Disable:I2SO.0]
[MSG:INFO: Neg Limit gpio.33:low:pu]
[MSG:INFO: Axis Y (-410.000,0.000)]
[MSG:INFO: Motor0]
[MSG:INFO: standard_stepper Step:I2SO.5 Dir:I2SO.4 Disable:I2SO.7]
[MSG:INFO: Neg Limit gpio.26:low:pu]
[MSG:INFO: Axis Z (-240.000,140.000)]
[MSG:INFO: Motor0]
[MSG:INFO: standard_stepper Step:I2SO.10 Dir:I2SO.9 Disable:I2SO.8]
[MSG:INFO: Pos Limit gpio.32:low:pu]
[MSG:INFO: Axis A (-960.000,0.000)]
[MSG:INFO: Motor0]
[MSG:INFO: standard_stepper Step:I2SO.13 Dir:I2SO.12 Disable:I2SO.15]
[MSG:INFO: safetydoorpin gpio.35:low]
[MSG:INFO: cyclestartpin gpio.34:low]
[MSG:INFO: fault_pin gpio.2:low:pu]
[MSG:INFO: homingbuttonpin gpio.39:low]
[MSG:INFO: Kinematic system: Cartesian]
[MSG:INFO: Connecting to STA SSID:PalimPalim]
[MSG:INFO: Connecting.]
[MSG:INFO: Connecting..]
[MSG:INFO: Connected - IP is 192.168.0.77]
[MSG:INFO: WiFi on]
[MSG:INFO: Start mDNS with hostname:http://fluidnc.local/]
[MSG:INFO: HTTP started on port 80]
[MSG:INFO: Telnet started on port 23]
[MSG:INFO: Status outputs Interval:500 Idle:NOPIN Cycle:I2SO.21 Hold:I2SO.23 Alarm:NOPINDoor:NO_PIN]
[MSG:INFO: UART1 Tx:gpio.15 Rx:gpio.16 RTS:gpio.14 Baud:9600]
[MSG:INFO: SiemensV20 Spindle Tx:gpio.15 Rx:gpio.16 RTS:gpio.14 Baud:9600]
[MSG:INFO: RS485 Tx: 01 03 00 6E 00 01 E5 D7]
[MSG:DBG: SiemensV20: setState:5 SpindleSpeed:0]
[MSG:DBG: Synced speed. Requested:0 current:0]
ok
$X
[MSG:INFO: Caution: Unlocked]
ok
[MSG:DBG: safetydoorpin 1]
[MSG:INFO: Check door]
[MSG:DBG: Parking pullout]
[MSG:DBG: Pos Limit 1]
[MSG:DBG: Limit switch tripped for Z motor 0]
[MSG:DBG: Pos Limit 0]
[MSG:DBG: Pos Limit 1]
[MSG:DBG: Limit switch tripped for Z motor 0]
[MSG:DBG: Pos Limit 0]
[MSG:DBG: Pos Limit 1]
#3 – MitchBradley 于 2025-05-21
Feel free to edit the wiki to say whatever you think needs to be said. https://www.goodreads.com/quotes/190777-to-do-good-is-noble-to-tell-others-to-do
#4 – ramack 于 2025-05-21
I surely would be willing, but as wiki contributions require a discord account I am out. That’s why I have chosen to be even nobler and proposed to you that you could improve the documentation – without complaining about the link (https://github.com/bdring/FluidNC/wiki/Hardware-that-Runs-FluidNC) in the issue template that points to the outdated wiki 😉.
Don’t get me wrong, I really appreciate the efforts you put into fluidnc and I’m giving my best to help where I can, but right now I don’t feel motivated to contribute. “It doesn’t work! Help-Me!”-users are a pain, but you should also try to avoid treating everyone as troll.
#5 – bdring 于 2025-05-21
I added some info to the parking page.
#1 – bdring 于 2025-05-17
You will have to show an exact log of what you do to cause the problem.
I did some testing. This is what happens if I activate the door before homing. It stays in alarm mode. The door pin is reporting as active. No motion occurs.
Here is the door active on startup. No motion occurs.
If I clear the homing alarm with $X. The door/parking feature can be activated, but since the Z machine position is is likely wrong, problems could occur. This is true for most of the features in FluidNC.
If I enable hard limits on Z the parking will trigger an alarm if it hits a switch.