I'm Stuart, I've been 3D printing at home for about 2 years now, though I couldn't even tell you what kind of printer I have - it was a Chinese kit from Amazon, since discontinued - I've had to start from pretty much first principals, upgrading bits and bobs, calibrating it all etc, but it works pretty well now - an excellent learning experience !
Anyway, I've noticed that sometimes I get G-Code that doesn't execute.
I use Slicr, and as you know, it has two blocks of automatically inserted startup g-code and lets you insert your own custom code in the middle. The code I want to run looks like the following:
Code: Select all
M107 M190 S80 ; set bed temperature M104 S200 ; set temperature ; above 3 commands are slicr-generated ; below is my custom code G21 ; set units to mm (slicr adds later, but am moving bed, so do here) G90 ; set absolute coords (ditto) G92 X0 Y-15 Z0 ; adjusts so (0,0) is on the bed, adjust to suit G1 Z3 F3000 ; lift nozzle G1 X0 Y0 F4800 ; home x and y ; and from here on is slicr-generated M109 S200 ; wait for temperature to be reached G21 ; set units to millimeters G90 ; use absolute coordinates M82 ; use absolute distances for extrusion
The trouble I have is that sometimes my code doesn't execute when I'm running from an SD card - the printer doesn't move but just goes straight from bed heating to nozzle heating. Worse still, the hardware seems to think it has raised the z axis by 3mm when it actually hasn't, so when it starts printing, it ploughs a furrow through my blue tape.
I suspect it's something to do with the M190 command, 'set bed temp and wait', I'm guessing that the 'wait' part confuses the processor so that it skips the following commands - if I start the print job when bed and nozzle are already spot on temperature then the code executes fine and the nozzle moves. I don't have the problem if i run the code tethered to the laptop instead of from SD card.
Any ideas what causes this, and how I could fix it ?
(I don't really have my bed at 80 degrees in case you're wondering, my bed sensor is wrong, reads in the 40's at room temperature !)