a question about fsm confusing me for a long time
- From: anny <zqr_123@xxxxxxx>
- Date: Wed, 12 Sep 2007 12:04:35 -0700
I am designing a state machine that will be fit into a FPGA.
The state machine have 9 states.Every state except idle state needs to
wait certain number of clockes (
for example, 80 clockes here,or maybe longer ,even 1000 clockes ). I
use counter in every state to hold current state.My question is I need
to load the counter in every state and counting,how can I seperate
the counter from the state ?When counting to 1000 clocks,the system
frequence is low,how to resolve it?
my code:
always @ (posedge clock)
case(cs)
idle: cs<=s0;
s0: begin
if(count==79) begin
count<=0;
cs<=s1;
end
else
count<=count+1'b1;
end
s1:.......
.
- Follow-Ups:
- Re: a question about fsm confusing me for a long time
- From: Andy
- Re: a question about fsm confusing me for a long time
- From: Mike Treseler
- Re: a question about fsm confusing me for a long time
- Prev by Date: "Latch generated" warning from Synplicity
- Next by Date: Re: "Latch generated" warning from Synplicity
- Previous by thread: "Latch generated" warning from Synplicity
- Next by thread: Re: a question about fsm confusing me for a long time
- Index(es):
Relevant Pages
|