Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com 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.

FSM - distinguishing bit pattern in VHDL

Status
Not open for further replies.

kringo

Newbie level 6
Joined
Jul 13, 2009
Messages
12
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,373
distinguish bit pattern

Hi!

I want to programme a FSM (finite state machine) and the only problem left is, that I have to distinguish a certain bit pattern. How can I do this in VHDL? I only want to distinguish the first bit and in the next step the following 5 bits (in 2 steps)
For example:
My register holds 011010
first step: distinguish MSB (0 or 1)
second step: distinguish second bit to LSB

thanks
greets
 

Re: distinguish bit pattern

hi
what is your data source? from out side and in serial mode? and what is your baud rate?
 

Re: distinguish bit pattern

the bit pattern is transmitted over the serial IF (pc to fpga board) with a baud rate of 38900! Do you know smthg in VHDL where I can distinguish my input like this:

if input[0] == 0
\\command
elseif input[1:7] == 101110
.
.
.

Thanks
 

Re: distinguish bit pattern

Hi
if your baud rate is 38900 so your frequency is 20 KHz. so if you are working in async mode your line must be high and when want to transfer data one start bit and 8 bit data and one stopbit follow it. you shold work with frequency equal to 16 multply by data rate that is frequency 320 KHz. you should start to check your line to see if it is changed to zero then start to sample it till middle of bit and if it is low for more number of samples write zero to your registers and so for other bits. if you are working sync mode you should start to sample and save data to read to your desired sequence.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top