Pages created and updated by
May 18, 2016
When assigning pins in a CPLD or other programmable device, especially ones with several inputs and/or outputs, there are some ways that you can make the external wiring easier to do and follow. Here's an example for a keypad encoding circuit:
There are 16 inputs to the circuit (from the keypad)
and 4 outputs (to the LEDs).
By assigning the pins for the inputs so that they are ordered in the same way as the pins on the keypad, it means they can be connected by a ribbon cable 1-to1.
Note the wire colour sequence in the pictures above and below. (They appear to be reversed left-to-right because the pictures are taken from different directions. Red on the top right goes to the bottom left, etc. )
The outputs follow a similar pattern.
Here's a closer look.
Notice how the ribbon cable connects the outputs above to the LEDs.
Assigning pins this way makes wire tracing very easy, and it also makes it easy to rewire if a device needs to be replaced.
For example, here is a CPLD board:
It has four connector banks, P1, P2, P3, and P4. Each bank has two rows of connectors. Note that the pin numbers on the connectors are not always consecutive, and so you need to be careful when assigning them.
P1 layout is as follows: This connector can be used to get 3.3V to power other devices.
P2 layout is as follows: Note that pins 43 and 44 are not the same as other I/O pins, and so should be avoided.
P3 layout is as follows:
P4 layout is as follows:
Wilfrid Laurier University
© 2015 Wilfrid Laurier University