Wednesday, December 28, 2016

Converting a SeeMeCNC Rostock MAX V3 to Duet WiFi

After a couple of months of working with my V3 in its stock configuration, it's time to migrate to a Duet WiFi controller and RepRapFirmware - for all of the reasons I've written about on this blog. The RAMBo controller that comes with the V3 is fine but it is at least 50 years old in "controller years". While many hobbyists can use RAMBo to make some nice prints, until you've experienced Duet and RepRapFirmware you don't know what you've missed. So let's dive in...

Materials and Preparation
You should take care of a couple of things before diving in to replace the RAMBo. First, you should have all of the necessary parts on hand. These are:

1x Duet WiFi - will include a connector kit
1x 7" PanelDue - this is optional and/or you could use the smaller 4.3" PanelDue

Digi-Key part numbers. I recommend getting 50 pins to have extras:

  • 5x connector housing male 4 position (WM2535-ND)
  • 3x connector housing male 3 position (WM2534-ND)
  • 3x connector housing male 2 position (WM2533-ND)
  • 35x connector male 24-30awg pins (WM2565-ND)
Adafruit 3.3v Trinket - to make the HE280 accelerometer probing adapter as described here (the parts above include the connectors for the adapter)

Print my 7" PanelDue Enclosure if you are installing the 7" PanelDue option

A few pieces of scrap wire. If you kept the scraps from your original kit, you have more than enough!

Pre-commisioning the Duet WiFi
The first thing you should do is pre-commision the Duet WiFi to get it on your network and update to the latest firmware stack and my configuration files. All knowledge on Duet is available on the website and forum. All of the following can be done with the Duet WiFi connected to USB to power it.

Step 1 is to get the Duet WiFi connected to your network. The official guide is here, complete it and then continue.

Step 2 is updating the config.g and other configuration files. You can download this zip file from my Dropbox. It has the necessary /sys and /macros files. You can upload the ZIP file itself in the Duet Web Interface.
  1. Open the Duet Web Interface and click on the Settings tab on the left side. Make sure the General tab is selected.
  2. Click the Upload Files(s) button and then choose the file you downloaded above.
Step 3 is updating the firmware. The current release version is 1.17. There are 3 firmware files, all pre-built and located here. Click on each one and then click the Download button at the upper right.  Here's how to install them:
  1. Open the Duet Web Interface (after doing step 1 above) and click on the Settings tab on the left side. Make sure the General tab is selected.
  2. Click the Upload Files(s) button and then choose the DuetWiFiFirmware-1.17.bin (or the latest version) file. It is important that you install the files in this order. Once the firmware updates, you will be asked if you want to install it, select Ok and wait for the install to complete.
  3. Do the same for the DuetWebControl-1.14-b4.bin (or latest version) and install it.
  4. Finally, install the DuetWiFiServer-1.03-ch.bin (or latest version) and install it.
You can now disconnect the Duet WiFi from USB and continue with the installation.

Making the Pigtails
Next, you will make the pigtail adapters to make it easy to wire the Duet WiFi.

1) Make four stepper adapters using one of the male 4 position housings on one end and one of the 4 position housings included with your Duet WiFi on the other end. These should be about 3" long (not a critical dimension so don't be persnickety about measuring!) Note the orientation of the locking tabs on the connectors. The colors match the wire colors of the existing RAMBo harness. I like to label the black connector X, Y, Z and E.

Make 4

2) Make three endstop adapters using one of the male 3 position housings on one end and one of the 3 position housings included with your Duet WiFi on the other, also about 3" long. These only have 2 wires so make sure you connect them to the correct pins as shown in the photo.
Make 3

3) Make one hotend thermistor "Y" adapter using one of the male 2 position housings on one end and one 2 position and one 3 position housings included with your Duet WiFi on the other, also about 3" long. I used green and white wire as shown to match the RAMBo harness.
Make 1
4) Make one bed thermistor adapter using one of the male 2 position housings on one end and one 2 position housings included with your Duet WiFi on the other, also about 3" long. Polarity does not matter. I used black and white wire for this.

