Post Two - Main Control Board Pt. 2

PCBs were provided at no charge to LRJ by PCBWay in exchange for an honest review. All sponsored content is clearly marked.

Nearly two months later, and we finally have the second post ready. I swear I’ll try and get better at sticking to deadlines…

I’ll warn you though, this’ll be one long read. If you can’t tell by the lack of progress updates since late November, the control board has been nothing short of an absolute nightmare to get working, a saga involving exploding parts, endless frustration, and so, so many broken components.

Let’s get right back to where I left off last time. We had a completed schematic, so it was time to lay out a PCB and order some parts. We decided on a bog-standard rectangular form factor, with screw holes on all four corners, as this would fit well in our custom case (more on that in a future post), while leaving room for cable routing on the top and bottom sides. Routing the traces was simple enough (if you’re not aware, traces are the etched lines of copper on the board that form the connections between parts), if complicated somewhat by the large number of thicc power lines needed to drive the motors (traces can have different thicknesses, depending on the current levels they are expected to carry).

PCB Design

The final PCB design, the Raspberry Pi mounts on the underneath into the GPIO header, this causes some problems later on.

At this point, we turned to PCBWay, who generously provided us with multiple free PCBs, making a custom control board wouldn’t have otherwise been possible on our very limited budget.

Begin sponsored review

The PCBs were all of excellent quality, with no obvious visual or electrical defects. l have used circuit boards from PCBWay before in personal projects outside of the jam and they have always performed well, with no manufacturing defects. The layers are all well-aligned and the silkscreen is sharp and bright.


The two sides of the raw PCB, before any soldering or assembly.

Another point I can make is that the adhesion of the traces to the fiberglass backing was excellent, as demonstrated by the lack of ripped pads after many hours of rework, and I’m not exaggerating there, I must have pulled and resoldered one of the chips at least 25 times during troubleshooting, with only minor defects in the solder-mask present when we finally got it working.

In conclusion, I would recommend PCBWay for all of your prototyping needs, their rates are well in line with the competition and delivery is usually quick and cheap, despite our boards for this particular project being heavily delayed due to the general state of the world in 2020.

End sponsored review

Now that’s over - have you ever tried writing a review of a circuit board, there’s not much to talk about, it’s really hard! - let’s get onto the parts. We ordered all the components needed to populate the boards from LCSC, and a week later I had a lifetime’s supply of anti-static bags, and the parts too of course.

LCSC Parts

I wasn’t joking about the lifetime supply thing, look at how many bags of parts there are! Side note - I apologize in advance for the quality of all photos, I’m no photographer by any stretch.

Bags in hand, I soldered up the board, in what was quite possibly the dodgiest “workshop” setup ever, no joke - it consisted of a sheet of MDF balanced between a bathtub and a stack of boxes. In retrospect I wish I’d have taken a photo. Anyway, I powered it up and…

Assembled PCB

The assembled PCB, spoiler - most of these parts will be desoldered fairly soon.

Nothing. And so began the endless troubleshooting, the problematic section of the board was the ARM chip, luckily all the other functions turned out fine. I went through the obvious troubleshooting steps, checking the voltage regulator, which was fine, checking the oscillators and jumpers. also good, I checked the programmer on another chip, and it worked fine. At this point, I was completely confused, and I eventually came to the conclusion that the problem must be my soldering. Off the chip came and I inspected the pins, no hidden bridges or bending. I tested the traces on the board itself, all fine. Somehow even more confused, I resoldered it back in place and flicked the power switch once again…

It worked, at least partially. Half the pins weren’t connected properly, this gave me yet more evidence that the problem was my crummy soldering skills rather than the parts I was working with. So I tried to reflow the non-functional pins, and I broke it somehow. Once again, there weren’t any solder bridges, at least none I could see, and all the supporting circuitry was functioning just fine. The only difference was that now the 3V power rail was shorted to GND. To test whether this was a problem with the regulator or the micro itself, I pulled the chip once more. The short went away.

All of this was fine though, we planned for this and had ordered a spare of every chip. After checking everything again, the regulator, the pads, the traces, the supporting circuitry, everything that could have an impact, I soldered the second chip in place, using hot air reflow this time rather than drag soldering.

It didn’t work. I feel like I’m repeating myself a ton here, but the power lines had shorted yet again, exactly the same failure mode as the previous chip. After a lot of deliberation on our Slack channel over what could be causing everything to keep breaking, we still had no clue. Our only option was to get another set of chips and try something different.

A few weeks later and I had the replacement chips (corona-mania shipping times sure did have a huge impact on how painful this whole process was). We weren’t taking any chances this time, I removed the regulator, powering the circuit from a known-good external supply and disabled all the external components the chip connected to, in case they were breaking it somehow. I swapped out all the capacitors and scrubbed the board to death in an effort to remove all left-over flux that could be causing problems. I held my breath, soldered it in place and flicked the switch, and…

New Chips

The replacement chips we had to order in.

It broke, AGAIN!!!!!!! Not only that, but it also fried the Pi, one of the motor drivers and blew up a capacitor (I still have no clue how this happened, we’re talking about 3.3V here, the capacitors were rated for far more). I was absolutely fuming, we were at around £60 in broken parts at this point, a huge chunk of our total budget. I was on the verge of tears, you have no idea how angry I was. I had no choice but to put everything in a drawer and forget about it, we were out of money and I had no confidence in this design ever working. Things were so bad, that I had actually started drafting an email pulling us out of the competition6.

A couple of weeks later, I was about to get the go-ahead to send said email, when I had an idea. Couldn’t we just scrap the onboard circuitry entirely and get a dev-board from STmicro, which we would then wire up to the points on the control board manually. Sure it’d be ugly and a ratsnest of wiring but it was a cheap way to get one last chance of success. I cut all the traces going from the chip to other parts of the board to avoid interference and wired up the development board.

I soldered in the spare motor driver from the first batch of parts and mutilated a new Pi Model 3B given to us by the jam to fit in the place of a Model A (those ports are a nightmare to remove, so much thermal mass…), powered it up and it worked. Entirely. I’m writing this two weeks after we had everything working for the first time, and no new problems have come up. I still have no clue why we had so many problems. I’ve used the exact same circuit on other projects before and it’s worked fine. Not that it matters now though, all I care about is that it worked.

Mutilated Pi

The replacement Pi, somewhat modified to properly connect to the control board.

Development is progressing very smoothly now, and I’m pretty sure we’ll be able to stick to weekly posts from now on. Next time - how we designed and manufactured the casing. I promise it won’t be as long as this one!

Take a quick peek at the case design below!

Thanks for reading to the end, if you’re from another team reading this in the future, the best advice I can give you after going through this ordeal is get all the support you possibly can, think of other ways to solve problems, don’t just try the same thing over and over again, and although it’s cheesy to say it, don’t give up!