In a previous post I mentioned how to build a Xilinx programmer using a Raspberry Pi Zero for their basic XC9500XL CPLD range. This has worked great on some projects. But I’ve had a few issues with it so I decided to upgrade my programmer. This outlines why and what I use now.

The Problems

So, the Raspberry Pi method is really good for small one-off projects. It can power the Xilinx 3.3v from its own regulator and is very fast at programming. But there is no dedicated cable for the GPIO to become a JTAG so I’ve been using individual jump wires for a while. These were beginning to degrade and I was considering building a more permanent solution.

I gave away my Pi Zero recently and bought a newer one. Exactly the same board revision but I’m guessing they have changed the regulator or something similar because it could no longer provide enough power to run the Xilinx chip to program it. I ended up solving this by plugging boards into an Amiga, powering up and letting the board’s own regulator power the Xilinx (making sure the 3.3v line isn’t connected up to the Pi).

The final problem to solve was having to constantly solder 6 pin connectors on to boards just to do one-time programming. I figured there had to be a better way.

The Solutions

First of all I decided to buy a reliable, dedicated Xilinx programmer that was still compatible with xc3sprog. I found the Digilent JTAG-HS2 on RS and figured out it was compatible with xc3sprog using the cable type jtaghs2. Not only that but I could use the version in the Debian/Ubuntu repositories instead of the custom version for Raspberry Pis. It should be noted that the newer JTAG-HS3 probably isn’t compatible and doesn’t have a connector for the standard 6-pin layout.

Next up, power. The Digilent device doesn’t provide power to the hardware at all. So I figured I would inline a 3.3v supply. To do this I found a set of breadboard power supplies on Amazon that were £10.59 for 5.

I combined one of these with an old power supply from a BT VDSL2 modem I had lying around. This alone would have been enough to program one of my boards that had JTAG pins. But I wanted to be able to program boards without the pins attached. There is where pogo pins come in. Pogo pins are basically spring-loaded pins that you can push onto a board to make contact, then when you are done you can simply release. I was considering a clip-on design but some of my boards would make this tricky, I then found a handy push-down and hold 6-pin pogo device which was designed to work with JTAG on eBay. So I purchased that too.

Now to put the whole thing together. I prototyped the setup on a breadboard and then found these breadboard-like PCBs on Amazon for the final design.

I soldered everything together and the end result looks like this.

It may be difficult to see, but the under the HS2 the + rail is connected to VDD and the - rail is connected to GND. The HS2 and the pogo pin cable are connected using basic right angle pins. The breadboard power supply is soldered directly on and wires are used to bridge the gap in the breadboard. I’ve labelled everything up with a label printer so I can make sure everything is the correct way around even if I disassemble it all.

Now I simply push down and hold the pogo pins onto the board, press the power button on breadboard PSU, hit enter on the computer keyboard and about 10 seconds later (for a XC9572XL) the Xilinx CPLD in question is programmed, I then press the power button again and release the pressure on the pins. If I do need to program a board with pins on it I can remove the connector from the blue pogo pin device and plug it in directly. I was able to program 9 boards this was in a few minutes.