Skip to content

Commit

Permalink
Add variables
Browse files Browse the repository at this point in the history
  • Loading branch information
ehu-ti8m committed Feb 1, 2024
1 parent 27e0a23 commit 52aee8d
Showing 1 changed file with 16 additions and 8 deletions.
24 changes: 16 additions & 8 deletions config/software/boot_logo.cfg
Original file line number Diff line number Diff line change
@@ -1,20 +1,28 @@
[gcode_macro _USER_VARIABLES]
variable_minidisplay_bootlogo_enabled = True
variable_minidisplay_bootinfo_enabled = True
variable_minidisplay_bootinfo_name = "PrinterName"

#### START SPLASH SCREEN
# Comment Out to Disable or Set 'custom' to New Name
[delayed_gcode START_LOGO]
initial_duration: 0.001
gcode:
{% set custom1 = "_my_intro" %}
SET_DISPLAY_GROUP GROUP={custom1}
UPDATE_DELAYED_GCODE ID=clear_display DURATION=4
{% set bootlogo_enabled = printer["gcode_macro _USER_VARIABLES"].minidisplay_bootlogo_enabled %}
{% if minidisplay_bootlogo_enabled %}
{% set custom1 = "_my_intro" %}
SET_DISPLAY_GROUP GROUP={custom1}
UPDATE_DELAYED_GCODE ID=clear_display DURATION=4

#### START SPLASH SCREEN
# Comment Out to Disable or Set 'custom' to New Name
[delayed_gcode START_INFO]
initial_duration: 4
gcode:
{% set custom = "_my_info" %}
SET_DISPLAY_GROUP GROUP={custom}
UPDATE_DELAYED_GCODE ID=clear_display DURATION=4
{% set bootinfo_enabled = printer["gcode_macro _USER_VARIABLES"].bootinfo_enabled %}
{% set custom = "_my_info" %}
SET_DISPLAY_GROUP GROUP={custom}
UPDATE_DELAYED_GCODE ID=clear_display DURATION=4

#### CLEAR MESSAGE AND SET DEFAULT DISPLAY GROUP
[delayed_gcode clear_display]
Expand Down Expand Up @@ -47,12 +55,12 @@ text:
~kp30~~kp31~~kp32~~kp33~~kp34~~kp35~~kp36~~kp26~

#####################################
# My Info
# My Info Override Printer Name with your own
#####################################
[display_data _my_info info3]
position: 0, 0
text:
PrinterName
{printer["gcode_macro _USER_VARIABLES"].minidisplay_bootinfo_name}

[display_data _my_info info1]
position: 1, 0
Expand Down

0 comments on commit 52aee8d

Please sign in to comment.