Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does this work with prusaSlicer? #27

Closed
appleimperio opened this issue Sep 20, 2023 · 2 comments
Closed

Does this work with prusaSlicer? #27

appleimperio opened this issue Sep 20, 2023 · 2 comments
Labels
question Further information is requested

Comments

@appleimperio
Copy link

Is your feature request related to a problem? Please describe.
Already configured the user_profile and add the commands to my Prusaslicer but when I slice the model I got various error "Parsing error at line X: Not a variable name" in various parts of the slicer not only in the custom start gcode but in the layer change too

Clearly outline your question
I just want to know if this work with Prusaslicer? or most of those variables are only for Supe Slicer

Describe your hypothesis
I think most of the variables used are only for Superslicer

before_layer_gcode
Parsing error at line 3: Not a variable name
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=material_color VALUE={filament_colour_int}
                                                                  ^
layer_gcode
Parsing error at line 3: Not a variable name
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=material_color VALUE={filament_colour_int}
                                                                  ^
start_gcode
Parsing error at line 4: Not a variable name
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=extruder_temp VALUE={first_layer_temperature[initial_extruder] + extruder_temperature_offset[initial_extruder]}
                                                                                                             ^
Please inspect the file /var/folders/7d/pvpt96_117l98cnrbh3719s40000gn/T/.36239.gcode.tmp for error messages enclosed between
        !!!!! Failed to process the custom G-code template ...
and
        !!!!! End of an error report for the custom G-code template ...
for all macro processing errors.```
@appleimperio appleimperio added the question Further information is requested label Sep 20, 2023
@github-actions
Copy link
Contributor

Welcome appleimperio!\nCongrats on creating your first issue.\nPlease follow the issue template to help us resolve your issue quickly.

@rootiest
Copy link
Owner

rootiest commented Sep 21, 2023

Yes it does work in PrusaSlicer (except for chamber temperature) but there are a few slight differences.

These are the codes I use in PrusaSlicer:

Start Gcode:

;print_cfg variables
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=extruder_temp VALUE={first_layer_temperature[initial_extruder]}
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=bed_temp VALUE={first_layer_bed_temperature[initial_extruder]}
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=chamber_temp VALUE=35
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=material_type VALUE="'{filament_type[initial_extruder]}'"
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=layer_count VALUE={total_layer_count}
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=tool_count VALUE={total_toolchanges}

start_print

End Gcode:

end_print

Before Layer Change:

; Layer [layer_num]

;print_cfg variables
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=material_type VALUE="'{filament_type[current_extruder]}'"
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=material_color VALUE="'{filament_colour[current_extruder]}'"
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=layer_count VALUE={total_layer_count}
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=layer_num VALUE={layer_num}
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=layer_z VALUE={layer_z}

After Layer Change:

; Layer [layer_num]

;print_cfg variables
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=material_type VALUE="'{filament_type[current_extruder]}'"
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=material_color VALUE="'{filament_colour[current_extruder]}'"
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=layer_count VALUE={total_layer_count}
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=layer_num VALUE={layer_num}
SET_GCODE_VARIABLE MACRO=_printcfg VARIABLE=layer_z VALUE={layer_z}

; Increment layer in Klipper
SET_PRINT_STATS_INFO TOTAL_LAYER={total_layer_count} CURRENT_LAYER={layer_num}
_BEGIN_LAYER

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants