my blog

Automated Blinds Part 4: Wireless Control and Silent Stepper Drivers

Riding my high from implementing a basic homing routine and command interface, I dove right into wireless control. To my absolute delight, I actually found this to be way easier than I thought. I started off with a tutorial that showed some basics of setting up Wifi connection credentials, creating a local server, and assigning addresses for HTTP requests. With that down, wired an LED and got it to blink on the breadboard with just my phone - pretty neat!

From there it was pretty simple, just create two more “buttons”, assigned to different addresses on the server and attach those client requests to functions. The functions are broken out versions of the code I posted in Part 3 so one for homing, one for raising the blinds, and one for closing them. I also added one more check variable that blocks the open and close commands from running if a home hasn’t been done since the last reboot which will help avoid any crashing.

This all culminated to a pretty satisfying moment:

Now this was super cool - but I quickly realized this was way too loud. The motor makes a pretty high pitch sound on its own but the frame of the blinds is a hollow aluminum extrusion that makes the system HUM. Not a great look for something I may want to have moving while I sleep.

When I originally spec’d parts for this project, I anticipated this issue and ordered some TMC2208 drivers from Trinamic. Trinamic has a reputation for being on the cutting edge of driver tech, and I have some experience with their hardware from my role at Markforged. One of their huge features is StealthChop, which is a proprietary voltage-regulated chopper that eliminates noise caused by less synchronized motor coil chopping found in the A4988 driver. Another advantage it has is an interpolated 256 micro-stepping capability, compared to the A4988’s measly 16, which again helps in cutting down on vibration and noise. I had tried to implement these drivers in my original circuit but there is considerably information online about how to get these working compared to the A4988 which is used in just about every open source 3D printer. In the process of getting the A4988 drivers working I learned a lot of the nuances in getting this type of driver working which made going back to the TMC driver pretty straightforward at this point.

A4988 driver (top) and TMC2208 driver (bottom)

A4988 driver (top) and TMC2208 driver (bottom)

I had never actually heard and felt the difference in the drive signal quality between these drivers, but let me tell you, it is night and day. With the TMC chip working I did some side by side comparisons and the results were stark.

A4988 Driver

TMC2208 Driver

Even though it’s miles better and quieter, it’s still not silent so I decided to turn down the speed a bit to find my ideal speed / noise ratio. The videos above both run the motors at 4000steps/second which translates to an actuation time (fully opened / fully closed) of a little under 15 seconds. I’m definitely more interested in optimizing for noise level for this particular application so I incrementally ramped the speed down until I found the fastest speed where the motor noise was imperceptible over ambient noise, in this case 1250steps/second. This translates to a 45 second actuation time. I think that’s what I’m going to keep for the time being; I may try to tune that faster in the future but for now it does the trick. Video of this final implementation speed below:

If you really turn it up - you might be able to hear my roommate Pete freestyling downstairs - goes to show how quiet it really is!

I’m feeling pretty good about the state of the hardware and firmware at this point so I’ll be shifting focus to getting my HomeBridge server setup so I can start controlling this from my Home app! After that I’ll look to finalize the hardware design and cover it in a future post so stay tuned!