# How to make a printer bed vibrate using g-code (heated chemical stirrer)?

I was just about to start using my 3D printers heated bed to warm a chemical reaction in a container and was thinking it would be great to be able to get the bed stepping back and forth to stir the pot. Can anyone already up to speed in programming G-code walk me through a quick and dirty way to get the X-axis on my old Printrbot metal doing a couple of micro-steps either way in an endless loop? Or suggest some software out there that could achieve the same effect?

Basically you need to write a G-code file yourself. This is a plain text file with a .g extension.
You need to home the printer with G28, then move the Y axis all the way forward (for a Prusa style printer) with G1 F1500 Y{ymax} (where {ymax} is the length of the bed). Now raise the head with a similar command G1 F500 Z{zmax} (where {zmax} is the height of the printer volume).
Heating the bed is done with M190 S60 (set and wait to reach 60 °C).
You can now rock the Y axis by moving it fast, e.g. with G1 F5000 Y{ymax-5}, G1 Y{ymax-1}, Y{ymax-5}, Y{ymax-1}, etc.