Mostly about my amusement

Category: Cool (page 1 of 11)

Oh, I do have a WordPress Blog.

It’s been ages since I last posted on my blog and I had been wanting to start again. What to talk about?

The Great Twitter to Mastodon Migration of 2022!

It’s not exactly a migration, it’s more like a mass exodus.

For anyone who’s not aware, Elon Musk completed his purchase of Twitter on October 27th, 2022. This was met by a lot of concerns from Twitter users. He likes to proclaim that he’s a “free speech absolutist” and if you think that means hate speech, anti-wokeness and anti-cancel culture then you are not wrong.

Note: “Wokeness” and “cancel culture” is not a thing. it never has been. Consequences, however are real.

In his first week he posted a nonsense conspiracy reply back to Hillary Clinton and subsequently deleted it. That was not bad but instead of apologizing for spreading that nonsense, he just kept mum. I’m glad he deleted it but, really how dumb do you have to be to go that way?

Then there was the matter of paying a monthly fee to get a “Blue Checkmark™”.

Putting aside the tone deaf “lords & peasants” nonsense, the idea is you pay and you get a blue checkmark seal of approval and other benefits.

It’s an awful idea. First, the existing blue checkmark was to let people know they were reading tweets from a verified person.

Do you follow Jeri Ryan? I do; she’s very cool.

The check mark is to let you know, that’s not a scammer pretending to be Jeri Ryan. Here’s her reply about the $8/month idea.

Verification has always been dodgy on Twitter. The rules changed, sometimes Twitter verified people and sometimes they did not.

The Blue Checkmark is not about spam or bots. It never has been. It’s about validating who that celebrity is.

Anyone who has had to deal with trolls and abusers know this is a bad idea. A scammer or phisher who pays for bulletproof hosting is not going to have a problem with $8/month if it helps them make their target dollars per month.

No one Begrudges Twitter Being Profitable

Twitter is (now) a private company. I don’t know if it has ever been profitable but Musk bought it for $44 billion and that was financed. Making money is a valid goal. This blue checkmark idea is just bad and no one should sign up for that.

Any website owner knows, advertising is king. No one likes ads. No one likes that a website shows me ad for that electronics I was browsing on Amazon. It is creepy. But it is an accepted way to make money on the Internet.

Elon Musk’s way of handling advertisers is typical Elon Musk.

That’s just a nonsense reply. Anyone who thinks it’s a “free speech in America” issue is not from this planet.

Just look at Ye’s troubles. Kanye West has lost major endorsements because he spews unapologetic anti-Semitic hate speech. Why would any brand want to be associated with that?

That’s always been the concern with Twitter being taken over my Elon Musk. Twitter has always been a hellscape when it comes to abuse. Sometimes they nailed it, other times they would routinely punish the wrong person and give the abuser a pass. With his treatment of hate speech/misinformation being “free speech” (it’s not) who wants to posting ads on that platform?

Mastodon is Federated and That’s a Good Thing

My first day really using Mastodon went like this.

  • I posted some toots. They’re called “toots”.
  • Someone replied at me “You smell Jewish” and their profile made it clear they were into “free speech”.
  • I reported them, added a couple of their posts that used the N-word to the report and blocked them.

It’s the Internet and I expected abusers. With a federated model I was not sure my report would mean anything. I was wrong!

Somewhere an admin got that report. They looked at it and I am sure they said “Oh. Yeah. That’s bad.” and banned the user.

There was no “We received your report”, there was no “That user does not violate the TOS”, they just dealt with it. Cool.

I’ll maintain both my Twitter account and my Mastodon account for now. It’s not a big deal, I do that today with Facebook and Twitter. I can be found at this URL.

https://mastodon.xyz/@jan_dembowski

Mastodon

I’ll see how it goes. Mastodon is currently a little slow and sometimes times out on me. That’s OK! That means people are joining it and that’s a good problem to have.

New Life for old 3D Printers

I’ve used and abused my first 3D printer for about 2 years. It had print quality problems and my recourse was to buy a new cool delta printer. But is there any way I can refresh that 3D printer I just about gave up on? I decided that an updated firmware may be something I wanted to try out.

Safety is an Optional Feature?

I don’t really know if temperature safety protection was available when my printer was originally made but it is now. Some manufacturers still turn that off and that’s insane. What that feature does is have the controller see how long it takes to reach a set temperature. If it takes too long, if the temperature results don’t make sense then the firmware powers off the heating elements and locks up the printer.

