Spurious (?) "Error: G0/G1: insufficient axes homed" message?
-
Well we need to see the other homing files.
And if you will get into the habit of posting such files with the </> tag it will be easier on us all and much appreciated.
You existing homez.g file assumes X and Y are homed - that may not always be the case.
Frederick
-
That is most curiuos.
- I would add something to check the homing of the X & Y axis at the top of homez.g file. I do them individually-not sure how your machine is set up.
if !move.axes[0].homed || !move.axes[1].homed ; If the printer hasn't been homed, home it M98 P"0:/sys/homey.g" M98 P"0:/sys/homex.g"
- I would put a M564 instruction at the very end of the homez.g file to make sure that it gets applied in case its forgotten elswhere.
M564 S1 H0 ; limit motion envelope to that defined by M208 in config.g
-
in deployprobe.g, the M564 is in the middle section between the 2 other if statements.
I am not certain, but I believe that RRF will parse the entire macro on execution-
it might be better to put the M564 statements at the very beginning and the very end in case the loops abort partway through. -
The location of the carraige may be relavant
- if its outside the envelope because we gave it permission to go there
- while it was still outside the boundary, we took that permission away,
- moving from that forbidden zone to the safe zone might be trigggering that error message.
That message might be generic appplying to all motions outside the M208 definitions.
That should be easy enough to test barring and official clarifications.
- I have experienced funniness with spaces and tabs in files for whitespace. Sometimes I have gotten errors for inexplicable reasons, and after parsing the files for tab characters and replacing them with spaces, things behave different.
I see tabs in your homez.g file at lines 15, 18, 32, 34,
-
@sinned6915 Greetings -
I added your if statement to my
homez.g
file but it seems that current RRF 3.3 already checks for an attempt to home Z before homing X and Y, and responds with this message in the console:Error: Must home axes [XY] before homing [Z]
I added a final
M64 S1 H1
tohomez.g
without change to the spurious message. I've since removed that line to continue troubleshooting.I've moved the M564 to be before all G1 movements in both
deployprobe.g
andretractprobe.g
as suggested, with theM564 H1 S1
after the G1 movements in each file.Not sure about item 4.
I've checked my latest files for tabs. I use VSCode which switches tabs to spaces be default, but perhaps if I edited via DWC for changes, some were introduced there. No change in bahavior.
I did notice one interesting thing. After I complete homing X, Y, and Z, and get the error message, if I home Z a second time, I don't receive the "Error: G0/G1: insufficient axes homed" message" after the second execution of Home Z.
@fcwilt I'm uploading files using the icon for "Upload files." If there is a better or different way to do that, please point me at those instructions. I've added the remaining homing files, as well as the updated files after the changes discussed above.
Thanks,
John
homex.g homey.g homeall.g config.g homez.g deployprobe.g retractprobe.g
-
I've posted your files using the </> tag. It gives each file it's own scrolling window which means we all can see them without downloading.
You just enter the tag and the paste the contents of a file between the start
** and end **
characters where you see the text undefined.; Configuration file for Duet WiFi on Railcore ZL - for RRF 3 ; executed by the firmware on start-up ; ; generated by RepRapFirmware Configuration Tool v2 on Tue Dec 25 2018 20:01:03 GMT-0600 (Central Standard Time) ; Modified 16 July 2021 - osh ; Debugging M111 S0 ; Debug (S0 is off; S1 is on) M929 P"eventlog.txt" S1 ; start logging to file eventlog.txt M915 X Y S10 F0 R1 ; log motor stalls (added 5/4/2019) ; General preferences G21 ; Work in millimetres G90 ; Send absolute coordinates... M83 ; ...but relative extruder moves M555 P2 ; Set output to look like Marlin M669 K1 ; Select CoreXY kinematics (RRF 2.03 and later) ; Network M550 P"RailCore" ; Set machine name M552 P0.0.0.0 S1 ; Enable network and acquire dynamic address via DHCP M586 P0 S1 ; Enable HTTP M586 P1 S0 ; Disable FTP M586 P2 S0 ; Disable Telnet ; Drives M584 X0 Y1 Z5:6:7 E3 ; Map Z to drivers 5, 6, 7. Define unused drivers 4,8 and 9 as extruders along with (actual) 3 M569 P0 S1 ; Drive 0 goes forwards X/Y stepper (front?) M569 P1 S0 ; Drive 1 goes backwards X/Y Stepper (rear?) M569 P2 S1 ; Drive 2 goes forwards (unused) M569 P3 S1 ; Drive 3 goes forwards Extruder (forward for LDO motor) M569 P4 S1 ; Drive 4 goes forwards (unused) M569 P5 S0 ; Drive 5 goes backwards Front Left Z M569 P6 S0 ; Drive 6 goes backwards Rear Left Z M569 P7 S0 ; Drive 7 goes backwards Right Z ; Leadscrew locations M671 X-11:-11:347 Y20:274:144 S7.5 ; Front left (-11,20), Rear Left (-11,274), Right (347,144) 9/1/2020 - osh - S7.5 is the max correction - measure your own offsets, to the bolt for the yoke of each leadscrew ; Axis and motor configurations M350 X16 Y16 Z16 E16 I1 ; Configure 16x microstepping with interpolation M906 X1200 Y1200 Z1200 E860 I30 ; Set motor currents (mA) and motor idle factor in per cent (docs say rounds to 100, but this is where I'd like them to be) M92 X200.0 Y200.0 Z1600.0 E836.0 ; Set steps per mm (25 June 2019) M566 X600 Y600 Z200 E3600 ; Set maximum instantaneous (jerk) speed changes (mm/min) M201 X1750 Y1750 Z250 E1500 ; Set accelerations (mm/s^2) M203 X24000 Y24000 Z900 E3600 ; Set maximum speeds (mm/min) M84 S60 ; Set motor idle timeout M579 X1.0028 Y1.0021 ; Scale X and Y axis ; Axis Limits M208 X300 Y300 Z320 ; set axis maxima and high homing switch positions - 9/1/2020 - osh M208 X0 Y0 Z0 S1 ; set axis minima and low homing switch positions (adjust to make X=0 and Y=0 the edges of the bed); ; Endstops M574 X1 S1 P"xstop" ; X min active high endstop switch M574 Y1 S1 P"ystop" ; Y min active high endstop switch M574 Z0 S2 ; Z endstop controlled by BLTouch probe ; Z-Probe - Euclid Detachable Omron switch probe M558 K0 P5 C"^zprobe.in" H8 R0.5 F240:120 T9000 A3 S0.03 ; K0 for probe 0, P5 for NC switch, C for input pin, ^ for enabling the native pullup ; resistor on Duet2 hardware running RRF3 H dive height of 8mm, F240 probing speed ?mm/sec, ; T9000 travel speed 150mm/sec, A3 number of probes 1, S0.03 max tolerance of 0.03 G31 K0 P500 X-1 Y35 Z0.90 ; CHECK for LOOSE things first! set Z probe trigger value, offset and trigger height. ; Tip: A larger trigger height in G31 moves you CLOSER to the bed ; switch plunger is 35mm to the RIGHT and 2 in FRONT of the nozzle ; switch triggers 0.9mm BELOW nozzle ; https://duet3d.dozuki.com/Wiki/Test_and_calibrate_the_Z_probe#Section_Fine_tuning_the_trigger_height ; Z-Probe - BLTouch "Smart v3" ; M950 S0 C"duex.pwm5" ; Define BLTouch Servo (S0) on duet pwm5 ; M558 P9 C"^zprobe.in" H5 F90 T6000 A3 S0.02 ; BLTouch connected to Z probe IN pin ; M208 S1 Z-0.2 ; set minimum Z ; G31 X-4 Y36 Z1.74 H5 P25 ; Customize your offsets. (Nozzle X) FilaStruder PEI Sheet: January 29 2021 ; ; Tip: A larger trigger height in G31 moves you CLOSER to the bed ; M98 P"filamentsensor.g" ; Call external file to configure filament sensor ; ; Mesh Bed Leveling area ; M557 X46.5:290.5 Y39.5:246.5 P2:2 ; Set Default Mesh - NOTE: take probe offset into account - corners only (magnets avoided) - 9/4/2020 M557 X46.5:290.5 Y39.5:246.5 P5:4 ; Set Default Mesh - NOTE: take probe offset into account - "full" bed (magnets avoided) - 9/4/2020 ; ; E.G. If probe offset is 42 on Y, then Y50:290 will take the hotend to Y08 to Y248) ; Heaters M308 S0 P"bedtemp" Y"thermistor" A"bed_heat" T100000 B3950 R4700 H0 L0 ; configure sensor 0 as thermistor on pin bedtemp M950 H0 C"bed_heat" T0 ; create bed heater output on bedheat and map it to sensor 0 M140 H0 ; Inform the firmware that bed heater 0 uses heater 0 M143 H0 S120 ; Set temperature limit for heater 0 to 120C M308 S1 P"e0temp" Y"thermistor" A"hotend_heat" T100000 B4725 R4700 C7.06e-8 H0 L0 ; configure sensor 1 as thermistor on pin e0temp (Hotend) M950 H1 C"e0_heat" T1 ;create nozzle heater output on e0heat and map it to sensor 1 M143 H1 S288 ; Set temperature limit for heater 1 to 288C M308 S2 P"duex.e6temp" Y"thermistor" A"keenovo" T100000 B3950 R4700 C7.06E-8 H0 L0 ; Secondary bed thermistor M140 S0 R0 ; Standby and initial Temp for bed set to 0 (-273 = "off") M308 S10 Y"mcu-temp" A"mcu-temp" ; Display Duet2 CPU temp ; Tools M563 P0 D0 H1 ; Define tool 0 G10 P0 X0 Y0 Z0 ; Set tool 0 axis offsets G10 P0 S0 R0 F1 ; Set tool 0 operating and standby temperatures(-273 = "off") M307 H1 R1.860 C240.1 D6.45 S1.00 V24.4 ; Heater 1 - Hot-end - PID tuned @ 240C 4/04/2021 M307 H0 R0.319 C829.9 D16.91 S1.00 V24.4 B0 ; Heater 0 - MIC 6 Bed - PID tuned @ 70C 4/04/2021 ; Fans M950 F0 C"fan0" Q500 ; create fan 0 on pin fan0 and set its frequency M106 P0 S0 H-1 ; set fan 0 value. Thermostatic control is turned off M950 F1 C"fan1" Q500 ; create fan 1 on pin fan1 and set its frequency M106 P1 S1 H1 T40 ; set fan 1 value. Thermostatic control is turned on ; Automatic power saving M911 S10 R11 P"M913 X0 Y0 G91 M83 G1 Z3 E-5 F1000" ; Set voltage thresholds and actions to run on power loss ; Miscellaneous M950 F2 C"duex.fan7" ; LED Light Bar (left?) M950 F3 C"duex.fan8" ; LED Light Bar (right)?) ;M501 ; Load saved parameters from non-volatile memory T0 ; Select first hot-end M98 P"/macros/LED_Ready.g" ; Turn on LED lights
; homeall.g - for RRF 3 ; called to home all axes ; ; generated by RepRapFirmware Configuration Tool v2 on Tue Dec 25 2018 20:01:04 GMT-0600 (Central Standard Time) ; Modified 16 July 2021 for Euclid detachable probe ; This file assumes the endstop switches are at the low end of each axis. ; Reverse the X and Y movement for high-end switches. ; Adjust the bed upper and lower limits in config.g (M208 commands) to get the correct homing positions G91 ; relative positioning G1 H2 Z5 F1000 ; lift Z relative to current position G1 H1 X-320 Y-320 F4000 ; move quickly to X or Y endstop and stop there (first pass) G1 X5 Y5 F2000 ; go back a few mm G1 H1 X-320 F360 ; move slowly to X axis endstop once more (second pass) G1 H1 Y-320 F360 ; then move slowly to Y axis endstop G90 ; absolute positioning M98 P"0:/sys/homez.g" ; Called separately as Home Z is complex with Euclid Probe deploy and retract items
; homex.g - for RRF 3 ; called to home the X axis ; ; generated by RepRapFirmware Configuration Tool v2 on Tue Dec 25 2018 20:01:04 GMT-0600 (Central Standard Time) ; Modified 14 July 2021 for Euclid detachable probe G91 ; relative positioning G1 H2 Z5 F1000 ; lift Z relative to current position G1 H1 X-320 F4000 ; move quickly to X axis endstop and stop there (first pass) G1 X5 F1000 ; go back a few mm G1 H1 X-320 F200 ; move slowly to X axis endstop once more (second pass) G1 H2 Z-5 F200 ; lower Z again G90 ; absolute positioning
; homey.g - for RRF 3 ; called to home the Y axis ; ; generated by RepRapFirmware Configuration Tool v2 on Tue Dec 25 2018 20:01:04 GMT-0600 (Central Standard Time) ; Modified 14 July 2021 for Euclid detachable probe G91 ; relative positioning G1 H2 Z5 F1000 ; lift Z relative to current position G1 H1 Y-320 F4000 ; move quickly to Y axis endstop and stop there (first pass) G1 Y5 F1000 ; go back a few mm G1 H1 Y-320 F200 ; move slowly to Y axis endstop once more (second pass) G1 H2 Z-5 F200 ; lower Z again G90 ; absolute positioning
; homez.g - for RRF 3 ; called to home the Z axis ; ; generated by RepRapFirmware Configuration Tool v2 on Tue Dec 25 2018 20:01:04 GMT-0600 (Central Standard Time) ; Modified 17c July 2021 for Euclid detachable probe echo "DEBUG: Running homez.g macro" G91 ; relative positioning M400 ; wait for moves to complete echo "DEBUG: First Lift Z in home-Z" G1 H2 Z5 F1000 ; lift Z relative to current position G90 ; absolute positioning echo "Probe State Value = " ^sensors.probes[0].value[0] echo "deployuser token = " ^sensors.probes[0].deployedByUser echo "DEBUG: Call deployprobe.g macro" M401 P0 ; This runs macro file deployprobe echo "DEBUG: returned from deployprobe.g" echo "Probe State Value =" ^sensors.probes[0].value[0] echo "deployuser token =" ^sensors.probes[0].deployedByUser G1 X150 Y150 F4000 ; go to bed center probe point M400 ; wait for moves to complete echo "Execute G30 command" G30 ; home Z by probing the bed M400 echo "Probe State Value = " ^sensors.probes[0].value[0] echo "deployuser token = " ^sensors.probes[0].deployedByUser echo "DEBUG: Call retractprobe.g macro" M402 P0 ; retract / remove probe echo "DEBUG: Returned from retractprobe.g" echo "Probe State Value =" ^sensors.probes[0].value[0] echo "deployuser token =" ^sensors.probes[0].deployedByUser echo "DEBUG: Last Lift Z in home-Z" G1 H2 Z10 F1000 ; lift Z relative to current position G90 ; absolute positioning echo "DEBUG: homez.g macro complete"
; *********************************************************** ; deployprobe.g ; Modified 17 July 2021 - osh ; *********************************************************** echo "DEBUG: Running deployprobe.g" ; uncomment next line to echo the probe deploy state echo "deployuser token= " ^sensors.probes[0].deployedByUser G91 ; relative positioning echo "DEBUG: First Lift Z in deployprobe.g" G1 H2 Z15 F4000 ; move Z 15 for clearance above dock. ; need to figure out some safety check on this G90 ; absolute positioning echo sensors.probes[0].value[0] if sensors.probes[0].value[0]!=1000 ; if sensor is value other than 1000 do this ; uncomment next line to echo the probe deploy state echo "deployuser token = " ^sensors.probes[0].deployedByUser echo "Probe State = " ^sensors.probes[0].value[0] abort "deployprobe start value Probe already picked up. Manually return probe to the dock" ; if we're here we know it's becasue the above is true which I assume is because you have an NC switch as a probe. echo "DEBUG: Pass first logic test" M564 H1 S0 ; Allow movement BEYOND axes boundaries (for Y to reach probe dock) G1 X5.0 Y290 F6000 ; move adjacent to probe dock location M400 ; wait for moves to finish echo "DEBUG: Probe Pickup while loop running" ; uncomment next line to echo the probe deplot state echo "deployuser token (before while loop) = " ^sensors.probes[0].deployedByUser while sensors.probes[0].value[0]=1000 G1 X5 Y305.3 F3000 ; move over dock (allow beyond range) F3000 is standard speed G4 S2 ; DEBUG PAUSE 2 seconds echo sensors.probes[0].value[0] G1 X60 Y305.3 F1200 ; slide probe out of dock - slowly M400 G4 S2 ; DEBUG PAUSE 2 seconds G90 ; absolute positioning echo "DEBUG: Probe Pickup while loop complete" ; uncomment to echo the probe deplot state echo "deployuser token (after while loop) = " ^sensors.probes[0].deployedByUser G90 ; absolute positioning G1 H2 Z10 F3000 ; move bed to clear probe from build surface M400 ; wait for moves to finish M564 H1 S1 ; Restrict movement to within axes boundaries (for normal Y movement) if sensors.probes[0].value[0]!=0 echo "Probe Pickup while loop complete" ; uncomment to echo the probe deploy state echo "deployuser token (in abort if section)= " ^sensors.probes[0].deployedByUser abort "deployprobe endvalue not 0 Probe not picked up! Print cancelled." echo "DEBUG: deployprobe.g complete"
; *********************************************************** ; ; retractprobe.g ; Modified 17b July 2021 - osh ; ; *********************************************************** ; echo "DEBUG: running retractprobe.g macro" if sensors.probes[0].value[0]!= 0 abort "retractprobe: Probe not currently picked up!" echo "pass first logic loop" G90 ; absolute positioning M564 H1 S0 ; Allow movement BEYOND axes boundaries (for Y to reach probe dock) G1 X90 Y280 F6000 ; move to the starting point (6000 for normal speed) G1 X90 Y305.3 F3000 ; move to intermediate point (3000 for normal speed) M400 G1 X40 Y305.3 F600 ; move to just outside dock position - leave at speed 300 M400 G1 X5.0 Y305.3 F600 ; move to dock and drop off probe M400 G1 X5.0 Y280 F3000 ; move to the side adjacent to the dock M400 G1 X150.0 Y150.0 F6000 ; move to the center of bed M400 M564 H1 S1 ; Restrict movement to within axes boundaries (for normal Y movement) echo "DEBUG: complete movement commands" if sensors.probes[0].value[0]!= 1000 abort "retractprobe: Probe not correctly dropped off in dock!" echo "DEBUG: retractprobe.g macro complete"
-
How much work would it be to add a Z endstop sensor?
With that you could home Z at any time without having to insure that X and Y are homed first.
I have Z probes on all my printers but I also have Z endstop sensors on them.
Frederick
-
Could you explain a bit what the deploy and retract files are doing?
How does it all work?
Thanks.
Frederick
-
@fcwilt Thanks for the example of posting that way. I use that for small segments of code, but hadn't realized it was a good way to post complete files.
As far as a Z-endstop -- I suppose it is possible. I haven't seen the need. As I mentioned above, the printer is working fine, just seem to be getting a message that does not correspond to the printer's behavior.
As far as the probe, you can read all the details on the Github page: https://github.com/nionio6915/Euclid_Probe/blob/main/README.md#probe-calibration
But in summary, a simple switch is magnetically attached to the carriage. The deploy and retract files handle the logic to determine if the probe is attached or not. The
deploy
macro will travel to the dock and "pick up" the probe. Theretract
macro will return the probe to the dock.John
-
@johnocfii said in Spurious (?) "Error: G0/G1: insufficient axes homed" message?:
As far as a Z-endstop -- I suppose it is possible. I haven't seen the need. As I mentioned above, the printer is working fine, just seem to be getting a message that does not correspond to the printer's behavior.
Well as you see if you click the Home Z button on the DWC you will get an error because homez.g attempts to move on X and Y to bed center.
You cannot, of course, move on X and Y to a given location until they have been homed.
I much prefer to be able to home Z first so I can be sure the bed is clear of anything on the X or Y gantries.
But to each their own.
-
@fcwilt he is using a magnetic coupled probe
you dont need an endstop, the probe works as both endstop and probe. the corollary is BLTouch- same device, 2 functions.
i suggested that the conditional get added to check the home status
-
@sinned6915 said in Spurious (?) "Error: G0/G1: insufficient axes homed" message?:
@fcwilt he is using a magnetic coupled probe
you dont need an endstop, the probe works as both endstop and probe. the corollary is BLTouch- same device, 2 functions.
i suggested that the conditional get added to check the home status
I know that.
I am suggesting that having both is a better approach.
Homing Z with an endstop is faster and you don't need to have X and Y homed first.
I only use the Z probe for things that require a Z probe - such as setting the Z=0 datum.
It's just a personal preference based on having built 8 printers.
Frederick