NPN sensor for Z probe Issue
-
Hello I am trying to setup my Z probe (using a NPN sensor) and ultimately complete a mesh level of my bed. When i home the z, it goes to the first probe point in the x and y directions but the Z axis doesn't move. Then it says homing is completed with a random Z value listed as homed.
Here is my Config:
; Drives M584 X4 Y1:2 Z9:8 E0 ; set drive mapping M569 P0 S0 ; physical drive 0 goes forwards M569 P1 S0 ; physical drive 1 goes forwards M569 P2 S0 ; physical drive 2 goes FORwards M569 P3 S0 ; physical drive 3 goes forwards M569 P5 S0 M569 P6 S0 ; physical drive 3 goes forwards M569 P7 S0 ; physical drive 3 goes forwards M569 P8 S0 ; physical drive 3 goes forwards M569 P9 S0 M350 X16 Y16 Z16 E16 I1 ; configure microstepping with interpolation M92 X816.5 Y793.4 Z626.4 E100.00 ; set steps per mm M566 X500.00 Y500.00 Z60.00 E120.00 ; set maximum instantaneous speed changes (mm/min) M203 X600.00 Y600.00 Z180.00 E1200.00 ; set maximum speeds (mm/min) M201 X25.00 Y25.00 Z20.00 E250.00 ; set accelerations (mm/s^2) M906 X800 Y800 Z800 E800 I30 ; set motor currents (mA) and motor idle factor in per cent M84 S30 ; Set idle timeout ; Axis Limits M208 X0 Y0 Z0 S1 ; set axis minima M208 X300 Y400 Z500 S0 ; set axis maxima ; Endstops M574 X1 S1 P"!xstop" ; configure active-high endstop for low end on X via pin xstop M574 Y1 S1 P"!ystop+!e0stop" ; configure active-high endstops for low end on Z via pins zstop and e1stop M574 Z1 S2 ; configure Z-probe endstop for low end on Z ; Z-Probe G31 X20 Y0 Z9 P25 M557 X15:762 Y15:762 S20 ; define mesh grid ; Heaters M140 H-1 ; disable heated bed (overrides default heater mapping) M308 S0 P"e0temp" Y"thermistor" T100000 B4138 ; configure sensor 0 as thermistor on pin e0temp M950 H0 C"e0heat" T0 ; create nozzle heater output on e0heat and map it to sensor 0 M307 H0 B0 S1.00 ; disable bang-bang mode for heater and set PWM limit M143 H0 S260 ; set temperature limit for heater 0 to 260C ; Fans ; Tools M563 P0 D0 H0 S"Main" ; define tool 1 G10 P0 X0 Y0 Z0 ; set tool 1 axis offsets G10 P0 R0 S0 ; set initial tool 1 active and standby temperatures to 0C ; Custom settings are not defined ; Miscellaneous M501 ; load saved parameters from non-volatile memory M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; set voltage thresholds and actions to run on power loss
Here is my homez.g:
G91 ; relative positioning G1 H2 Z5 F6000 ; lift Z relative to current position G90 ; absolute positioning G1 X15 Y15 F6000 ; go to first probe point G30 ; home Z by probing the bed
-
As far as I can see you don't actually have a probe defined at all. There is no M558 command.
Is this your full config?
Can you also share the results of sending M122 and M98 P"config.g" in the gcode console?
-
@Phaedrux
I added the M558 line to the config and now it goes to probe. However during probing the bed moves in the wrong direction.
here is the new config: the homez.g is the same as before:; Drives M584 X4 Y1:2 Z9:8 E0 ; set drive mapping M569 P0 S0 ; physical drive 0 goes forwards M569 P1 S0 ; physical drive 1 goes forwards M569 P2 S0 ; physical drive 2 goes FORwards M569 P3 S0 ; physical drive 3 goes forwards M569 P5 S0 M569 P6 S0 ; physical drive 3 goes forwards M569 P7 S0 ; physical drive 3 goes forwards M569 P8 S0 ; physical drive 3 goes forwards M569 P9 S0 M350 X16 Y16 Z16 E16 I1 ; configure microstepping with interpolation M92 X816.5 Y793.4 Z626.4 E100.00 ; set steps per mm M566 X500.00 Y500.00 Z60.00 E120.00 ; set maximum instantaneous speed changes (mm/min) M203 X600.00 Y600.00 Z180.00 E1200.00 ; set maximum speeds (mm/min) M201 X25.00 Y25.00 Z20.00 E250.00 ; set accelerations (mm/s^2) M906 X800 Y800 Z800 E800 I30 ; set motor currents (mA) and motor idle factor in per cent M84 S30 ; Set idle timeout ; Axis Limits M208 X0 Y0 Z0 S1 ; set axis minima M208 X300 Y400 Z500 S0 ; set axis maxima ; Endstops M574 X1 S1 P"!xstop" ; configure active-high endstop for low end on X via pin xstop M574 Y1 S1 P"!ystop+!e0stop" ; configure active-high endstops for low end on Z via pins zstop and e1stop M574 Z1 S2 ; configure Z-probe endstop for low end on Z ; Z-Probe M558 P5 C"^zprobe.in" H5 F120 T3000 G31 X20 Y0 Z9 P25 M557 X15:762 Y15:762 S20 ; define mesh grid ; Heaters M140 H-1 ; disable heated bed (overrides default heater mapping) M308 S0 P"e0temp" Y"thermistor" T100000 B4138 ; configure sensor 0 as thermistor on pin e0temp M950 H0 C"e0heat" T0 ; create nozzle heater output on e0heat and map it to sensor 0 M307 H0 B0 S1.00 ; disable bang-bang mode for heater and set PWM limit M143 H0 S260 ; set temperature limit for heater 0 to 260C ; Fans ; Tools M563 P0 D0 H0 S"Main" ; define tool 1 G10 P0 X0 Y0 Z0 ; set tool 1 axis offsets G10 P0 R0 S0 ; set initial tool 1 active and standby temperatures to 0C ; Custom settings are not defined ; Miscellaneous M501 ; load saved parameters from non-volatile memory M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; set voltage thresholds and actions to run on power loss
here are the M122 and M98 responses:
9/7/2023, 11:40:45 PM M98 P"config.g" i HTTP is enabled on port 80 FTP is disabled TELNET is disabled Error: bad grid definition: Too many grid points; suggest increase spacing to 37.3mm Error: Heater 1 not found Error: Heater 2 not found Error: Heater 4 not found Error: Heater 5 not found Error: Heater 6 not found Error: Heater 7 not found 9/7/2023, 11:40:19 PM M122 === Diagnostics === RepRapFirmware for Duet 2 WiFi/Ethernet version 3.4.1 (2022-06-01 21:05:28) running on Duet WiFi 1.02 or later + DueX5 Used output buffers: 3 of 26 (23 max) === RTOS === Static ram: 23860 Dynamic ram: 75200 of which 0 recycled Never used RAM 12948, free system stack 134 words Tasks: NETWORK(ready,13.7%,242) HEAT(notifyWait,0.0%,333) Move(notifyWait,0.0%,296) DUEX(notifyWait,0.0%,24) MAIN(running,85.8%,410) IDLE(ready,0.5%,30), total 100.0% Owned mutexes: WiFi(NETWORK) === Platform === Last reset 00:03:43 ago, cause: software Last software reset at 2023-09-07 23:36, reason: User, GCodes spinning, available RAM 13108, slot 1 Software reset code 0x0003 HFSR 0x00000000 CFSR 0x00000000 ICSR 0x0041f000 BFAR 0xe000ed38 SP 0x00000000 Task MAIN Freestk 0 n/a Error status: 0x00 Aux0 errors 0,0,0 Step timer max interval 0 MCU temperature: min 32.8, current 34.1, max 34.8 Supply voltage: min 12.2, current 12.2, max 12.4, under voltage events: 0, over voltage events: 0, power good: yes Heap OK, handles allocated/used 0/0, heap memory allocated/used/recyclable 0/0/0, gc cycles 0 Events: 0 queued, 0 completed Driver 0: standstill, SG min n/a Driver 1: standstill, SG min 0 Driver 2: standstill, SG min 0 Driver 3: standstill, SG min n/a Driver 4: standstill, SG min 0 Driver 5: standstill, SG min n/a Driver 6: standstill, SG min n/a Driver 7: standstill, SG min n/a Driver 8: standstill, SG min n/a Driver 9: standstill, SG min n/a Driver 10: Driver 11: Date/time: 2023-09-07 23:40:15 Cache data hit count 4294967295 Slowest loop: 59.06ms; fastest: 0.16ms I2C nak errors 0, send timeouts 0, receive timeouts 0, finishTimeouts 0, resets 0 === Storage === Free file entries: 10 SD card 0 detected, interface speed: 20.0MBytes/sec SD card longest read time 1.2ms, write time 3.0ms, max retries 0 === Move === DMs created 83, segments created 3, maxWait 15424ms, bed compensation in use: none, comp offset 0.000 === MainDDARing === Scheduled moves 17, completed 17, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 2], CDDA state -1 === AuxDDARing === Scheduled moves 0, completed 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1 === Heat === Bed heaters -1 -1 -1 -1, chamber heaters -1 -1 -1 -1, ordering errs 0 === GCodes === Segments left: 0 Movement lock held by null HTTP is idle in state(s) 0 Telnet is idle in state(s) 0 File is idle in state(s) 0 USB is idle in state(s) 0 Aux is idle in state(s) 0 Trigger is idle in state(s) 0 Queue is idle in state(s) 0 LCD is idle in state(s) 0 Daemon is idle in state(s) 0 Autopause is idle in state(s) 0 Code queue is empty === DueX === Read count 1, 0.27 reads/min === Network ===
-
@Drak said in NPN sensor for Z probe Issue:
the bed moves in the wrong direction.
Then you'd likely need to reverse the motor rotation direction for the Z motors in the M569 commands.
M569 P8 S1 M569 P9 S1
Test carefully.
-
@Phaedrux Thank you, I got this error when homing, I leveled the bed again and got same error but at a lower max error. how do i establish a a Z=0 datum?
Warning: Skipping grid point X=15.0, Y=265.0 because Z probe cannot reach it Warning: the height map has a substantial Z offset. Suggest use Z-probe to establish Z=0 datum, then re-probe the mesh. 24 points probed, min error 0.302, max error 3.056, mean 1.826, deviation 0.716 Height map saved to file 0:/sys/heightmap.csv 9/9/2023, 5:45:40 PM Warning: Skipping grid point X=15.0, Y=165.0 because Z probe cannot reach it Warning: Skipping grid point X=15.0, Y=215.0 because Z probe cannot reach it 9/9/2023, 5:44:32 PM Warning: Skipping grid point X=15.0, Y=65.0 because Z probe cannot reach it Warning: Skipping grid point X=15.0, Y=115.0 because Z probe cannot reach it 9/9/2023, 5:43:23 PM G28 Z Warning: Skipping grid point X=15.0, Y=15.0 because Z probe cannot reach it
-
@Drak said in NPN sensor for Z probe Issue:
Duet 2 WiFi/Ethernet version 3.4.1
Should probably update your firmware.
Upload this zip file to the system tab in DWC.
https://github.com/Duet3D/RepRapFirmware/releases/download/3.4.6/Duet2and3Firmware-3.4.6.zip@Drak said in NPN sensor for Z probe Issue:
how do i establish a a Z=0 datum?
This is done by using the probe to home Z with a G30 first.
Make sure you've measured your probes offsets accurately first.
https://docs.duet3d.com/en/User_manual/Connecting_hardware/Z_probe_testing