- **VHDL**
(*http://www.velocityreviews.com/forums/f18-vhdl.html*)

- - **Specify bit position in array of vectors**
(*http://www.velocityreviews.com/forums/t377617-specify-bit-position-in-array-of-vectors.html*)

Specify bit position in array of vectorsGosh, it didn't take long for me to need help again! I promise this
is my last question for awhile. I have four books on VHDL and Google didn't help. How do I specify a bit position in an array of std_logic_vectors? TYPE arraytype IS ARRAY (0 TO 8) OF STD_LOGIC_VECTOR(7 DOWNTO 0); SIGNAL foo : std_logic; SIGNAL big_array : arraytype; .... foo <= big_array(5,2); -- yes I know this is wrong. What is the syntax to pick bit #2 of big_array(5)? Thanks again! Shannon |

Re: Specify bit position in array of vectorsOn 9 fev, 15:31, "Shannon" <sgo...@sbcglobal.net> wrote:
> Gosh, it didn't take long for me to need help again! I promise this > is my last question for awhile. > > I have four books on VHDL and Google didn't help. > > How do I specify a bit position in an array of std_logic_vectors? > > TYPE arraytype IS ARRAY (0 TO 8) OF STD_LOGIC_VECTOR(7 DOWNTO 0); > SIGNAL foo : std_logic; > SIGNAL big_array : arraytype; > > ... > > foo <= big_array(5,2); -- yes I know this is wrong. What is the > syntax to pick bit #2 of big_array(5)? > > Thanks again! > > Shannon Isn't it big_array(5)(2) ? Can't imagine another way! Cheers weber |

Re: Specify bit position in array of vectorsOn Feb 9, 12:05 pm, "weber" <hug...@gmail.com> wrote:
> On 9 fev, 15:31, "Shannon" <sgo...@sbcglobal.net> wrote: > > > > > > > Gosh, it didn't take long for me to need help again! I promise this > > is my last question for awhile. > > > I have four books on VHDL and Google didn't help. > > > How do I specify a bit position in an array of std_logic_vectors? > > > TYPE arraytype IS ARRAY (0 TO 8) OF STD_LOGIC_VECTOR(7 DOWNTO 0); > > SIGNAL foo : std_logic; > > SIGNAL big_array : arraytype; > > > ... > > > foo <= big_array(5,2); -- yes I know this is wrong. What is the > > syntax to pick bit #2 of big_array(5)? > > > Thanks again! > > > Shannon > > Isn't it big_array(5)(2) ? > Can't imagine another way! > Cheers > weber- Hide quoted text - > > - Show quoted text - Yep. That did it. (I imagined all kinds of ways! None of them correct...hehehe) Thanks, Shannon |

All times are GMT. The time now is 09:32 PM. |

Powered by vBulletin®. Copyright ©2000 - 2014, vBulletin Solutions, Inc.

SEO by vBSEO ©2010, Crawlability, Inc.