internal error when homing Z

recently updated klipper and now get internal error on command g28 when homing the z axis. "Internal error on command:"G28" Internal error on command:"G28" Traceback (most recent call last): File "/home/pi/klipper/klippy/gcode.py", line 211, in _process_commands handler(gcmd) File "/home/pi/klipper/klippy/extras/homing_override.py", line 23, in cmd_G28 self.prev_G28(gcmd) File "/home/pi/klipper/klippy/extras/ratos_homing.py", line 77, in cmd_G28 self.template.run_gcode_from_command(context) File "/home/pi/klipper/klippy/extras/gcode_macro.py", line 68, in run_gcode_from_command self.gcode.run_script_from_command(self.render(context)) File "/home/pi/klipper/klippy/gcode.py", line 226, in run_script_from_command self._process_commands(script.split('\n'), need_ack=False) File "/home/pi/klipper/klippy/gcode.py", line 211, in _process_commands handler(gcmd) File "/home/pi/klipper/klippy/extras/homing_override.py", line 23, in cmd_G28 self.prev_G28(gcmd) File "/home/pi/klipper/klippy/extras/ratos_homing.py", line 28, in cmd_G28 self.prev_G28(gcmd) File "/home/pi/klipper/klippy/extras/homing.py", line 268, in cmd_G28 kin.home(homing_state) File "/home/pi/klipper/klippy/kinematics/corexy.py", line 64, in home homing_state.home_rails([rail], forcepos, homepos) File "/home/pi/klipper/klippy/extras/homing.py", line 185, in home_rails hmove.homing_move(homepos, hi.speed) File "/home/pi/klipper/klippy/extras/homing.py", line 85, in homing_move wait = mcu_endstop.home_start(print_time, ENDSTOP_SAMPLE_TIME, File "/home/pi/klipper/klippy/extras/beacon.py", line 1512, in home_start trsync.start(print_time, self._trigger_completion, expire_timeout) TypeError: start() missing 1 required positional argument: 'expire_timeout' MCU 'mcu' shutdown: Command request"
37 Replies
miklschmidt
miklschmidtβ€’5mo ago
Don't put this in your config and you won't break it πŸ™‚
No description
ElevatorMusic
ElevatorMusicβ€’5mo ago
Added the z axis g28 z0 after failing. This has worked up until now. I need to home my y axis first then x axis at y360.
miklschmidt
miklschmidtβ€’5mo ago
This is not the way to do that. It may have worked (except you've skipped every single RatOS related homing feature), but it sure doesn't anymore (and hasn't ever since ratos_homing was introduced ages ago) changing the homing order will be a supported feature in RatOS 2.1 The only way to achieve that in 2.0 is by copying the [ratos_homing] section from homing.cfg to your user overrides section and swapping the X and Y part of the homing routine.
ElevatorMusic
ElevatorMusicβ€’5mo ago
@miklschmidt Okay so I modified the homing config file and the x and y work. but z still fails
ElevatorMusic
ElevatorMusicβ€’5mo ago
removed the override section
No description
ElevatorMusic
ElevatorMusicβ€’5mo ago
No description
ElevatorMusic
ElevatorMusicβ€’5mo ago
No description
miklschmidt
miklschmidtβ€’5mo ago
Please upload your printer.cfg and i'll take a look
ElevatorMusic
ElevatorMusicβ€’5mo ago
thanks
miklschmidt
miklschmidtβ€’5mo ago
[safe_z_home]
## XY Location of the Z Endstop Switch
## Update -10,-10 to the XY coordinates of your endstop pin
## (such as 157,305) after going through Z Endstop Pin
## Location Definition step.
home_xy_position: 180,180
speed: 100
z_hop: 10
[safe_z_home]
## XY Location of the Z Endstop Switch
## Update -10,-10 to the XY coordinates of your endstop pin
## (such as 157,305) after going through Z Endstop Pin
## Location Definition step.
home_xy_position: 180,180
speed: 100
z_hop: 10
Delete that
miklschmidt
miklschmidtβ€’5mo ago
if you want to change the safe home position use the safe_home_x and safe_home_y RatOS variables: https://os.ratrig.com/docs/configuration/macros#homing
Configuring RatOS Macros | RatOS
RatOS comes with a bunch of flexible predefined macro's that can be customized via variables and macro hooks.
miklschmidt
miklschmidtβ€’5mo ago
The reason it's broken for you is that you've defined multiple mutually exclusive homing mechanisms You can only use one of homing_override, safe_z_home or ratos_homing. ratos_homing is a combination of the homing_override and safe_z_home. RatOS only works with ratos_homing.
ElevatorMusic
ElevatorMusicβ€’5mo ago
interesting! I'll test it out @miklschmidt I'm still getting the error
blacksmithforlife
blacksmithforlifeβ€’5mo ago
post your updated printer.cfg
ElevatorMusic
ElevatorMusicβ€’5mo ago
@blacksmithforlife πŸ‡ΊπŸ‡Έ
miklschmidt
miklschmidtβ€’5mo ago
And you restarted klipper after changing printer.cfg?
ElevatorMusic
ElevatorMusicβ€’5mo ago
@miklschmidt yesss
miklschmidt
miklschmidtβ€’5mo ago
is your beacon extension up to date?
ElevatorMusic
ElevatorMusicβ€’5mo ago
@miklschmidt
No description
No description
ElevatorMusic
ElevatorMusicβ€’5mo ago
yes I think it is seems like it is a beacon issue
miklschmidt
miklschmidtβ€’5mo ago
that is not the latest version Do a moonraker refresh and update should fix your problem Oh i'm blind you're right it is the prefixed g in the commit hash confused me So @ElevatorMusic you prolly just need to restart the klipper service Klipper won't reload the python file unless it's actually restarted
miklschmidt
miklschmidtβ€’5mo ago
No description
ElevatorMusic
ElevatorMusicβ€’5mo ago
I've even rebooted the pi @miklschmidt same thing
miklschmidt
miklschmidtβ€’5mo ago
woot Odd.. There's a pretty huge try / catch block on the exact line it's complaining about @ElevatorMusic i'd try asking on the annex discord or post an issue on the beacon github (https://github.com/beacon3d/beacon_klipper/issues), remember to show them this https://discord.com/channels/582187371529764864/1199533915912798268/1199873889367503039 and mention the rpi booting :).
ElevatorMusic
ElevatorMusicβ€’5mo ago
ouch ouch its getting serious
miklschmidt
miklschmidtβ€’5mo ago
wait @ElevatorMusic when you setup your beacon did you go through the beacon install procedure? There's a chance you overrode RatOS's preinstalled beacon setup, and you're updating the wrong one. Because i noticed you hardcoded a by-id serial in your printer.cfg when RatOS already handles all this for you
ElevatorMusic
ElevatorMusicβ€’5mo ago
@miklschmidt I had my old beacon setup before ratos supported it. When I upgraded to the revH the serial wouldn’t work and so the solution I found was to hardcode it.
miklschmidt
miklschmidtβ€’5mo ago
Yeah that's definitely it then, RatOS won't symlink the beacon.py file if it already exists in the destination. Go and update your old beacon installation and i'm sure the problem is solved πŸ™‚ I would also advise that you either override the beacon entry in your moonraker.conf to point to your old installation or you delete the beacon.py file in klippy/extras and run ~/printer_data/config/RatOS/ratos-update.sh Also RevH is supported in RatOS now so you can remove the serial. btw the way you do that is by ssh, navigate to your old beacon installation cd ~/whereveryouputit and do git pull
ElevatorMusic
ElevatorMusicβ€’5mo ago
No description
ElevatorMusic
ElevatorMusicβ€’5mo ago
I wonder if beacon and beacon klipper are both supposed to be there @miklschmidt
miklschmidt
miklschmidtβ€’5mo ago
beacon_klipper is your old installation That's the one that's currently symlinked into klipper/klippy/extras
ElevatorMusic
ElevatorMusicβ€’5mo ago
so delete it
miklschmidt
miklschmidtβ€’5mo ago
That's why updating through Mainsail does nothing (that updates ~/beacon) I wrote what you should do https://discord.com/channels/582187371529764864/1199533915912798268/1199894035867897957 if you just delete beacon_klipper you're gonna leave a dead symlink in ~/klipper
rm ~/klipper/klippy/extras/beacon.py
rm -rf ~/beacon_klipper
sudo ~/printer_data/config/RatOS/scripts/ratos-update.sh
sudo systemctl restart klipper
rm ~/klipper/klippy/extras/beacon.py
rm -rf ~/beacon_klipper
sudo ~/printer_data/config/RatOS/scripts/ratos-update.sh
sudo systemctl restart klipper
should get rid of your old installation, symlink the one managed by RatOS and restart klipper.
ElevatorMusic
ElevatorMusicβ€’5mo ago
and it works! moonraker was updating the other install Thank you for all the help.
miklschmidt
miklschmidtβ€’5mo ago
np πŸ™‚