Shutting down your printer is a more attractive outcome than burning your house down. This is one reason why you want to buy safe equipment from reputable manufacturers. And even then, some of those manufacturers disable that safety check.

I ran into an issue like this with my 3D printer about 2 years ago. Too much power was going through a cheap connector for the hot end nozzle and the connector on the control board melted. The whole basement filled up with the smell of burnt plastic and I thought the inside of the controller box was on fire. It wasn’t quite that bad but close.

I don’t know if thermal protection would have stopped that melted connector but I do know that after a period of time the printer would safety off when the temperature didn’t make it in the window of time.

The manufacturer sent me a Melzi 3.5 replacement board and I swapped it out. I also added hardware to make the printer safer.

  1. One MOSFET to the rescue. I added it between the printer’s hot end and control board that drew power directly from the power supply. That meant the control board didn’t feed a lot of amperage, it just signaled the MOSFET to draw power separately and send it to the hot end.
  2. The 3D printer’s firmware lacked basic thermal protection that more current models have or should have in 2019.
  3. Leveling the printer bed was ruining my liver. 3D printing relies on getting a good first layer. Everything is literally built upon that. The way you level the bed involves turning the screws on each corner. Sometimes it works but often (for me) it didn’t. I could get part of it to work OK but then “RRAARRR!! WHY WON’T YOU WORK ON THAT PART OF THE BED!!?!”


I really wanted to try an updated firmware so I followed this video very carefully. It’s the exact same process as burning a bootloader onto an Ender 3 but this video matched my hardware. I bought an Arduino UNO R3 from Microcenter and went to work.

This process will put a bootloader on the controller. It will also brick your printer as you are wiping out the existing firmware. For me that was fine as I gave up on the printer and this was just the first step. I skipped the part about burning the Repetier firmware as I wanted straight to Marlin.

I found a pre-made version in this Google Group. It was Marlin 1.1.8 and it just worked. I took the author’s Configuration.h and Configuration_adv.h files and manually edited Marlin 1.1.9 (I wanted to see what I was doing) and now I am running that version.

I also replaced the 3D printer bed surface. It’s a sticker with Buildtak like surface. My old one as looking like the surface of the moon and was frequently failing. This is a re-usable part and is like getting new tires for your car.

Manual Mesh Levelling

This is how I previously leveled my printer’s bed.

  1. Remove the filament from the hot end and clean the nozzle with a metal brush while hot.
  2. Move the printer head to home. That’s the front left corner.
  3. Adjust the front left corner by turning the screw. This moved the corner up or down.
  4. Using a piece of paper, move the bed till there was just a little pressure on the paper. I wanted the paper to move without bunching up but get a little drag.
  5. Move the hot end to the next corner and repeat.

This works sorta, except that moving another corner also moved the level on the other corners so I had to revisit each corner multiple times to make it work. For added benefit, my bed was slightly warped. What was level at the corners wasn’t level at the middle.

I would get around that by using a raft on my prints but I’d prefer to just print reliably on the print surface directly.

Here’s how I do this now. This is using a current feature of the Marlin firmware.

  1. Heat up and clean the hot end nozzle and remove any filament. It’s metal and the wire brush works.
  2. Adjust the 4 corners to close to the homed nozzle and visually level. I just get it close to the nozzle. I don’t worry about how close, it’s within a millimeter or two and that’s fine. I think the firmware has 4 mm of play but I’ve not confirmed that.
  3. Heat the bed and the nozzle. I use PLA so that’s 60C and 205C.
  4. Select level bed on the LCD panel. This homes the nozzle and asks me to to click when ready. It will probe the height of 16 points (4 x 4). I set this in the firmware’s Configuration.h file.
  5. I click and it moves the hot end to the first point. Using the LCD knob, I raise or lower the nozzle (not the bed corners) till it’s just dragging on the paper underneath. When it’s just right I click to let it know.
  6. I repeat this for the next 15 points on the print bed.
  7. Save the settings when done.

This is what the mesh points look like.

Send: G29 S0
 Recv: State: Off
 Recv: Num X,Y: 4,4
 Recv: Z offset: 0.00000
 Recv: Measured points:
 Recv:         0        1        2        3
 Recv:  0 -1.07500 -1.02500 -1.02500 -1.07500
 Recv:  1 -0.80000 -0.75000 -0.75000 -0.82500
 Recv:  2 -0.55000 -0.52500 -0.55000 -0.62500
 Recv:  3 -0.40000 -0.42500 -0.50000 -0.60000
 Recv: 

