Working on a new project, combining making something fun with learning some new skills. In this instance the primary goal was to learn a little more about python, Visual Studio Code + Github, and object oriented programming (my first class!).
Sneak peek below, but this will be a RGB 48*48 matrix framed in a shadow-box on the wall. Initially it’ll run the game of life, but could be updated later to display anything. Early pics of the physical project below, and link to gitHub repository.
Not a super exciting project, but it did let me actually make something on the new CNC. My son has been playing with epoxy and learning to make things by watching youtube. We made a table for the basement a while ago, and it needed some coasters. Pretty basic profile/pocket of our lake, and he did the epoxy fill!
For the bed of the machine i just used a 1/2″ steel plate. I went with hot rolled as they didn’t have cold rolled available. This was an eehhhhhh sort of choice. Its not dimensionally flat across the work area, and I really don’t have the power available to mill it directly. For the interim i attached a 1/4″ aluminum sacrificial bed on top of the plate which i could mill flat.
This gets us to the end of the physical construction. Final touch was drawer fronts, with some wrenches i got from my dad when he retired his mechanics business.
This machine is based around a smoothstepper control board driving gecko stepper motor drivers. On the pc end of things gcode is processed by mach4. It’s an interesting relationship between these three companies as the lines of support are pretty gray. I had some issues during the build and its amazing how on the back-end their engineers all seem to know each other. In particular the smoothstepper guys were super helpful on some issues that wen’t pretty deep into mach4 territory.
I also just wanted to say that you’ll pay a bit more for the gecko drivers, but their support is top notch. I blew up a board due to ignorance, and they replaced it without even an admonishment!
I did as much of the wiring on a backer-board on my workbench as I could before mounting the panel in the back of the machine. The stepper drivers need a heatsink, and I had this one in my garage for 10+ years. Originally it was going to be for a home theater amplifier.
I 3d printed up a bracket for the smoothstepper, and even printed some cable management loops. On my last build 3d printers really weren’t a thing so maybe i went overboard, but this was pretty fun. Used a lot of ferrules which I learned about volunteering at the high school for First Robotics. Nice to cross pollinate skill sets!
We bring in 220 on the left, which goes through a big contactor, with only the 5v rail-mount power supply always being powered. The contactor is initiated through a the aircraft toggle mounted on the estop box. That basically turns whole machine on/off. The limit switches on the machine were 24v so i had to solder inline resistors so they would work with the 12v inputs on the smoothstepper.
Once the fixed back plate (3/4″ aluminum) and the movable front plate (1″ aluminum) were machined it was assembly time. Here you can see the parts laid out and ready to go. In the upper-right you’ll see two white brackets to mount the stepper motor and tension the belt. These were 3-d printed with the mindset that I’ll mill aluminum ones when the machine is up and running. I found out about the option to put brass screw inserts in the 3-d print too late, but it looks like an awesome procedure and is something I’d do in the future.
Assembly was pretty straight forward. I did have a little binding on the lead screw and had to shim it out a little bit using some folded aluminum foil. Shim stock isn’t something I have on hand!
And some additional photos of the assembly and mounting to the y-axis.
Once it was on the machine I could locate the z-axis homing switch. I used a fairly inexpensive magnetic sensor from amazon. I mounted the sensor in the back plate, and then drilled/tapped and threaded a hex-cap bolt in the movable front plate. This bolt triggers the magnetic sensor when the z-axis is in the full-up position.
Pro-Tip : Just buy a z-axis. It’s likely not worth the hassle, unless you don’t value your time. Or if this really and truly a hobby and you enjoy doing and redoing things.
That said I built a z-axis! I bought a bundle of parts off ebay and used that as a ground floor for measuring and designing. Having parts on hand provided a good starting point for scale and feasibility in Fusion 360.
From there it was quite a few iterations to draw up what would become the axis. During this process I learned a LOT about fusion, as I wanted all the movements to work so I could watch for clearance issues etc. Saunders Machine Works’ youTube channel was a huge help. The final drawing (looks like 42 edits) looked something like this.
Mounting the stepper that way was a little more work, but it keeps it from sticking out the top, and counter-balances the weight a little bit. Here is a zip file with the fusion model if you want to use it.
I started doing the manufacturing of the backplate the manual way. Lobbed off a piece of 3/4″ aluminum stock and started drilling, tapping, and cutting. Fusion allows you to print out 1:1 sized prints which worked super well. I just sprayed on contact adhesive and glued the template to the stock. It was a lot of holes, and a lot of tapping.
The studious observer may notice the two pockets where the bearing-blocks for the lead screw attach. Those I didn’t get done in my garage. At the high school they have a old cnc Haas mill that we have access to for working on the robotics team. They were kind enough to let me run the pocket operations I needed on that mill. Thank goodness! It would have been nice to mill the whole piece there, including the drill holes but I didn’t want to overstay my welcome.
How can we make this project harder and take longer? Oh yes, lets collect new skills in a very round-about path to the destination. In this case I wanted to learn how to TIG weld. I could haphazardly do MIG welding but wanted to learn TIG. This was primarily as aluminum is a key working material for the high school robotics team and being able to weld it would likely come in handy. With a welder in hand I knocked together a frame to hold the new CNC gantry as well as a few drawers.
One of the things that’s not super obvious is behind the drawers you’ll see a ‘divider’ that leaves about a foot of space in the back. That’s where the electronics will eventually go.
I have had this 2×4 cnc machine for 4 years now, and have outgrown it. Made of MDF with aluminum rails and skate bearings it won’t go down in history as a super sturdy machine. That said it served me well and together we made some awesome things. I have been volunteering at the high school robotics team, and having a machine that can mill aluminum with a reasonable amount of accuracy was my design goal.
Doing the slow troll on craiglist and facebook marketplace I came across this guy. Stout steel frame, and nice linear bearings. The z-axis on it was some sort of ink sprayer – not sure what exactly it’s previous life was but good bones for my build. Now I just needed a table, z-axis, electronics, mill.. the little things.
One thing that was interesting/concerning was this used belts instead of ball/lead screws to move the x/y axis. There is an included gearbox with a 2.5:1 ratio off the stepper motors, and my concern was if I could get and maintain the accuracy needed. Overall these rail systems were very well built, and even the belt-tightening mechanism was well done.
My dad spent a lifetime as an automotive mechanic, specializing in transmission repair. He recently retired and I spend a few days helping him clean out his shop as he sold the building. I took a few moments to take photos of his toolbox, as the years of wear and showcase of daily-driver tools was pretty cool.
I have been playing around with using ESP8266’s as endpoints around the house for collecting temperature, turning the sprinkler pump on, texting me when the doorbell is pressed, etc. One of the challenges when doing setup/testing is getting the IP address of them when they first come online.
I am running dnsmasq on a raspberry pi, which provides both local DNS and DHCP services. This is in no way novel, as it is a pretty vanilla configuration. What I wanted to share is a small script that monitors for updates to the dnsmasq log, watches for new client releases/renewals and then posts those to the MQTT service. There are lots of things you can do with it from there, but I usually just subscribe to the topic via terminal or mqtttool on my iPhone.
from pygtail import Pygtail
import paho.mqtt.client as mqtt
client = mqtt.Client()
for line in Pygtail("/var/log/dnsmasq.log"):
isItACK = re.search(r'DHCPACK',line) #see if its an ACK
newInput = re.sub(r'^.*DHCPACK\(eth0\).', "", line) #strip everything before mac address
newInput = newInput.rstrip() #strip newlines
client.connect("xxxxxx.widgetninja.net",1883) #connect to mqtt
client.publish("/network/DHCP",newInput) #publish to mqtt
client.disconnect #hang up
Hope this helps save you some time trying to find the ip address of that new device, be it something you made or otherwise just added to your network.