Saturday, December 19

Not Ready for FPGAs? Try a CPLD

[Kodera2t]  wanted to experiment with programmable logic. Instead of going with an FPGA board, he decided to build his own CPLD (complex programmable logic device) board, with a built-in programmer. The CPLD is a Xilinx 9536 which is inexpensive and, though obsolete, still readily available. The programmer for the board uses an FT232RL and the total cost is very low ([kodera2t] says it is in the price range of a Raspberry Pi Zero or about $4).

From a user’s point of view, a CPLD is just a small FPGA. Internally, there is a significant difference in how they implement your design. Although there are differences between different product families, CPLDs usually use a sea of logic gates arranged as an AND/OR chain. By feeding inputs and inverted inputs into the AND gates and then ORing the results, you can build interesting logic circuits. However, modern CPLDs use Verilog or VHDL, so you describe what you want just like with an FPGA and the software figures out how to use the underlying circuits to give you what you want.

FPGAs typically use a different method to represent logic, usually LUT or Look Up Tables that amount to truth tables, defining outputs from a set of inputs. However, other FGPA architectures exist (such as mux-based FPGAs). FPGAs usually have more flexible interconnection than a CPLD. From a practical standpoint, though, you can consider a CPLD as a “little” FPGA. CPLDs almost always hold their own configuration in non-volatile storage, so they come on instantly; only a few FPGAs do that.

The [kodera2] project on Hackaday.io has pretty thorough instructions for programming and also has a PCB layout for the board. The $4 price point is hard to beat, but a much more capable FPGA board doesn’t have to cost much more than that. However, if you want the experience of building everything from the PCB up, the CPLD project lets you get something up and running with a small investment and without having to solder super dense parts. On the other hand, if you just want to learn Verilog or VHDL, you don’t need any hardware. Just use your web browser.

There’s a short video of the board in action, below.


Filed under: FPGA

No comments:

Post a Comment