Programmable Devices
CPLDs, FPGAs, SoC FPGAs, Configuration, and Transceivers
20693 Discussions

Selecting the correct Altera CPLD for LED signal decodings

Altera_Forum
Honored Contributor II
1,136 Views

Hello! I am new to this forum and also to CPLDs... 

I am working on a project and in the middle it has been decided to include a more advanced LED panel than what was planned initially. 

This would require additional 40 to 45 IO pins than already available on the MCU. There is also a need for decoding the MCU output signal, eg binary to seven-segment. 

I thought of using decoders for decoding and IO expansion. However, it appears that the MAX V CPLDs are actually cheaper than multiple decoders and also occupy less space. 

I do not have much of experience with VHDL and other HDL languages.And at this point I cannot even afford to spend more than say, two weeks to learn a new software or language. 

I have a few questions before beginning to design with a CPLD 

 

Is the most inexpensive CPLD capable of doing the following.... 

1. accept a serial input 

2. expand it to 48 bit parallel 

3. Decode it and provide a 48 bit output 

(Decoding will mostly be binary to seven segment) 

 

Also, the MAX V datasheet says that the 5M40Z series has 40 Logic elements. But just below it says that it has 24 LABs and each LAB has 10 logic elements, which should translate to 240 and not 40! So how much does it actually have? 

Please help. 

Thanks
0 Kudos
5 Replies
Altera_Forum
Honored Contributor II
390 Views

You will at least need a 5M80Z because with 48 outputs you need 48 registers and the 5M40Z only has 40. 

If you want 'no flashing while the outputs are updated' you need another 48 buffer-registers and thus at least a 5M160Z. 

If your serial input is a 'true' serial you may need a bigger device still as you would have to implement a baudrate generator and such. 

If you can do some bit-banging, i.e. a data signal and a strobe, the 5M80Z/5M160Z will very probably be OK.
0 Kudos
Altera_Forum
Honored Contributor II
390 Views

Does this mean that the M540Z devices have only 40 flip flops? 

Its has 54 IO but only 40 Flip flops! Does this mean that a few IO pins cannot be connected through flip flops? 

Also, the datasheet says it has 24 LAB and each LAB has 10 logic element. This is unclear to me. Please explain...
0 Kudos
Altera_Forum
Honored Contributor II
390 Views

The datasheet specifies 40 LEs on page 1-2, 4 Long LAB Rows on page 2-3, 10 LE/row * 4 = 40 

I have no good idea how they arrive at 24 Total LABs. I guess they only produce 4 type of die and enable/disable functionality according to the 'sold' item, which means that out of 24 LABs a 5M40Z only has 4 LABs enabled/operational
0 Kudos
Altera_Forum
Honored Contributor II
390 Views

Alright.... 

even if there are only 40 flip flops in the 5M40Z, are all the 54 IO pins accessible? 

Can multiplexing help? In the sense that not all 48 LEDs will be ON simultaneously. For half the duty cycle the first 24 will be signaled and during the other half of the duty cylcle the remaining 24 LEDs will be signaled. In this manner we would require only 24 Flip Flops, multiplexed to different set of IO. 

Is this possible?
0 Kudos
Altera_Forum
Honored Contributor II
390 Views

No. With 40 LE's you can only drive 40 unique outputs. The multiplexer themselves will require (an additional) 48 LE's. 

I would suggest you to just try it out and launch Quartus and see what it generates.
0 Kudos
Reply