Sunday, April 7, 2013

CODE : SIPO Serial In Parallel out register VHDL

CODE : SIPO


This code is just an example for more detailed understanding of VHDL concepts I would recommend these two books :

1) A VHDL PRIMER by J. Bhasker - A VHDL PRIMER from flipkart.com
A VHDL PRIMER from amazon.com
A VHDL PRIMER from amazon.in

2)VHDL:PROGRAMMING BY EXAMPLES by PERRY - VHDL:PROGRAMMING BY EXAMPLES by PERRY from flipkart.com
VHDL:PROGRAMMING BY EXAMPLES by PERRY from amazon.com
VHDL:PROGRAMMING BY EXAMPLES by PERRY from amazon.in

----------------------------------------------------------------------------------
-- Company:
-- Engineer:
--
-- Create Date:    00:06:03 11/02/2006
-- Design Name:
-- Module Name:    SIPO_code - Behavioral
-- Project Name:
-- Target Devices:
-- Tool versions:
-- Description:
--
-- Dependencies:
--
-- Revision:
-- Revision 0.01 - File Created
-- Additional Comments:
--
----------------------------------------------------------------------------------
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
use IEEE.STD_LOGIC_ARITH.ALL;
use IEEE.STD_LOGIC_UNSIGNED.ALL;

---- Uncomment the following library declaration if instantiating
---- any Xilinx primitives in this code.
--library UNISIM;
--use UNISIM.VComponents.all;

entity SIPO_code is
    Port ( Din : in  STD_LOGIC;
           o : out  STD_LOGIC_VECTOR (3 downto 0);
           clk : in  STD_LOGIC);
end SIPO_code;

architecture Behavioral of SIPO_code is

begin
process(clk)
variable temp: std_logic_vector(3 downto 0):="0000";
begin
    if(clk'event and clk='1') then
        temp(3):= temp(2);
        temp(2):= temp(1);
        temp(1):= temp(0);
        temp(0):=Din;
        o<=temp;
    end if;
end process;


end Behavioral;


1 comment:

  1. Salve,

    The sense of praise that I have found for you after reading SIPO Serial In Parallel out register VHDL is overwhelming! Such a tremendous read!

    If Linux is to take advantage of the masses gathering behind Android and steamOS, then it truly needs to make things easier for the moderate level user.
    If someone wants to give a linux distribution a try but is coming from windows or mac then the chances are they will have smart phones, tablets and other peripherals that they will wish to connect.
    I am so grateful for your blog. Really looking forward to read more.

    Many Thanks,
    Kevin

    ReplyDelete