The bed goes from a -0.4 mm to -1.075 mm adjustment. See the second line? The edges are slightly higher than the middle. It’s imperceptible to a person but for a machine that’s laying down a layer of filament 0.25 mm thick it counts.

To enabled this feature, right after my print’s G28 code, I need to add “M420 S1” and that tells the printer to use the mesh I manually probed. I updated my slicer’s profile and started a test print and waited.

Great Shark Monkeys. That worked.

Test print on the 3D printer bed

I haven’t been able to get a good first layer like that in ages. I would get one side leveled but between the too low or high on the other side. And the low sections in the middle was awful. Now the printer gets the geometry from the mesh level I set and poof! A good first level is accomplished on the whole bed. Sweet.

I did the firmware upgrade mostly as a “Why not?” and to see if I could get those safety features baked in. The manual mesh leveling is an added bonus and I now have a fully functional 3D printer which I had written off months ago.

Octoprint and Reverse Proxies

I have two active 3D printers, each hooked up to their own Raspberry Pi 3 running Octoprint. I like to manage them from my iPhone when I’m about. I don’t want to expose my IoT devices to the Internet without some precautions.

Here’s how my Internet connected house is setup.

Simple network diagram

The diagram was created and edited in https://www.draw.io/ Free online tools FTW.

My FIOS router on the left listens on port 80 and 443 and forwards that traffic to my Ubuntu Linux Server. On that server I run Apache2 with mod_proxy enabled. 

I run ddclient to update a DNS name with my floating IP address. I use virtual hosts on the Ubuntu Linux Server to receive all external http/https requests. All http requests on port 80 get 301’ed to https on the same host. 

First setup https on the virtual host as you normally do. Before trying to reverse proxy, have a default index.html file and make sure that works. I use Let’s Encrypt for the TLS certificate as it’s free and easy to setup.

Here’s reverse proxy configrution. 10.1.1.17 is the internal IP address of my first Octopi. Make sure the DNS name is working first before trying to test anything.

ProxyPreserveHost On
ProxyPass "/"  "http://10.1.1.17/"
ProxyPassReverse "/"  "http://10.1.1.17/"

ServerName pi1.valid-dns-name.com

ServerAdmin webmaster@localhost
DocumentRoot /var/www/vhosts/pi1.valid-dns-name.com

<Directory /var/www/vhosts/pi1.valid-dns-name.com>
        # Options Indexes FollowSymLinks MultiViews
        Header always set Strict-Transport-Security "max-age=31536000; includeSubDomains"
        Options -Indexes
        AllowOverride All
        Order allow,deny
        allow from all
</Directory>
<Location />
        AuthType Basic
        AuthName "Wrapper Auth"
        AuthBasicProvider file
        AuthUserFile "/var/www/external.htpasswd"
        Require valid-user
</Location>

That <Location /> section on the bottom? That’s important. That’s the section that says “You need a password to access this URL” and protects the Octopi setup from passerby’s on the Internet.

What I tell you three times is true.

  1. Do not expose any IoT devices on the Internet without encryption and passwords.
  2. Do not expose any IoT devices on the Internet without encryption and passwords.
  3. Do not expose any IoT devices on the Internet without encryption and passwords.

It’s just a bad idea. The wonderful Gina Häußge who writes and drives the Octoprint software knows this and has an excellent guest post on her blog about that access. This post is how I accomplished the Reverse Proxy method.

The password is created using the htpasswd command.

$ sudo su - www-data -s /bin/bash -c "htpasswd -c /var/www/external.htpasswd bob"
New password:
Re-type new password:
Adding password for user bob
$

I sudo as the www-data user so that the ownership of that file will be set as I want it. This creates a file with bob and his hashed password in it. The AuthUserFile directive will use that. If you have a valid user ID and password, you get in. If not you don’t get access.

The configuration gets copied for a new Pi. Just change the IP and ServerName and you can re-use this for other Octopi installations. By having an encrypted password protected access to your Octoprint setups, you can monitor and control your 3D printers from anywhere you have Internet access.

New Kossel 3D printer

