/ README.md
README.md
1 # OctoPrint-GPX 2 An OctoPrint plugin for MakerBot (prior to 5th gen) and clones. 3 4 It uses GPX to translate gcode to x3g underneath OctoPrint in the communications 5 layer. 6 7 [GPX](https://github.com/whpthomas/GPX) is a *G*code *P*ostprocessing to *X*3g 8 tool written by [WHPThomas](https://github.com/whpthomas). Gcode is a language 9 for describing toolpaths in 3d printers which is derived from the gcode used in 10 CNC machines. X3g is an extension to the s3g protocol which was named for the 11 Sanguino v3 which was in use at the time as the bot's controller. 12 13 ## Caveats 14 I've only tested this on one config: 15 Raspberry Pi set up via the OctoPi image 16 FlashForge Creator Pro running Sailfish 7.7 17 18 ## Installing 19 1. Start with OctoPi: Get your Raspberry Pi up and running by following the 20 instructions on [OctoPi](https://octopi.octoprint.org) 21 22 2. Get the GPX plugin. You get plugins by using the Plugin Manager in OctoPrint. 23 24 * Open a browser to octoprint (http://ipaddress/) and login 25 * Choose "Settings" from the top bar 26 * Click "Plugin Manager" on the left side 27 * Click the "Get More..." button 28 * Find GPX in the list and click "Install" 29 * Restart octoprint (if you're using OctoPi: System.Restart from the menu bar) 30 * Refresh your browser 31 32 3. Set and save the GPX settings. 33 34 * OctoPrint-\>Settings-\>GPX 35 * Pick your machine type: *Replicator 1 Dual* (if you have a clone, it's 36 most likely a Rep 1 clone even if it was sold as a Rep 2 clone) 37 * Set the gcode flavor to "RepRap" and your slicer too. The only reason to 38 use MakerBot flavor is if you are using a MakerBot slicer. 39 40 4. Try connecting 41 42 Choose a port and baudrate. I don't have AUTO working yet. 115200 works 43 on my bot. 44 45 5. Upload gcode from your slicer to OctoPrint. 46 47 OctoPrint only understands ".gcode" and then GPX translates it to x3g. 48 Don't upload x3g to OctoPrint. That won't work. 49 50 On the other hand, only use ".x3g" with the printer's SD card. It doesn't 51 understand gcode and GPX running in OctoPrint can't help the firmware with 52 it directly on the SD card. 53 54 ## Known issues 55 * Upload to SD doesn't work. It can't work directly because SailFish removed 56 that feature to save bytes. Probably a good call since who wants to wait for 57 115200 baud when you can just plug the SD card into your PC. 58 [Google Groups Post](https://groups.google.com/d/msg/jetty-firmware/KCIfkv02MPY/SX17OBhXoJMJ) 59 I'm working on FlashAir support 60 * Can't delete SD files for a similar reason 61 * For prints that have small segments that don't require full stops to move to 62 the next one (ie cylinder with a smooth surface), you'll be happier printing 63 off of the printer's SD card. Printing over serial peaks out at about 60 64 segments per second. 65 * Upload to OctoPrint and then print works with .gcode, not with .x3g. The GPX 66 layer converts the gcode to x3g when you print from OctoPrint. I need to 67 figure out a way to make the UI more graceful about this. To review: If the 68 destination is OctoPrint and let it drive: .gcode. If the destination is the 69 SD card and let the bot drive the print: .x3g. 70 71 ## Plan 72 73 I was thinking for my next project, possibly, to start an OctoPrint plug-in 74 that will talk to the FlashAir SD card directly bypassing the motherboard on 75 the the bot. 76 77 The GCode viewer can't follow along the build on the SD card because it doesn't 78 have a good way to understand where the bot is in printing an x3g file. I'm 79 thinking about this one. Perhaps we can use the number of commands processed to 80 line something up. I have the printer reporting current position back to 81 OctoPrint every second or so now, so theoretically it could follow along-ish on 82 z-change, but it'd be guessing about the pacing in between. It'd require a new 83 hook or something in OctoPrint.