Sunday, 20 October 2024

Testing the castellated module format

In the previous post working on the modularisation of the MEGAphone with NLnet Foundation's support, I described the castellated  module format I have developed.  The sample PCBs from PCBWay have turned up now, so time to try out how well it works in practice!

Here is what the sample boards look like: 

 

For ease, I made it a single panel, and made the little test modules snap-offs.  The test modules just have simple wiring from each pad to a set of hole-throughs in the middle, for testing continuity.

There is unfortunately a fabrication error on the PCBs: The little modules have all their cut layer a bit to one side, or perhaps the other layers in there were shifted. I have checked the Gerbers, and it was all correctly aligned there. So I'm guessing PCBWay might have accidentally moved something when setting it up, perhaps with the castellation, thinking that the far end of the PCBs should be castellated, instead of just the sides.

This has a few consequences: 
 
1. Pins 5 and 10 on the little PCB at least have their trace to the hole-throughs cut, so continuity cant best tested over those.

2. The cut-outs for the DIP IC puller to allow the module to be held still while soldering don't work, because the top and bottom edge of the module is misplaced by about half a pin.  This wasn't a huge disaster, but did make soldering it on fiddlier than it should have been. 

3. Also for desoldering, this means you don't have a nice way to hold the module with the IC puller, while using either a soldering iron or hot air gun to reflow it.
 
You can see what has happened with the misplaced cuts when the module sits on the carrier board: At one end there is spare PCB, and at the other end, there is only a 1/4 of a hole, instead of a half of a hole!


 
I did try filing off the excess at the other end to make it possible to use the DIP IC puller, but it didn't really help, as the opposite end was loose, and so it could rotate a bit. But every indication is with that fixed, it should work nicely.
 
The only other error I have found so far is a problem of my creation: The wide 20-pin module is too wide for the carrier board footprint, as you can kind of see in this image:
 

 
Whereas the other two smaller modules sit nicely over their footprints, the wide one is too wide, and doesn't leave enough of the carrier board pads visible. That will be an easy fix, however.
 
Time to try soldering it on, including fitting the VCC and GND straps using bits of solder wick.  That worked really easily, as the solder wick really wants to connect to the solder, even if it only reflows a little, because of the thermal mass of the carrier board's GND and VCC planes. So that feature is a win!
 

 
I ended up with it a bit rotated first time around as you can see above, and so I got to try out the ease of desoldering straight away ;)  With the VCC and GND straps not fitted, there was no massive thermal capacity problem, and with a bit of mucking about with my hot air gun, I was able to pull it off again prying it from underneath with a pair of tweezers. I was not at all gentle, and had the hot air set to 350C, which is pretty hot, and it still worked to remove it, without ripping any pads. You can see that some of the pads the solder was only softened, not properly melted when I pried it off, but all the pads still stayed put!
 
 
In the process of doing all this, I have learnt that the hole diameter in the castellated pads should be a bit bigger, so that the soldering iron can sit in it easier, to ensure ease of forming the solder joint. Also, for ease of removal, I should reduce the size of the pad on the underside of the modules.  The big pad on the top side is good, though, as it allows for continuity testing of the joints super easily using multimeter probes, because the pads are big enough to park the probes on each.

Remounting the module wasn't too hard, although I did learn the hard way, that its much easier if you first wick off the solder lumps from the carrier board pads and the underside of the module, so that it could sit flat on the carrier board again. This is another reason to remove the excess pad size on the underside of the modules.
 
Once I did that, it was really easy to reseat the module.  Holding the soldering iron vertical in the half-hole of the castellation seemed the easiest way to get both parts of the joint hot quickly.  

Again, I purposely didn't take too much care with this process, to simulate someone doing this with limited skills, or in an austere environment.
 

Then it was time to refit the VCC and GND straps. I recycled the saturated bits of solder wick from the process of cleaning the module and carrier pads, so it looks a bit scrappy, but the key point is that all connections have continuity.
The only thing to be careful of when recycling saturated wick like this, is to make sure it sits low enough, that it can't snag on anything sitting above the module PCB level, for example, if we had the carrier board sitting directly behind the battery or screen in the MEGAphone.  But its fairly easy to poke it down using a soldering iron.
 
The final thing to try out was to apply glitter polish, and see how the QR-code style reference points work to make it easier to acquire and compare an image of the glitter over the module. Actually making the image registration software to do this is outside of my scope, but if anyone would like to give it a go, and see how well it works, here are a few images from different angles:




Anyway, the short story is that this module format seems to be workable, and I just need to do a respin at some point with the reduced pad size on the underside of the modules, and fix the width of the wide module. I'll do those two when I design up the first modules (which will probably be DC:DC regulator modules), which will also give some time for me to figure out with PCBWay how the production fault occurred, so that we can avoid it in future.

Sunday, 6 October 2024

Modular MEGAphone: Prototyping castellated modules

 In the last post, I described a concept for the modules for the MEGAphone based on the following approach:

B. Half-Round Castellated Pins

C. Key Pins & Varied Module Dimensions.

D. Carrier Board Cut-Outs for Reduced Height / Reverse Component Mounting

E. Carrier Board Cut-Outs for Ease of Removal

F. Bridges for Power and Ground Thermal Relief

I'm going to add to that:

G. Image Registration Reference Markers

The reason here, is to make it easier to check if a device has been tampered with, by making it possible for someone to make an image registration-based blink comparator, to quickly and easily check of the glitter polish has been tampered with. I'm not going to implement that right now, but I want to make it easy to do.


Let's start with making a footprint in KiCad for a simple version of the carrier board half of this interface.  This requires the surface-mount pads for the pins, and the cut-outs for the ease of removal, and the cut-out to allow for reverse-side components on the modules, as well as the image reference markers.

So let's start with measuring the size of the hooks on the end of an IC puller I have here, so that we can size the cut-outs at the ends. The hooks are only about 3mm wide and  2mm deep, so it looks like 4mm x 4mm should be big enough. These should stick out far enough, so that the hook can be got into place, but still have enough of the cutout beneath the module for the hooks to grab onto.  The edges of the module will restrain the IC puller when used, but won't restrain a screwdriver or other improvised tool, if one is used. Therefore, the cut-outs for the ends should not be contiguous with the cut-out for the module components.

Let's take a look at what this looks like for the 2x5 format:


We have the 2 rows of 5 pads in the middle, where the module will sit on top.  Then above and below that, we have the A1,A2 and B1,B2 jumper pairs: These are for putting the jumpers on that connect the module to the possible large and heat sucking GND and VCC planes of the carrier board -- and vice-versa, cutting and removing the jumpers disconnects the module from those planes, and thus making it much easier to desolder or resolder, because none of the pins are going to be massive heat-sinks.

Back to the missing pin 2: This is what allows the user to know which way around the module should go: You can't rotate it or flip it, and still have the missing pad line up with the missing pad on the module half, that looks like this:

I've included exclusion zones for everything except for tracks on the rear side, except for the area marked in the middle that corresponds to the cut-out in the carrier board. The pry zones should have exclusion zones for everything, including tracks, so that using hard tools there can't mess up the function of the module.  I've not got those quite right here, which I'll have to fix, but hopefully you get the idea.

On the front side, there is no exclusion zone, because those physical problems don't apply there.

On the rear side of the module, we can see the pry zones, where no components should be placed, because a user may be using a hard tool against that surface to try to lift the board off.


Any components on the rear side should go in that square in the middle.

Now, for a symbol for the module, I've gone with this, so that those power and ground plane isolation jumpers are explicit:

For modules, a regular 10 pin symbol can be used for now, so I haven't made an explicit symbol just yet.

As I discussed in the previous post, I'd like for different modules that are not electrically compatible with one another, that they shouldn't fit. To do that, we can most easily remove different pins, or combinations of pins.  For removing only a single pin, there are only two choices: a corner, or a pin next to a corner. Removing a middle pin won't work, as then the module could be flipped vertically. So we can have a "minus pin 1" and a "minus pin 2" version.  If we want more variants, then we need to remove two pins, with "minus pins 1,2", "minus pins 1,3", "minus pins 1,4", "minus pins 1,7", "minus pins 1,8" and "minus pins 1,9" are the only options that maintain resistance to Murphy's Law. That would give us 8 total variants. 

I'll get to those, but first, I wanted to make a 20 pin version, with narrow and wide variants, depending on the space required on the module:



At this point, I have enough done that I can design up some simple test PCBs for fabrication, so that I can see whether they really are easy to solder and desolder etc.

For that, I'll make a 100x100mm carrier board (US$5 for 5 pieces from PCBWay and friends) with places for various modules, on both sides of the board, as well as simple examples of the modules, with hole-throughs that go to each pin, so that I can easily verify that the connections have been made. I'm not going to worry about the various missing-pin combinations, as that's less relevant right now.

Here's the test carrier board, with six of these footprints, spread over both sides, with every pin broken out to some standard 0.1" headers for ease of testing:


Looking at this, I'm slightly concerned that I have the inter-pad spacing a bit tight, and that they will be prone to bridging. I know that 0.1" pin headers are super easy to solder, so I should be able to reduce the pad heights to match that ratio of pad to space. They were 2mm, so only just over 0.5mm between them. I've now reduced them to 1.75mm, so that they now have just over 0.75mm between them, which feels a lot better:

Now for the test modules. I decided to add them as snap-offs on the PCB, as this should be cheaper than submitting 4 different PCB orders. I've not done this before, nor worked with PCBWay for castellated edge connectors. So let's see if they complain about my design :)


Actually, it occurred to me that it might be cheaper to do it in two parts, since the modules are forced to be 4 layer in this arrangement, even though they are just simple adaptors right now. But maybe I'll leave them all together, as it will still confirm that PCBWay can do this with 4-layer boards. In which case I should ideally put GND and power layers in them, with thermal relief connections to the pins, so that the thermal issues from that for soldering are reproduced.  Once I get the review feedback from PCBWay (I submitted it in the middle of the night), I'll make a decision on it, as I'll be pleasantly surprised if they accept it first time around.

As expected, I got some feedback from PCBWay, who pointed me at this resource

Basically I need to make my tabs wider (2mm+), with rounded ends, as well as the gap between the boards (1.6mm+), and I can then put drill holes (diameter > 0.45mm) along the edge, to make it easier to break them off.  Here is how the connections work now:

So let's see how PCBway goes with that. It passed, but the price is pretty high for five pieces, due to the castellations, and the 6 different designs on the panel. I'll live with that for now, as my priority right now is testing the module design.

Hopefully, it will work when it arrives...