One of the 4 position housings and one two position housing are used for the Trinket probe interface, the remaining connectors are used once the Duet is in place.

Installing the Duet WiFi
Disconnect the harness and other wiring from the RAMBo. Make sure to mark each as you remove the connector so you know what to reconnect to. A small piece of masking tape with a label on each works well.

Install the Duet WiFi printed adapter using the original screws that attached the RAMBo mounting pillars.

Note the orientation to accommodate the fan. Make sure you don't pinch any wires and that the fan power wires are routed to the right of the fan as shown.

Install the Duet WiFi with its power connectors oriented to the right as shown. Then connect the main power wires (red and black) and heated bed wire (black). It might be easiest to connect these wires before attaching the Duet to the mount. I used 4 M3x10 cap screws with washers to attach Duet.
Next, install the stepper pigtails and connect to the original RAMBo stepper harness. Note the X, Y, Z and E orientation as shown.
Now you can connect the X, Y and Z endstop pigtails and harness - pay attention to install on the proper axes.
Install the Y adapter you made in step 3 above. It connects as shown to the Duet and RAMBo harness.
Connect the bed thermistor adapter.
Find the orange wire coming out of the HE280 whip. You will install a 2 position connector to it as shown. Then install it on the Duet as shown. This is the part cooling fan wire.

NOTE: the ORANGE wire must be attached to the NEGATIVE terminal and not the positive terminal shown in the photo. I can't reshoot this photo as I've completely rewired my V3 and removed the HE280 and accelerometer probe. It is shown correct in the photo below (with the yellow circle) though.

Hook up the hotend wiring to the hotend connector on Duet WiFi as shown.

Install a 2 pin connector on the Rostock MAX V3's top ventilation fan (the one inside the Duet mount cutout) and connect as shown. It is important to get the polarity of the wires correct or the fan will not run.

Now you can install the HE280 accelerometer adapter. Here is the completed board and harness (note that yours will not have the green LED, that was for testing). The whip should have a 2 position connector with a single blue wire and a 4 position connector wth a red and black wire. They connect to the adapter's mating connectors.

The other end of the HE280 adapter attaches to either the Duet's E0 endstop 3 pin connector or to its 4 pin Z probe connector, depending on which version you built. This is all described in the instructions and header file on GitHub. Attach to the Duet WiFi.

If you are installing a PanelDue, connect it to the 4 position connector on Duet. 

That's it for the basic Duet WiFi installation and configuration. Now you an proceed with making sure everything works properly. First power up your printer. If you have PanelDue, you should see its display. If not, power down and figure out your connection issue before proceeding.

Connect to DuetWiFi from a web browser. Once connected, verify the bed and hot end thermistors are giving sensible readings. Then heat the bed to 50°C and the hotend to 100°C to test them. Once your bed and hotend are working, you can test the steppers. Click the home button and watch carefully. Have your cursor on the Emergency Stop button or finger on the power supply button in case of problems. Next, bring your hotend up to printing temperature and test the extruder.

If all of that works, you are ready to test the HE280 accelerometer adapter for probing. Home your printer and click the Auto Bed Compensation button. If all goes well, you will have a calibrated, ready to print Rostock MAX V3 with a Duet WiFi and RepRapFirmware! 

Wednesday, December 14, 2016

Proto-pasta Matte Fiber HTPLA

I have been on a quest for a nice matte black PLA to use to print parts for the fly fishing reel kits I manufacture and sell. When I saw Proto-pasta's Matte Fiber HTPLA, I knew I had finally found what I was looking for. I started with a roll of black but with the results I'm getting, I'll be buying all available colors!

