Software for Plan-B

Previous step

The next step is software. While plan B is capable of 3D printing in normal Gcode, printing in special Plan B code is orders of magnitude faster and more accurate. The way this is done right now is by first using a normal Gcode slicer to make the initial file, then use a piece of temporary software (Plan B converter) written by me to convert this initial file to Plan B code. The slicer I am using is Slic3r, but in theory most modifiable slicers will be capable of making the code that Plan B converter can use.

This is not ideal, far from perfect and maybe a bit unwieldy, but right now it is the only way. In the future there will be a special piece of software that converts an stl model directly into Plan B code, but for now, this will have to do.

Download software here:

[download converter]

Plan B converter needs to be opened in QT Creator, which can be downloaded here: http://www.qt.io/download-open-source/  (QT Creator is near the bottom)

Any version of QT creator will do, but it needs to have QT version Desktop 5.2.1 MinGW 32bit. With this installed, you can open Plan B converter in QT and run it with the 5.2.1 MinGW compiler.

EDIT 03/07/15 (dd/mm/yy):

I finally got a new computer, and on this one, not all dll’s are messed up. I managed to make Plan B converter stand alone. The top piece of information will be converted shortly

[Download the new converter]

 

Download and install Slic3r. This can be downloaded at http://slic3r.org/.

The settings need to be adjusted so it creates files that Converter can read. In it’s simplest form, plan B converter needs an outline (ONLY an outline) of the part that is going to be printed. Other modifications are layer thicknesses and code types. The full list of necessary modifications is listed below, together with images of all modifications shown in the Slic3r window.

  • In Print settings -> Layers and perimeters: Layer height is the layer thickness Plan B will print at. I usually have this value between 0,15mm and 0,2mm, depending on the part size. 0.18 has worked perfectly for me so far. Perimeters is the amount of outlines of the print. We NEED this to be 1, it is basically what converter reads. Solid layers need to be both 0, we don’t want any infill anywhere. All check boxed need to be off, especially the first and third.
  • In Print settings -> Infill: make fill density 0%, more out of courtesy than it being necessary.
  • In Print settings -> speed: no changes need to be made, Converter simply ignores speed, Plan B figures out it’s own speed.
  • In Print settings -> Skirt and brim: no changes are necessary.
  • In Print settings -> support material: turn Generate support material off, make Raft layers 0.
  • In Print settings -> Notes: Nothing of importance here.
  • In Print settings -> Output options: Default values will do.
  • In Print settings -> Multiple extruders: All values need to be 1, check boxes need to be off.
  • In Print settings -> Advanced: all default values.
  • In Filament settings -> Filament: Diameter can be a default 1.75mm.
  • In Filament settings -> Cooling: Everything is turned off here.
  • In Printer settings -> General: Make the Bed size the printer bed size (plan B is 150mmx150mm) and make the Print center half of that. make the Z-offset the layer thickness times -1. (ie. layer height 0.18mm makes Z-offset -0.18mm). Make the G-code favor ‘Reprap (Marlin/Sprinter/Repetier)’. Turn the Use relative E distances off.  Make the Extruders 1.
  • In Printer settings -> Custom G-code: No additional code is needed.
  • In Printer settings -> Extruder 1: Nozzle diameter needs to be the droplet size of a cartridge, in the case of Plan B (HP C6602A, 96DPI) 0.26mm. All other values don’t really matter.

 

Save these setting and go to the Plater tab and load in the file you want to print. Orient it the way you want it to be printed (with Plan B, fewer layers means faster prints) and scale it if necessary. Make sure all the right settings are selected, there are drop down menus where you can select what settings to use. Here you can also note the height of the print, it will help determine how much material needs to be loaded in the printer. Click the Export G-code button and save this file in a place you will remember. With the part sliced, it is time to start Plan B converter.

Plan B converter will turn this Gcode file into Plan B optimized code. It doesn’t work perfectly for everything, but for most files it creates code good enough for processing. It can either be opened from QT Creator or opened from it’s .exe file. It has a few settings that need to be checked before every file.

  • in Settings: X-size and Y-size needs to be set to the size of Plan B (150mmx150mm). If this value is too low, it will skip a part of the file. Too big will only cost extra RAM memory while converting.
  • in Settings: Cartridge resolution, the resolution needs to be set to the DPI of the cartridge, in case of the HP C6602, 96DPI.
  • in Settings: Nozzle row width needs to be the amount of nozzles in the cartridge. in case of the HP C6602, 12 nozzles.
  • in Settings: Sweep direction modifies if the printer will print in one direction (more accurate) or in both directions (faster). One direction is the safest choice, it requires no additional tweaking in the firmware. Double direction makes the printer print in both directions, but the firmware needs to be adjusted to make this accurate enough to work.
  • in Settings: Pass count determines how many times a sweep is printed. Not all cartridges have droplets large enough to fill everything. In this case, small gaps will appear between each of the lines. This will severely weaken the part. By setting this value to double, the printer will print another set of lines between the already printed lines, filling the gap.

