Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > General Computer Discussion > Software > shift left/shift right in VHDL

Reply
Thread Tools

shift left/shift right in VHDL

 
 
deepak21 deepak21 is offline
Junior Member
Join Date: May 2012
Posts: 1
 
      05-06-2012
Dear

Question: how to shift left or shift right

Rough program as follows

library IEEE
...
...

Package matrix_types Is
Type matrix_4x1 Is Array (1 to 4) Of std_logic_vector (7 downto 0);
Type matrix_1x4 Is Array (1 to 4) Of std_logic_vector (7 downto 0);
Type matrix_4x4 Is Array (1 to 4, 1 to 4) Of std_logic_vector (7 downto
0);
End Package matrix_types ;
...
...
architecture.......
begin
.....
process
.......

Variable x : matrix_4x1 :=
("000000100",
"0000000000",
"0011110000",
"0010110001");

begin

QUERY: Now i have to shift left or shift right EACH ROW of variable x either TWICE or
THRICE etc.

Please reply me dear...

Thanks and Best Regards,
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Java left shift and right shift operators. Sanny Java 38 04-29-2011 10:02 PM
what "shift" does, if not "$_ = shift;" ? devphylosoff Perl Misc 3 12-04-2007 12:27 AM
Left Shift / Right Shift Operators Santosh Nayak C Programming 16 11-30-2006 05:10 PM
Shift - byte[] buf shift Roberto Gallo Java 3 01-27-2004 04:26 PM
left shift then right shift an unsigned int Wenjie C++ 3 07-11-2003 08:22 PM



Advertisments