Firstly, I found this HTPLA just as easy to print as normal PLA. I did have to increase my hot end temp about 5°C but otherwise, my standard 2mm SLOW 15mm/s retract, 4mm Z-lift and other slicing parameters were the same. I normally print parts on my delta printers but since getting the Prusa i3 MK2 last week, I'm putting it through its paces. So I loaded up my torture test model into KISSlicer and had at it. As you will see, this part requires PERFECTION for the first layer. The concentric rings are designed into the part, they are not something a slicer can do. The layer height, adhesion, string and blob control all have to be perfect in order to produce the high quality parts I put my name on. So, take a look at this:

This part is perfect. And it had 5 platter mates, I printed them 6-up on the i3 MK2 and all of them look like this one. One cool thing about the HTPLAs is they can be heat treated at 110°C for an hour or so. This significantly raises the heat deflection temperature (HDT) to 120-140°C - higher than standard PLA, ABS or PET. These parts are heading for the oven...

Monday, December 12, 2016

New Prusa i3 MK2 build

I've followed Josef Prusa's work for several years and even built a couple of earlier i3s with friends. Two recent developments caught my attention and I just felt compelled to check them out myself. The first development is a sensor and compensation system that actually corrects for skewed X-Y geometry on a Cartesian printer. The second is a new dual/quad multi material upgrade.

The i3 MK2 with the geometry correction is available now but the multi material upgrade is pre-order with shipping expected to start in January. I put in my order for the printer and quad upgrade about 4 weeks ago. The printer arrived, on time, last Thursday. I got busy putting the kit together on Friday.

Here's the traditional "open box" photo. The kit is very well packed and everything survived the trip from Czechoslovakia in tact. The printed Assembly Instructions and 3D Printer Handbook were an unexpected surprise and was an early indication of the focus on usability that Prusa puts into these kits.

The next pleasant surprise was that all of the tools needed for assembly were shipped with the printer - I thought I was the only kit manufacturer that did that with my fly fishing reel kits!

All of the parts were top notch from the 3D printed parts, to the authentic E3D V7 hotend and mini RAMBo control board. The Z axis steppers actually have the screws integrated as the stepper shaft - there is no coupler. This is an interesting idea and simplification that eliminates a potential point of problems.

The printer also comes with a PEI print surface (need I jump for enthusiastic joy about that?) along with a roll of quality PLA and a glue stick to treat the bed for printing other materials. The kit includes everything a beginner (or experienced) 3D printer needs to be successful. The only significant thing missing is a part removal spatula like the type SeeMeCNC include with their Rostock MAX kits.

Assembly was a pleasant 6 hours (including photographs along the way). The manual has an on-line version with lots of user comments and tips. I used a combination of both, finding the high resolution photos online to be very helpful.

Once the machine was assembled, it was time to commission it. Here's where Prusa's attention to usability really shines. The firmware is pre-installed and, more importantly, is customized to tightly integrate with the probing system and calibration. When you first turn on, the firmware recognizes a new printer and guides you through an integrated Self Test that checks stepper motion, hot end and bed heaters, fans and end stops. Very clever and very helpful. My printer completed the Self Test without issues.

Once the initial check completes, calibration is the next step. Again, this is simply a matter of selecting an option from the LCD panel. The printer runs through its paces scanning each of the nine probe points that are manufactured into the heat bed itself. Again, very clever and tightly integrated. Upon completion I was informed that I had slight skew but that would be removed by the compensation. So onward I pressed.

Calibrating the probe is probably the most difficult step and it is quite easy with the docs and videos Prusa provides. Once Z height is calibrated, it can be easily tweaked - even in the middle of a print - from a panel menu and using the knob to move the nozzle up and down. The included calibration gcode simply draws simple back and forth lines on the bed as you tweak the  height until the first layer looks good and sticks well. Very simple and it really makes this critical calibration simple for even beginners.

My first print was the Prusa name tag as recommended. It came out perfect with an excellent first layer and no stringing or blobbing (the gcode was provided). My second print was a case for a Raspberry Pi to run OctoPrint to control the i3 MK2. I used KISSlicer and again, the print came out really nice.
I've since printed nearly a Kg of several different PLAs including the matte fiber HTPLA from Proto-Pasta that I really like for my fly fishing reel kit parts. The material printed like a dream. It really made me aware of how trouble free direct extruders are over extruders using a Bowden tube like all of delta printers have.

