+ Post New Thread
Results 1 to 6 of 6
-
7th March 2005, 01:28 #1
- Join Date
- Mar 2005
- Location
- Alexandria, Egypt
- Posts
- 44
- Helped
- 2 / 2
- Points
- 1,669
- Level
- 9
Encoders
What is the diffrence between the priority Encoder and the normal encoder ? Plzz if any one can reply I will be thankfull. Also give me the number of an encoder without priority.
Thnx
-
7th March 2005, 01:28
-
7th March 2005, 10:07 #2
Re: Encoders
Originally Posted by Haytham-Sief
if (cond [0] == 1)
{
q <= 1;
}
else if (cond [1] == 1)
{
q <= cond [1];
}
else
{
q <= 0 ;
}
The h/w equailvalent will be such that cond[0] if top priority ..if it is one then it does not matter if cond[1] is 0 or 1 ... the implementation is usally in a layered mux condition.
1 members found this post helpful.
-
7th March 2005, 10:07
-
7th March 2005, 10:21 #3
- Join Date
- Feb 2005
- Posts
- 93
- Helped
- 12 / 12
- Points
- 2,224
- Level
- 10
Encoders
When you want to implement a priority encoder in VHDL/Verilog you use the if-else statement. The higher the priority the lower the delay. For normal encoders you use the case statement.
1 members found this post helpful.
-
7th March 2005, 10:21
-
7th March 2005, 11:02 #4
- Join Date
- Mar 2005
- Location
- Alexandria, Egypt
- Posts
- 44
- Helped
- 2 / 2
- Points
- 1,669
- Level
- 9
Re: Encoders
Thanx very much for ur help but plzzz I need more explaination , I'm not using VHDL I'm using hardware without controling I mean I cant conrol the priority of the encoder. Thnx alot
-
7th March 2005, 12:33 #5
- Join Date
- Feb 2005
- Posts
- 93
- Helped
- 12 / 12
- Points
- 2,224
- Level
- 10
Re: Encoders
If you are using schematics then I uploaded you two pictures of a priority and a normal encoder examples.
In priority encoder x2 has the highest priority while x0 has the lowest one.
In parallel all have the same priority.
Hope it helps
1 members found this post helpful.
-
7th March 2005, 12:33
-
6th February 2009, 16:26 #6
- Join Date
- Jan 2009
- Posts
- 38
- Helped
- 1 / 1
- Points
- 926
- Level
- 6
Re: Encoders
It is very useful. Thanks for your sharing.
+ Post New Thread
Please login