Re: Who can explain the bit'pos for me?
- From: threeinchnail@xxxxxxxxx
- Date: 29 Jun 2006 05:43:32 -0700
I got it. Thank you all very much ^_^
D Stanford wrote:
threeinchnail@xxxxxxxxx wrote:
Thank you, Hubble. I understand your explanation..
But I am still confused it a little bit. If I take an example of
bit_vector ("10101010"). I want to convert it to integer. According to
the function:
1. result:=0+0;
2 result:=2*0+1;
3 result:=2*1+0;
For it to function properly, bv'range must be max downto 0. It must be
sequencing from MSB to LSB.
with an input bit vector of "1100"
1. index = 0, result = 0*2 + 1 = 1
2. index = 1, result = 1*2 + 1 = 3
3. index = 2, result = 3*2 + 0 = 6
4. index = 3, result = 6*2 + 0 = 12
.
- References:
- Who can explain the bit'pos for me?
- From: threeinchnail
- Re: Who can explain the bit'pos for me?
- From: Hubble
- Re: Who can explain the bit'pos for me?
- From: threeinchnail
- Re: Who can explain the bit'pos for me?
- From: D Stanford
- Who can explain the bit'pos for me?
- Prev by Date: Re: logic synthesis
- Next by Date: Emacs vhdl-mode question
- Previous by thread: Re: Who can explain the bit'pos for me?
- Next by thread: Re: Who can explain the bit'pos for me?
- Index(es):
Relevant Pages
|