Asynchronous 4 Bit Up Counter using D-Flipflops

Guest #5216714
Rate this post
• ▲ useful
▼ not useful
Hey,

i am kinda stuck since 2 hours, i can't find anything related in the 
web. so i decided to ask you guys. may be i can get some hints for my 
problem.

first of all. i want to implement a 4 Bit Up Counter using only D 
Flipflop with an asynchronous reset. my problem is i dont know hot to 
"initilize" the flip flops since i get "not initialized" when i use iSim 
in VHDL.

i am only allowed to use AND/NAND gates and the D Flipflop should work 
with a falling edge.


D Flipflop: https://imgur.com/maADKt2

Asynchronous 4-Bit UP Counter: https://imgur.com/g83g5SF

i am very grateful for any help, i am stuck with my ideas right now.

PS: The D Flipflop has to work with only the CLK, D, Q and nQ. The reset 
is for the 4 BIT Counter!
Moderator (Company: Titel) #5216733
Rate this post
• ▲ useful
▼ not useful
anjej wrote:
> i am only allowed to use AND/NAND gates and the D Flipflop should work
> with a falling edge.
Simply attach your VHDL file(s) here without invoking screenshots on 
more or less dubious file-sharing portals. Then it's easy to show you 
the solution...

> PS: The D Flipflop has to work with only the CLK, D, Q and nQ. The reset
> is for the 4 BIT Counter!
I thought you must implement that counter using those flipflops...
However:  when it's an asynchronous reset, then it must go to flipflops. 
If it's a synchronous reset then it can go to the combinatorial network 
between the flipflops.

> my problem is i dont know hot to "initilize" the flip flops since i get
> "not initialized" when i use iSim in VHDL.
Try that in the entity's port declaration
q : out := '0';
qn : out := '1';
Guest #5216780
Rate this post
• ▲ useful
▼ not useful
Thank your for your reply.

Lothar M. wrote:
> anjej wrote:
>> i am only allowed to use AND/NAND gates and the D Flipflop should work
>> with a falling edge.
> Simply attach your VHDL file(s) here without invoking screenshots on
> more or less dubious file-sharing portals. Then it's easy to show you
> the solution...

Okay, done.

>> PS: The D Flipflop has to work with only the CLK, D, Q and nQ. The reset
>> is for the 4 BIT Counter!
> I thought you must implement that counter using those flipflops...
> However:  when it's an asynchronous reset, then it must go to flipflops.
> If it's a synchronous reset then it can go to the combinatorial network
> between the flipflops.

Yeah that counter has to be build with those flipflops.
So basically i use my reset input and wire it to all clk's of the 
flipflops?

>> my problem is i dont know hot to "initilize" the flip flops since i get
>> "not initialized" when i use iSim in VHDL.
> Try that in the entity's port declaration
> q : out := '0';
> qn : out := '1';

Thank you i did that, but i did that with the 'd' too. So i got some 
results right now. I am looking if the results are right.

Reply

Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.

Formatting
  • [c]C-Code[/c]
  • [vhdl]VHDL-Code[/vhdl]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]
  • [[Title]] – link to an article
  • Link to another post: right-click its post ID (#8078628), copy the address, paste it into the text

More about formatting

Post long source code as an attachment, not in the text.

Already registered? Log in

Not shown to anyone. We send you a link; your post appears once you confirm it there.

By submitting you create a free account and accept the terms of use.