I’ve had my Monoprice Duplicator v2 for almost 2 years and it developed some problems.

  • The firmware lacked safety features I wanted. I could have (maybe) updated the code but I’m not sure how many features would fit. The board on it is an old Melzi clone and I would need to buy another board just to update that one.
  • The printer needed love and attention. I started getting layer shifts, the bed surface began to look like the surface of the Moon and prints started suffering from layer shift.
  • really like 3D printers that auto-level (tramming) in some fashion. That’s my favorite feature on the Prusa Mk2s and it generally just works. Leveling this printer’s bed was a real challenge. 

When I started looking the Ender 3 was the low end printer to get. It looks modifiable and a friend of mine likes his. He also purchased a Kossel delta printer and I was hooked.

Mini-Kossel vs Cartesian

Most 3D printers have a rectangular or square bed that moves forward and back for the Y-axis. The hot-end (the part that extrudes melted filament) moves left right on a rail for the X-axis and that whole rail moves up and down for the Z-axis. 

What makes this printer different is that the bed does not move. The bed has a 240 mm diameter and is round surround by three columns. Movement is controlled by sliders on those columns moving up and down together. It’s very cool to see.

Since the bed does not move that makes what is being printed in place very stable. The head can move and I print infill at 100 mm/s. The perimeters of my 3D print are set at 50 mm/s but I can safely increase that to 80 mm/s without any worries and that’s fast.

ANYCUBIC Linear Plus Kossel

I don’t think the manufacturer produces this printer anymore. The support section is still there but it’s no longer listed as product. That’s cool; it cost me $218.40 with free shipping from Aliexpress.

The build took me about 90 minutes. The kit is already half-assembled and very straight forward. The end stops screws made me want to punch a kitten as the screws would not set all the way in. I will probably print new ones out of ABS and re-do them. Also not all of the screws or t-nuts were of the best quality and stripped easily. For what I paid I am not complaining.

I did a test leveling as detailed in Anycubic’s manual and looked for a kitten to punch. The process is just awful and resulted in a bad first layer.

Marlin 1.1.9 to the Rescue

I’m a big fan of opensource software and the process for leveling this printer with Marlin is detailed in this Youtube video. It was that video that convinced me to get this printer. Da Hai knows what he’s doing and has his configuration files available to download. My version is the larger size and I started to modify Marlin to adjust for my bigger version.

I promptly fell on my face too; I do not know what I’m doing in Marlin. Some searching and I found this excellent blog post which is a review of the same printer and how the author was able to upgrade to that version of firmware.

I tested, made a couple of minor changes such as the printer display name and adjust how auto-home works and poof! I updated the firmware.

Everything worked. I used the process from Da Hai’s video to measure the surface and printed away. It just worked. I’ve added Anycubic’s Ultrabase, re-leveled the print bed and just went.

There are some test prints that you do to make sure everything is working. I printed 3D Benchys, I printed a 6 gear bearing (it prints in place) and they printed fine. The measured bed leveling produced a perfect first layer.

Then I changed the PLA to some from Inland (I had been using the roll that shipped with the printer) and printed this print in place iris box. I have never been able to successfully print this one before no matter how I tuned my printers. You make some small cuts on the base and rotate the bottom from the top. I didn’t have much success in the past but the pieces always were locked together and would not move. The results were great. I had no problem with this one at all.

Printed in place iris box

There are some artifacts in the print but it works. The printer is very precise.

Not for a First 3D Printer

This is my 3rd filament 3D printer. I’m comfortable with compiling the firmware, with the assembly, etc. but I do not recommend someone buying a Kossel printer unless they know what they’re doing.

The manufacturer’s documentation was very good. The printer was easy to assemble. Without the new firmware, without the very helpful posts and videos, I may have had a much harder time at it.

Since I do have some experience I’m having a good time playing with this latest toy.

Prusa MMU for the MK2s

I think I can call the multi-material upgrade of my Prusa Original i3 Mk2s a success. It took me about a day to put together and another day of tuning but I like the results and the prints look good.

Here's what you get with the upgrade kit.

  • A new E3D v6 with multi-material heat break
  • An additional daughter board to drive the extruder motors
  • All of the new plastic parts in ABS
  • Bondtech gears for the extruders
  • Bowden tubes
  • Spool holders for 4 rolls
  • All the fasteners needed

The instructions on Prusa's site are very good. I setup my laptop on the kitchen table, put the printer next to it and got to work. I took my time and spent 7 hours last Saturday just assembling it. A few quick tests and all was right in the world.

The Bowden tube setup is different and I need to get used to it. I had a clog on extruder 2 and had to  unscrew the Bowden tube from the print nozzle to clear it out.

