commit
1390e7a6a1
2 changed files with 19 additions and 2 deletions
|
@ -22,6 +22,11 @@ command: sh /usr/data/helper-script/files/scripts/useful_macros.sh -restore_moon
|
|||
timeout: 600.0
|
||||
verbose: true
|
||||
|
||||
[gcode_shell_command Reload_Camera]
|
||||
command: sh /usr/data/helper-script/files/scripts/useful_macros.sh -reload_camera
|
||||
timeout: 600.0
|
||||
verbose: true
|
||||
|
||||
|
||||
[gcode_macro KLIPPER_BACKUP_CONFIG]
|
||||
gcode:
|
||||
|
@ -42,6 +47,10 @@ gcode:
|
|||
gcode:
|
||||
RUN_SHELL_COMMAND CMD=Moonraker_Restore
|
||||
|
||||
[gcode_macro RELOAD_CAMERA]
|
||||
gcode:
|
||||
RUN_SHELL_COMMAND CMD=Reload_Camera
|
||||
|
||||
|
||||
[gcode_macro BED_LEVELING]
|
||||
description: Start Bed Leveling
|
||||
|
|
|
@ -58,6 +58,12 @@ function restore_moonraker(){
|
|||
exit 0
|
||||
}
|
||||
|
||||
function reload_camera(){
|
||||
echo -e "Info: Reloading camera config..."
|
||||
ACTION=reload /usr/bin/auto_uvc.sh
|
||||
exit 0
|
||||
}
|
||||
|
||||
if [ "$1" == "-backup_klipper" ]; then
|
||||
backup_klipper
|
||||
elif [ "$1" == "-restore_klipper" ]; then
|
||||
|
@ -66,7 +72,9 @@ elif [ "$1" == "-backup_moonraker" ]; then
|
|||
backup_moonraker
|
||||
elif [ "$1" == "-restore_moonraker" ]; then
|
||||
restore_moonraker
|
||||
elif [ "$1" == "-reload_camera" ]; then
|
||||
reload_camera
|
||||
else
|
||||
echo -e "Invalid argument. Usage: $0 [-backup_klipper | -restore_klipper | -backup_moonraker | -restore_moonraker]"
|
||||
echo -e "Invalid argument. Usage: $0 [-backup_klipper | -restore_klipper | -backup_moonraker | -restore_moonraker | -reload_camera]"
|
||||
exit 1
|
||||
fi
|
Loading…
Add table
Reference in a new issue