Solutionism… trying to solve everything by creating more problems 🙁 This story starts with me trying to once and for all solve my under voltage alerts on my raspberry pi. As you know from previous posts, my Pi is leeching power from my Ender’s PSU. However, it seems that the printer is also leeching power off the Pi via the USB cable. The Solution? Cut the power line in the USB cable of course! But this doesn’t come without consequence… An unknown foe emerges, one that only a select few face today. They call it… EMI.
EMI, also known as Electro-Magnetic Interference, the reason your Wi-Fi craps out when your microwave turns on. Well, not anymore with new Wi-Fi tech (thank god!) but just because we don’t face the problem on a daily basis doesn’t mean its not there! Lets talk more about the situation.
Ok so basically we have a USB cable with normal EMI shielding, protecting 4 wires inside the main cable. Red (power), White/Green (data) and Black (ground). Cutting open the main cable, and then cutting just the red wire, my cable should now only transmit GCODE data and not 5V power with it. In my infinite wisdom, re-applying the shielding was sort of an after thought. So proving that my under voltage error was gone and the printer seemed to be working normally, I started a print job and went to bed.
The Next Day…
The following morning, I checked on the print aaaaand… it was half done. My printer stopped about 30% through the job and Octoprint showed that it received too many GCODE errors in a row. Maybe the slicer screwed up? I did just update Cura. Attempting the print again, keeping better tabs on it, about 2 hours in I got the same error. This time, I dove into the Octoprint error logs to see what these repeating errors were it was crying about. Finding the line where it marked an error, the GCode it was sending was, gibberish. The next line, it tries again with a correct command. Dozens of lines later, again, it sent gibberish. Octoprint has some logic built in where 3 strikes and the job quits.
G1 X47.398 Y140.25 E3817.88201
G1 X47.545 Y139.855 E3817.89603
G1 F1511.3 X<:h{n#x4wIoshUqq139.731 E3817.90261
G1 F1608.6 X47.948 Y139.675 E3817.91046
G1 F1709.4 X114.223 Y139.675 E3819.84475
G1 F1587.3 X47.898 Y115.18 E3826.94527
G1 F1699.7 X60.748 Y115.175 E3827.32244
G1>>x-y[BGf*O0=xe3Y115.493 E3827.34204
G1 F1500 X61.348 Y115.75 E3827.3508
G1 X61.348 Y121.081 E3827.52811
G1 X61.278 Y121.283 E3827.53522
G1 X46.199 Y114.451 E3855.24456
G1 X46.199 Y157.299 E3856.66969
G1 X188.8 Y157.3 E3861.41262
G1 X188.8 Y77.7 E3864.06013
G1 X187.198 Y77.7 E3864.11341
G1 X187.195 YFH3o2{t_`a<*B08S
G1 X187.139 Y155.639 E3866.70613
G1 X187.032 Y155.695 E3866.71015
G1 X181.918 Y155.697 E3866.88024
That’s when it hit me. Exposed wires, random characters injected into the GCODE, half baked print jobs. It had to be EMI. I grabbed a spare USB cable and swapped things out, cringing at the fresh under voltage error. I started a fresh print job again, 2 hours later good, 3 hours still working, and completed at 4 hours! Well shit… who knew that a USB cable with exposed wires would have to deal with EMI 😉 It was time to do something drastic.
Fighting EMI with Less EMI
I’m talking about doing the job right, re-cutting the cable and using PROPER shielding this time. So, this time I cut the cable all the way through. Reason being, I needed to slide some heat shrink over the incision point. Then, cutting the red one short so it stays out of the way, I stripped the data and ground wires and used solder terminals to bind the wires together again. Mind the bulge 😉
I actually invested in a heat gun finally to do a proper melting job. Much better than using a lighter and risking a good printer fire. Finally, sliding the heat shrink over the terminals and applying the heat gun, I now had a fully shielded USB cable. Well, you can’t know that for sure until you test it! Plugging everything back in, I fired off the same print job and went to bed. The following morning, I had a full print! I ran the job one more time to be sure. Same results, job completed!
Whew, Out of the EMI woods! Sort of…
Yep, feels good conquering solutionism. I got to have my cake and eat it too! Under voltage error is gone and I no longer suffer from EMI. But of course, just when you think its over, solutionism rears its ugly head. Like an annoying room mate that pops in when you just thought you had the whole house to yourself for the afternoon! My problem now morphed to my relay. When I power on my printer, there is an 80% the whole system draws too much power for a split second, causing the Pi to crash.
My hunch is that by cutting the red USB wire, I caused an imbalance in the circuit. Knowing how cheap these printers are made, there is a good chance with my ground wire still hooked up, some electrical shenanigans is a foot. But, I’m going to have to save that story for the next post.
Thanks for tuning in! Stay curious and keep printing. Until next time!