I did have to butcher my Lack table enclosure. I run my printer in the basement and that gets cold. Enclosing the printer guarantees that I'll get better prints.

Less S3D, more Slic3r PE

The one thing I am not thrilled with is the software. I use Simplify3D a lot because I generally get better results. S3D's supports are magical and just pop off. In the past I would use Slic3r PE only when I needed to.

S3D does not yet support the Prusa MMU. There is a single color profile that I found on the Internet and that works well. But for multi-color prints it's Slic3r PE or nothing. This isn't too bad for me because once the bed is level and the z height is adjusted (-0.867 mm on mine, I set the PINDA probe a little higher) I get good first layers.

The default printer profiles generally work. The only adjustment I make is to set the first layer speed to 20 mm/s. After that it's full speed ahead.

The Purge Block

If you look at the image with this post, you'll see that each multi-material print has a block next to it. When the printer changes filament the head moves to the block and prints a 60 mm by 10 mm layer. By the end of that the nozzle is primed and the color can be applied.

That layer of block either gets completely filled in or if there's not filament change a small infill is applied for the next layer. Here's a closer look at the 2 color Moai.

That print has 2 filaments on every layer. That purge block is solid at 60 mm x 10 mm x 60 mm. I don't really think that's wasteful as it keeps the results clean. I may play with those settings to reduce the size.

Here's the fun thing: if I printed 1 or I printed 10 on the same job then the purge block is still the same size. It has to be the same height as the print itself because the print nozzle cannot descend. That would risk hitting something else on the print bed. Next time I'll print more than one and lay it on it's back. That should reduce the purge block and get more use out of the filaments.

Where to Get Objects to Print?

You can make them yourself but Thingiverse is loaded with many good models. There's more than a few that my kids already want me to print. It will be a while before I really make my own.

In the meanwhile I have a printer that can do up to 4 different materials in one go. That's cool and I'm having fun with this hobby.

3D Printed WordPress Bow Ties

Sometimes my hobbies cross over into each other. This year I attended WordCamp US in Nashville and had an idea. Why not download and make a bow tie with a WordPress logo on it?

First I went to Thingiverse and I quickly found this one. I already had the WordPress logo from converting the SVG with Fusion 360 and I began to work on combining the two files.

About an hour later I swore profusely. I had a lot of problems. My PC was a little under powered. Fusion 360 can do amazing things and you can design a V8 engine with it including all the parts. My limited Fusion 360 skills were failing me.

All I wanted to do was take the logo, position it on the tie and export the results to a new STL file for printing. But I'm not really good at manipulating imported objects that way in a tool like that.

Tinkercad to the Rescue!

Autodesk makes Fusion 360 but they also have a 3D editor that lives on the web and runs in your browser called Tinkercad. I imported the two files, positioned the logo where I wanted it and exported it for printing.

It took me all of 5 minutes. The first pass had the logo a little too thin and it broke too easily. It was also upside down; I thought the clip on bow tie would work that way. Sometimes I make poor choices.

Different Colors

Just as before with my WordPress coin, I wanted the bow tie to be one color and the logo to be another. My working printer does this like so:

  • Print using one color filament till the 59th layer. I used a tool to figure that out.
  • Move the nozzle to the corner and the print away from the nozzle. The nozzle is 200° C and that will melt any plastic it is near.
  • Beep loudly. This is an important step as the 3D printer is in the basement.
  • I remove the old filament and insert the new color.
  • Log into Octopi via my iPhone's browser and tell the printer to resume.

That's it. The bow tie came out well and I printed a few more. Did I mention that I sometimes go overboard? I printed 9.

Opensource All of The Things

The bow tie I downloaded is licensed via Creative Commons – Attribution and Thingiverse provides an easy to print attribution card HTML. Which I could not incorporate into this post except as a graphic and a link.

The 3D printer community is mostly opensource and these were printed on a Prusa i3 clone. I used Simplify 3D to slice the file into gcode but there are some really good opensource slicers such as Cura and Slic3r. I've had some bad luck with Slic3r but I think I sorted that out now.

If you want to play with this modified bow tie then you can download it via Thingiverse. Or create an account in Tinkercad and play with it there. It's an easy thing to do and is lots of fun.

A 3D Printed Dial

I had a broken dial. I also have a 3D printer, so rather than epoxy the heck out of the old one, I designed and printed a replacement. One finished 3D printed part was produced with just a few hours of work.