When all the settings are right, go to File and click the Open File button. It will open a window where you can select the Gcode file sliced by Slic3r. Click open and then when everything else seems right, click the Convert File button. This too will open a window where you can set the name of the output file and where it needs to go. When a place is selected, click save and wait for a moment. Plan B converter gives no feedback while converting, it may seem like it is not responding, but it is merely busy converting the file. Depending on the complexity of the file, it may take up to a minute to convert it, though small files will convert instantly. This file can be loaded on the SD card.

This file has to be renamed to “print.txt” to make the printer actually print it. Remember to do this before you insert the SD card in the printer.

 

 

Plan B converter is a temporary solution. It works good enough to make Plan B work, but it is not ideal. There is already someone working on a more permanent solution for the software. Plan B converter will make mistakes in the file, clearly visible in most prints during printing. These mistakes are not big enough to make the print fail, but still should not be there. When you look in the code of Plan B converter, you will find that it is fairly inefficiently written. I am not a full time programmer. I make functional pieces of code, not pretty ones. If there is anyone capable and willing to help with the software and firmware of Plan B, please contact me.

Next page

19 Comments

  1. “output_data << "G1 Y" << grid_line_coordinate[l*12] << " Z" << Z_height << " D" << grid_line_direction[l*12] << "\n";"
    this line makes me confused.
    "l*12",i think "12" represents the nozzle width,l*12 will always be an even number,this makes the value of "grid_line_direction[l*12]" aways be 1.The 2 directions of sweeping will be never activated.

  2. Hi,appreciating for your wonderful work. I have converted the C++ code to the Java code,and fixed several mistakes.(just like the repeated nozzle tags,N0 N0 N0 X1.0 T0,etc). Wish to have a interaction with you via email.thanks.

  3. Hi,
    I was wondering if you know how to fix the error “This application failed to start because it could not find or load the Qt platform plugin “windows”” when loading from the new standalone file. I also haven’t been able to get the older QT Creator dependent .pro file from building. My effor for this one says “Could not start process “D:\Qt\Qt5.2.1\5.2.1\mingw48_32\bin\qmake.exe” D:\Plan_B_converter\Plan_B_converter\Plan_B_converter.pro -r -spec win32-g++ “CONFIG+=debug” “CONFIG+=declarative_debug” “CONFIG+=qml_debug”
    Error while building/deploying project Plan_B_converter (kit: Desktop Qt 5.2.1 MinGW 32bit)
    When executing step ‘qmake'”

    If you know how to fix this that would be very helpful.
    Andrew

      • Is there anything different you might need to do if you run the printer on gcode alone? I am likely mostly printing smaller designs with simple shapes (less than 20mmx20mm and shapes usually will have the same horizontal cross section shape). You still will need to name the print file “print.txt,” right?

        Thank you for your help with this.
        Andrew

        • Print.txt is only opened in the firmware, and then almost blindly read. Any reasonable line it can read is moved to machine code in the firmware, including movement commands. (Z going up, down is ignored). The printer should follow this just fine. Have you first updated the SD card library in arduino. Between Plan B being published and now, the library has been dug around in and they have broken a few thing in some versions. I will send you a test file to see if it is read.

    • Build piston only moving in one direction can mean that the direction pin on the motor driver does not work. Firmware might be the culprit, but I think the hardware is more likely. You are using a megatronics V3?

      • Thank you for your answer. I handled it via changing the optical endstop of build piston with a new one. But i have a new problem. Printing does not start on the middle of table. How can i fix it? Is it about firmware or slic3r options?

        Thank you

        • That can be fixed either in the slicer or in the firmware. The firmware has a location that is (0;0), which is in the corner of the printbed, closest to all endstops. The slicer also has a (0,0), which can be either in the middle, or in the corner of the printbed. Middle or corner does not matter, as long as they are both the same. Having said that, fixing this is easiest in slic3r. The (0;0) point should be in the bottom left corner.

  4. I have begun printing with Plan B and it is great. I have noticed that when I choose to print with multiple passes I get better results, but I have also noticed that not every y-section (x-sweep) uses the number of passes specified. Most do, but often I will have it set for two or three passes and there will be sections where it only sweeps once (and sometimes not at all?) and then moves in the y-direction to the next sweep. I’m assuming this is a bug in the Converter Software, but have yet to delve into the code.

    Are you aware of this problem and potential fixes? I would think you will be using something similar to the Plan-B Code on your Oasis project, and this may be an important fix for consistent, future results.

    • It really depends on where it happens whether it is a bug or not. If it happens in the middle it is a bit sketchy, if it happens on the ends, it is more possible. The thing to look for is if that one sweep only prints a thin line segment. If it does, then the one sweep might be intentional (there is nothing to print in the second sweep). If all of these reasons do not apply to you, there might be a bug. The converter is far from bug free.

  5. For future reference to anyone doing this now or later, I only had success when I used Slicer version 1.1.7 (the same used above).

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.