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

Add G-code export for M3D Micro #4919

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

natanoj
Copy link

@natanoj natanoj commented Jan 17, 2020

Add a new printer profile for M3D Micro which needs minor differences to all the existing printer profiles to print the generated G-code. Builds with all existing tests passing on my Debian Buster. Have tested a few printouts which works on the M3D Micro.

@AppVeyorBot
Copy link

@@ -67,7 +67,9 @@ GCodeWriter::preamble()
std::ostringstream gcode;

if (FLAVOR_IS_NOT(gcfMakerWare)) {
gcode << "G21 ; set units to millimeters\n";
if (FLAVOR_IS_NOT(gcfM3dMicro)) {
gcode << "G21 ; set units to millimeters\n";
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So that printer firmware does something weird for g21?

But you need G90 in the defaults?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, that printer does not accept G21. More specifically, it doesn't accept other combinations of specific printer profiles in the export code either. I went through them one by one, and each profile adds a g-code or syntax that this simple printer does not accept unfortunately.

A better, more generic, way would perhaps be to have a generic default, which would be similar to this new profile, and have a specific option for the G21.

While I was looking through the export code, I noticed that it bocomes more cluttered the more printers are added. For that reason I don't like my own change, but it gets the job done for me.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I went through the Spooler logs from the M3D supplied spooler, and in there I can see that the printer identifies as a Repetier protocol 2 firmware. However, when looking at the generated G-code from the supplied Cura engine, it does not fully match what is generated with the Repetier setting in Slic3r. The printer returns an error code for G21, and other G-codes for mainly extrusion does not match the M3D generated G-code.

I'll make a test with the Repetier setting, and manually remove the G21 to see if that works. The G21 is still problematic though.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested G-code generated by the Repetier export. With the G21 left in, the printer just stops at that command. Without G21 it stops after warming up. It is interesting though that when I run the exact same sequence of generated G-codes manually without G21 (i.e. with a lot of time in between each command) they work in the generated sequence. I suspect it is the M82 directly after G90 that causes the hickup. So the most reliable setting for this printer is with this small addition.

Of course, still up to you if this is something that should be included or not. At least now I have a setup that works for me for this printer.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suspect that the better long term solution is to have a "generic" flavor that lets the user provide a file that says "use X to do task Y".
Leaving an entry blank would be enough to say "my printer can't do this, so skip"

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

Successfully merging this pull request may close these issues.

None yet

3 participants