7
$\begingroup$

Often, the pre-generated G-code is enough for start and end. However, sometimes we want to have something different. In this case: how to generate an audible alert of something like 4 bleeps at the end of the print, after putting the printer into the end position and when the bed has reached a "safe" 30 °C?

$\endgroup$

2 Answers 2

9
$\begingroup$

Let's put the parts one by one:

  • Wait for bed temperature being at 30 °C: M190 R30
  • Play Bleep for 1/5th of a second: M300 S440 P200
  • Wait for 1/5th of a second: G4 P200

That gives:

M190 R30
M140 S0
M300 S440 P200
G4 P200
M300 S440 P200
G4 P200
M300 S440 P200
G4 P200
M300 S440 P200
G4 P200

Just for 0scar:

M300 S1396.91 P400 ;f7
G4 P400
M300 S1661.22 P600 ;as7
M300 S1396.91 P400 ;f7
M300 S1396.91 P200 ;f7
M300 S1864.66 P400 ;b7
M300 S1244.51 P400 ;es7
M300 S1396.91 P400 ;f7
G4 P400
M300 S2093.00 P400 ;c8
M300 S1396.91 P400 ;f7
M300 S1396.91 P200 ;f7
M300 S2217.46 P400 ;des8
M300 S2093.00 P400 ;c8
M300 S1661.22 P400 ;as7
M300 S1396.91 P400 ;f7
M300 S2093.00 P400 ;c8
M300 S2793.83 P400 ;f8
M300 S1244.51 P400 ;es7
M300 S1244.51 P200 ;es7
M300 S1046.50 P400 ;c7
M300 S1567.98 P400 ;g7
M300 S1396.91 P1600 ;f7
$\endgroup$
3
  • 1
    $\begingroup$ Cool, I'll implement it as soon as you post how to play this! ;) $\endgroup$
    – 0scar
    Sep 23, 2019 at 4:53
  • 2
    $\begingroup$ @0scar There you go. Beverly Hills cop. $\endgroup$
    – Trish
    Jan 13, 2020 at 21:37
  • $\begingroup$ Lol! I will give it a try! $\endgroup$
    – 0scar
    Jan 13, 2020 at 22:01
1
$\begingroup$

Trish's version is good but wait for bed temperature being at 30 °C (M190 R30) before setting the temperature to 0 °C (M140 S0)

So this is my version:

G91 ;relative positioning
G1 E-1 F300  ;retract the filament a bit before lifting the nozzle, to release some of the pressure
G1 Z+0.5 E-5 X-20 Y-20 F9000 ;move Z up a bit and retract filament even more
G28 X0 Y0 ;move X/Y to min endstops, so the head is out of the way
G1 Y150 F5000 ;move completed part out
M84 ;steppers off
G90 ;absolute positioning
M190 R30 ;waits until cooling to 30 °C
M300 S300 P1000 ;beep
M300 S300 P1000 ;beep
M300 S300 P1000 ;beep
M300 S300 P1000 ;beep
M104 S0 ;extruder heater off
M140 S0 ;heated bed heater off 
$\endgroup$
3
  • $\begingroup$ S perimeter is "this or more" - 60 is more than 30, so triggers S. $\endgroup$
    – Trish
    Oct 4, 2019 at 13:54
  • $\begingroup$ ups yeah my bad..I was talking about the M190 R30 gcode but - hey - you used the "R" right so my fault..I'm gonna edit my answer $\endgroup$
    – jæk
    Oct 4, 2019 at 14:34
  • $\begingroup$ Yur order of commands in the revamped... You do realize that you set the bed off (M140 S0) and then demand the printer to target 30°C after that and not turn off the bed again? $\endgroup$
    – Trish
    Oct 5, 2019 at 15:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .