This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Multiplexing SWDIO/SWCLK to program panels in production - Why is it a bad idea?

Hello,

I've been researching how to go about programming our devices on the production line. Most of the threads I've seen suggest two options: either to order them pre-programmed or to use several flashers connected to a PC (or use that solution that works with microSD cards).

The first suggestion is not an option for us, we have to produce about 5000 pieces that need to be delivered to Kickstarter backers and if we want to meet our deadline we would have to send the final binaries to the manufacturer now and the firmware is not ready yet. For mass production, we will probably use this option but not right now.

The second option is to use a flasher per device (could be one per 8 or so, depending on the capabilities of the flasher), but we don't have space in the PCB to use a bed of nails or something like that to connect them directly to each device.

One choice would be to draw traces from the SWD pins out to the panel and connect them there. I read in another post asking the same question that this not a good idea at all because the traces might get shorted when the devices are depanelized.

Our panel will have 40 to 50 boards and the PCB has 4 layers. We are planning to use a single J-Link and multiplex the SWD lines to program one device at a time. We would draw the SWD lines from one of the inner layers of the PCB so we doubt we would have problems with traces being shorted when cut.

So my question is: Why is such a bad idea to multiplex the SWD to program a single device at a time?

Parents
  • Not sure it's going to work too well. Even if you have individual traces per board, you're going to have some fairly long lines. You'll have to route them to be about the same length and even then the stray capacitance on the longer ones is going to cause you at the least speed issues, at the worst, programming failures.

    I don't think muxing the SWDCLK is going to work. SWD v1 wasn't designed for that, again I think you'll run into capacitance issues pretty quickly apart from problems with multiple devices trying to respond. ARM designed SWDv2 multi-drop for sort of that and I can't find quickly in the spec how many devices are allowed to attach to SWD even there. And the nRFs don't support multidrop (don't know if anyone does). If they supported JTAG mode that would be a cool way to program lots of them, you could really set the whole array up as a big boundary scan chain, but they don't support that either.

    I've never come across anyone trying to do it this way, which makes me feel that .. there's always a better plan.

    You said the board is too small for a bed of nails. Even the tag-connect size with 3 holes (they're a pain) and 6 pads? I'd recommend trying that again and see if you can find a creative way to get them in.

    Last option I'd probably try if there really is no room is to panelize the boards with a strip of beds of nails between them, one per actual board (you should be able to pack those in), program the boards via their (personal) connector, then snap them off. You'll probably reduce your board count per panel that way because of the extra area, but you have the advantage that it will work, you don't need to make anything complicated to make it work and programming will be super quick. You'll have to work out the economies of getting fewer boards out of each panel and thus how much it'll cost per board to do this, I'd hope for a run of 5000 you'd be talking pennies per board, not insignificant for a kickstarter run, but if it gives you 100% programmability of every board on the panel using a simple method, it may be worth it to get it done.

    I reckon by the time you've done 5000 you'll be quite good at it :)

  • you've misunderstood much of what I suggested. I'm not suggesting muxing anything, I don't think it will work to mux even swdclk over more than a few devices because you'll run into capacitance issues. I know what multidrop is and how it works, but even the spec for multidrop doesn't say how many devices can be connected (not that I've found) and anyway nothing supports it. The SWD v1 spec specifies one device per swdclk/swdio line pair.

    I suggest having one single bed of nails per device on thin strips around the actual devices which can be broken off after use. You don't need 50 jlinks, you need one, or two, or three, you just go from bed to bed and program each device. It's slow but it works. The more jlinks you have, the faster you get it done. One guy does one panel, someone else does another.

    No muxing at all.

Reply
  • you've misunderstood much of what I suggested. I'm not suggesting muxing anything, I don't think it will work to mux even swdclk over more than a few devices because you'll run into capacitance issues. I know what multidrop is and how it works, but even the spec for multidrop doesn't say how many devices can be connected (not that I've found) and anyway nothing supports it. The SWD v1 spec specifies one device per swdclk/swdio line pair.

    I suggest having one single bed of nails per device on thin strips around the actual devices which can be broken off after use. You don't need 50 jlinks, you need one, or two, or three, you just go from bed to bed and program each device. It's slow but it works. The more jlinks you have, the faster you get it done. One guy does one panel, someone else does another.

    No muxing at all.

Children
No Data
Related