My pool has a salt cell that uses electrolysis to convert salt in the water into chlorine. You manually set the level from 10% to 100% generation but I usually leave it alone at it’s maximum setting.

That dial literally has one job and it broke. It was flush with the panel so rotating it meant scrolling the right exposed side. Built out of cheap injected plastic though it did last for 7 years.

In Fusion 360 I started with a stub to make sure I sized the knob holder correctly and ended up with a knurled dial that protrudes from the machine. My process isn’t very good and I learn through “what’s that feature do?” For example, the knurling was put on my making a sketch, extruding and cutting it out of the dial then creating a circular pattern out of that 120 times.

The effect came out great. My first pass has knurling that was too shallow (0.5 mm). Until I printed it out I couldn’t see that I had made a mistake. Once I saw it I went in the designs time line, deleted the sketch (which also deleted the pattern) and re-did it again. The new knurling rocks.

The last iteration was missing something. I put on the face a cutout to show that turning it clockwise means more, counter clockwise means less. The original dial had that printed on the face but my cutout is more prominent. It also meant I got to try something cool on my design.

I started with PLA but when I got what I wanted I printed it in ABS plastic. Here’s a photo of the iterations.

Yes, I could have fixed the old dial with some epoxy. That would have molded the broken part nicely. But it’s not often I get to use one of my toys in a real world way like this. 2 days of on/off fiddling got me the part I really wanted.

I think she gets it from her Mom

My daughter and a lot of her friends have begun to follow different K-pop bands. Putting aside that none of them understand Korean, they like the visuals and the beat of the music. And some of it is sung in English.

My daughter is crafty and I don’t just mean her attitude. Today she’s attending a birthday party and her friend is a big fan too. She took a small binder and using a word processor on the iMac made a 50+ sheet printed on both sides compendium of the bands they follow. Complete with the current band member bios.

BUT WAIT! THERE’S MORE!

She made stickers with the color laser printer and set them on the pages using Velcro. That way they can be re-positioned in different sections. The holes on each page and insert were done with a single hole punch.

She made folder inserts from stiff color paper and put printed material on and in them. She solicited her other friends to email her content and dolled that up too, formatting it so it printed and inserted correctly with the rest. She made a K-pop quiz complete with the answers in the back.

To make sure it’s a “living” book, she put all the document files and images on a USB drive that she’s included with the binder. That way the new owner can add or change the content as she sees fit.

I don’t know what to say. She draws and does crafts better than anyone I know.

Here’s a gallery of the book before it was given. I’m gobsmacked about all the attention to detail for this. She pulled all the images from online fan sites and formatted all the data.

I can’t wait to see what she does next.

3D Printing the WordPress logo in two colors

My 3D printer only supports having one filament loaded at a time and that generally means the objects I print is one color. I wanted the WordPress logo (naturally) and two colors would be cool. I can print pieces in different plastics and assemble them but sometimes you want one piece. Good news! My printer’s open source firmware supports changing filaments before the print job is done. That let’s me start the base in one color but switch to another before the print is completed. Here’s how I did it.

I downloaded the WordPress logo to my PC via Wikimedia in SVG format. SVG is a vector format for images that can be scaled without losing sharpness. I loaded that into Fusion 360 and deleted the text to the right and just kept the round logo.

In Fusion 360 I scaled the logo to 50 mm diameter. I then extruded the white portions in the logo to 3 mm. The circle outline and the space between the parts of the “W” were extruded to 1.5 mm. I exported that to an STL file and loaded it into Simplify 3D. This is where it gets clunky.

For slicing 3D prints into a format the printer can understand I use software named Simplify 3D. It’s not opensource (or cheap) but it’s very extendable and saves me a lot of time.

Simplify 3D supports scripts that use regular expressions to locate text in the generated G-Code output file and make substitutions. In the generated code it also comments each layer of the print so there’s a “layer 8” text where I want to insert printer commands to swap filaments.

Figuring that I needed to modify layer 8 was a pain. There’s probably a well documented way to do it but I sent my G-Code output file to Octopi. I loaded the file but did not actually print it yet.

OctoPi comes with a built in G-Code viewer. I moved the slider up until I found that layer 8 was where I wanted the change filament commands inserted.

I then deleted that file from the OctoPi, went back to Simplify 3D and in the process settings I went to Scripts -> Starting Script and added this to the “Additional terminal commands for post processing” field.

