Continue to Site

Welcome to

Welcome to our site! is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Help for project(programmable counter)

Not open for further replies.


Member level 1
Nov 23, 2005
Reaction score
Trophy points
Activity points
I'd like some help for a project.

I want to make a programmable counter 1 to 10 (binary).It will be connected to 10 switches.If i switch on the 1st switch then it will skip the number 0,if i switch on and the second witch then it will skip and the number 1 etc...

I want to make it with PLD (xilinx xc95000).

Any ideas? i dont want a solution but rather some basic steps i could begin from.

thank you in advance

Do you already know Verilog or VHDL?

If it counts from 1 to 10, how can the first switch cause it to skip 0?

What happens if all the switches are on?

Latch inputs from the 10 switches and decode it to integer value.

Have two concurrent blocks ( 2 process if VHDL or 2 always if verilog).
Increment the counter in the first block. (cnt <= cnt1+1)
In the second block check wether the count value has reached the decoded switch value. If reached increment cnt1.
When this is passed to the previous block automatically that particular value will be skipped.

This is just an idea... U have to check in simulation....

I am sorry the counter should count from 0 to 15.It was just an example,the one i posted before.

I am supposed to do it with Ic-logical gates only.I was thinking of going with multiplexer logic. Having a logic cirquit that gives each input of the multiplexers the appropraite value and then having a normal counter that increases the num. of input line the multiplexers

Not open for further replies.

Part and Inventory Search

Welcome to