Jump to content
Ultimaker Community of 3D Printing Experts

Replacement pattern with {...} won't get replaced


Recommended Posts

Posted (edited) · Replacement pattern with {...} won't get replaced

Hi there,

 

I have some strange behavior when slicing, which is probably just because I don't see my mistake. I'm using some custom start code. One of the lines contain for example 

M140 S{material_bed_temperature_layer_0}

  

My expectaion would be to see something like "M140 S60" in the sliced G-Code file, but what I see is for example this:

 

;FLAVOR:Marlin
M73 P0
M117 Time Left 0h40m33s
;TIME:2433
;Filament used: 1.01777m
;Layer height: 0.1
;MINX:79.625
;MINY:74.192
;MINZ:0.1
;MAXX:150.375
;MAXY:144.942
;MAXZ:27.65
;POSTPROCESSED
;Generated with Cura_SteamEngine 4.10.0
M82 ;absolute extrusion mode
; Ender 3 Start G-Code
M501                                                                   ; Standardwerte laden
M82                                                                      ; absolute Extrusion
M117 Vorbereiten                                                         ; Info am LCD
M107                                                                   ; Bauteil-Lüfter aus
M140 S{material_bed_temperature_layer_0}                   ; Bett heizen
M104 S180                                                                        ; Düse vorwärmen

 

There is no M140 from Cura before my start code. That basically indicates that Cura recognized that I have own temperture settings in my start code. Fine!
But why do I still see the variable name instead of the value?

 

And an additional question: is there a posibility to make an easy calculation in custom start code? Somthing like "M140 S{material_bed_temperature_layer_0} + 15.0" ?

Thanks!

Edited by Uwe11
  • Link to post
    Share on other sites
    Posted · Replacement pattern with {...} won't get replaced

    To answer the second part of your question: no, there is no way to do simple math with the replacement patterns.

    • Thanks 1
    Link to post
    Share on other sites
    Posted · Replacement pattern with {...} won't get replaced

    I don't see why/how the pattern replacement is not working from the snippet you posted; the spelling seems correct.

    Can you save a project file (using File -> Save project...) and post a link to it here? Then I can have a look at your exact start gcode, as well as any postprocessing and other settings that could affect this.

  • Link to post
    Share on other sites

    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now
    • Our picks

      • Ultimaker turns 10: A look back
        Ultimaker is turning 10 years old and that means it is story telling time! We'll explore 2010-2014, traveling through the evolution of the business from the Protobox and Ultimaker Original, to the major leaps forward with the Ultimaker 2 and Ultimaker 3.
          • Like
        • 0 replies
      • Ultimaker Transformation Summit
        Visit our virtual showroom and learn more about the Ultimaker ecosystem!
        • 14 replies
      • New here? Register your Ultimaker for free 3D printer onboarding course
        Hi,
         
        Often getting started is the most difficult part of any process. A good start sets you up for success and saves you time and energy that could be spent elsewhere. That is why we have a onboarding course ready for
        Ultimaker S5 Pro Bundle, Ultimaker S5, Ultimaker S3 Ultimaker 2+ Connect.   
        They're ready for you on the Ultimaker Academy platform. All you need to do to gain access is to register your product to gain free access. 
        Ready? Register your product here in just 60 seconds.
          • Like
        • 4 replies
    ×
    ×
    • Create New...