{REPLACE "\n; layer 8, Z = " "; layer 8\nG28 Y0 X0\nM300 S0 P1000\nM25\nG92 E0\nG28 Y0 X0\n; layer 8 "}

And generated and updated G-Code file with additional commands that I sent to Octopi. I loaded up a spool of blue filament and began printing. Midway through the print the extruder moved to the home position (but did not change it’s height) and waited for me to change the filament. Once I did that I loaded Octopi’s web page on my phone, logged in and clicked “Resume”.

The resulting prints came out well and I repeated the process with the white filament first. The bottom is one color and the top is another at just the right place.

This hardly took me anytime at all. It’s not a fauxgo, it’s a legitimate SVG (well, I hope it is) representation of the WordPress logo. The blue is a bit off but I can be forgiven for that. The PLA material is listed as “Egyptian Blue” and it’s the closest I had on hand.

There’s probably an easier way to get the layer accurately without using Octopi but it works. If I find an easier way then I’ll update this post.

What I really want to do is print the badges for the WordPress teams such as Support, Docs, training, etc. That’d be cool and I may do that this weekend.

This all came about because my brother got his 3D printer working in two colors on the same layer. His printer has two extruders and can print one color next to the other on the same layer. My printer does not do that but I’ll catch up. Competition is good. 😉

Pi Zero W makes for a compact Retropie box

Of course I did this with a Pi Zero W. 😉

One of the reasons I like the Raspberry Pi is that it lets you take hardware and turn it into a dedicated purpose based appliance. Cheaply! And one of those uses is to make a retro game system. I've used the Raspberry Pi Zero before but I was hampered by the fact that it lacks network and Bluetooth access. To get that you need to purchase a USB hub, wifi dongle and if you want it an Bluetooth fob.

The new Pi Zero W addresses that and adds both wifi and Bluetooth on the small package. Once it's setup all you need is an HDMI cable and power. That's it.

Here's how I did it with an 8Bitdo Bluetooth SNES style controller.

  1. Download Retropie for the Zero onto another Pi Zero (non-wireless one, I have a few). I could not get the image to boot on the new device so I setup a hub with a wifi dongle and keyboard on an old version.
  2. After the image reboots to resize the file system then F4 to get out of Emulationstation and on the command line run this command.
 sudo apt-get update ; sudo apt-get -y upgrade ; sudo apt-get -y dist-upgrade ; sudo apt-get -y autoremove 

That will take a while to run and you will need to read part of the upgrade and press Q at a point. That annoys me as those commands should run unattended. Meh.

The purpose of this is to get the underlying Raspbian OS up-to-date.

  • When you’re done run sudo shutdown -h now and swap the old Pi Zero for the Pi Zero W. Unplug the wifi dongle, you don’t need it anymore. Boot up the Pi Zero W with the keyboard attached via the USB adapter.
  • Once it boots up press F4 to get back to the CLI and run these commands.
  •  cd RetroPie-Setup sudo ./retropie_setup.sh 

    And select "U Update all installed packages" with your arrow keys. I don't know if that step is necessary but I do it out of habit. I like making sure I have the latest updates. That will take a long while too and reboot when it's finally done.

  • Update your new 8Bitdo controller to the latest firmware. On my Windows PC I updated my SFC30 to firmware 2.71.
  • Boot your Pi Zero W and press F4 exit Emulationstation and manually run the retropie-setup script again. Follow these instructions to connect your 8Bitdo controller and don’t forget to do the UDEV part. Reboot as needed.
  • Transfer ROMs via the wifi to your new device. I find that NES, SNES and Genesis games work well. MAME is a bit of dicey but older games played satisfactorily.
  • Connect to HDMI TV and have lots of fun.
  • The final parts list came out to this.

    Pi Zero W $10
    8Bitdo SFC30 Bluetooth controller $30
    Pi Zero Case I used one I 3D printed
    Mini-HDMI cable adapter $20
    2A micro USB power adapter $8

    I already had the cables and power supply but I'm trying to be complete. Not counting the case it's ~$70 for this one player setup.

    It's not a Raspberry Pi 3

    The overall experience is good and if you limit your retrogames to the older 8bit systems then you'll like it. But the Pi Zero W doesn't have all the CPUs and RAM of the bigger Raspberry Pi 3. The good Neogeo games won't play well. Sometimes sound suffers due to CPU use. Lag is a thing.

    But if you have the technical know how this beats the Nintendo Classic by a mile.