a question about fsm confusing me for a long time



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:.......

.



Relevant Pages

  • Re: FPGA to PHY/MAC chip
    ... add an Ethernet interface to my spartan-3e FPGA allowing it to receive ... using the Digilent Basys 2 starter board along with the pmod Ethernet NIC ... This pmod contains a PHY/MAC chip with an SPI ... If you had a state machine that consisted of a register which ...
    (comp.arch.fpga)
  • Re: deglitching a clock
    ... John Larkin wrote: ... and a state machine to make sure that the clock only changes ... Would you use the Pin-Delay feature on a FPGA, to de-skew click lines from other devices? ...
    (comp.arch.fpga)
  • Re: A first FPGA project
    ... operation/connections of the FDC controller. ... on is the FPGA in the middle. ... If you are only handling a sector, you may be able to use a state- ... But it should all be implementable in a state machine, ...
    (comp.arch.fpga)
  • Re: hardware software codesign
    ... How much data to you need to send to/from the FPGA? ... state machine to process the received data. ... Your state machine could also put the data into a RAM ...
    (comp.arch.fpga)
  • Re: Help coding a bigger project
    ... The approach is deppending on your application, FPGA resources, maximum ... One alternative might be runing everything at one clock (some high-speed ... clock), do one state machine which takes care of every entity one-by-one, ... > LP-filters to filter the signals. ...
    (comp.arch.fpga)