Next I decided to try the new Prusa Edition of Slic3r. Apparently, Prusa has been working to improve, add features and reliability to Slic3r. Frankly, I've had so many bad experiences with Slic3r that I rarely use it. But Prusa's Edition is a different beast. This new version has a really interesting Cubic infill type that results in better 3D rigidity. It is very cool and I can see using this for some of my work. Another really nice feature is "Ensure wall thickness", which looks ahead and determines how much support and walls are needed UNDER upper layers in order to print nicely. The example Pumpkin Head print really shows the spectacular results.

(from Prusa's Web site)

Although I rarely use a slicer's support tools (I either design supports into the parts I design or I add them to others' designs in an STL editing tool) a lot of work has been done in this area.

Overall, I am quite pleased with the gcode and prints I'm getting with Slic3r Prusa Edition. I'll continue to use it for the i3 MK2. Prusa has committed to continuing development and rewriting the app in C++ for performance. It should be interesting to watch what comes out of this development.

The Prusa i3 MK2 kit is a great 3D printer for a very reasonable price. There really were no compromises in its design and components. As refined as the actual printer design is though, what really sets the i3 MK2 apart from every other printer - kit or pre-built - that I've seen/used/built is Prusa's holistic approach to ensure a great user experience from the time the box is opened to the the completion of the first print. Details like integrated Self Test and sophisticated calibration in the firmware to support this experience should pay dividends with happy users! I can hardly wait for the quad multi filament upgrade.

Saturday, December 10, 2016

File sharing with OctoPrint

In a previous post I addressed installing OctoPi (OctoPrint on a Raspberry Pi) for controlling the RAMBo on my SeeMeCNC Rostock MAX. OctoPrint has been working well and makes managing the printer and prints a lot easier via wireless. Along the way, I came across Samba - a suite of utilities for Linux & Unix systems that allows sharing their file systems with Windows and Mac computers with the SMB/CIFS protocol. Basically, with Samba, directories on the Raspberry Pi can be shared with desktop systems so you can slice a model and save the gcode directly into the Pi's gcode folder where it will automatically show up in the OctoPrint print list to be printed! Very convenient. Here's how to do it:

First install Samba on your RPi. Log into the RPi with SSH. Once there, we'll use the apt-get utility to install Samba. I found my apt-get needed to be updated before it could locate the samba resources. On the RPi command line, run:
sudo apt-get update

Then install samba with:
sudo apt-get install samba samba-common-bin

Once the install completes (both of the above steps may take a minute or more) you need to add the pi user to the SMB password list. Note, if you changed your username from the default pi, simply replace that in the following command:
sudo smbpasswd -a pi

You will be prompted to enter and verify a password. Choose something you'll remember.

Next you should enable write access on the upload folder:
sudo chmod 777 /home/pi/.octoprint/uploads

Finally, you need to edit the smb.conf configuration file to publish the uploads folder. 
cd /etc/samba

Then edit the file with:
sudo nano /etc/samba/smb.conf

Scroll down in the file until you find a line that starts with [printers], we'll insert the configuration for the folder above that. Copy and paste the following at that point:
comment = OctoPrint Uploads
path = /home/pi/.octoprint/uploads
writeable = Yes
only guest = Yes
create mask = 0777
directory mask = 0777
browseable = Yes
public = yes

and save the file (^-O to write followed by ^-X to exit). Finally, reboot the RPi:
sudo reboot now

Once the RPi has rebooted, you should be able to find it on your network. For OSX select the Finder's Go->Connect to Server... menu and click the Browse... button. Your RPi should show up in the Network-> section. Click on it and click the Connect button. You'll be asked for your username and password. Once you've connected, two folders should appear - pi and uploads.
Managing gcode files on OctoPrint is much easier and faster!