-- This is the template for Lab 1. You should start with this; -- it will make your life easier. library ieee; use ieee.std_logic_1164.all; use ieee.std_logic_arith.all; entity lab1 is port( KEY : in std_logic_vector(3 downto 0); -- pushbutton switches SW : in std_logic_vector(8 downto 0); -- slide switches LEDG : out std_logic_vector(7 downto 0); -- green LED's (you might want to use -- this to display your current state) LCD_RW : out std_logic; -- R/W control signal for the LCD LCD_EN : out std_logic; -- Enable control signal for the LCD LCD_RS : out std_logic; -- Whether or not you are sending an instruction or character LCD_ON : out std_logic; -- used to turn on the LCD LCD_BLON : out std_logic; -- used to turn on the backlight LCD_DATA : out std_logic_vector(7 downto 0)); -- used to send instructions or characters end lab1 ; architecture behavioural of lab1 is begin -- these are constant all the time. Don't change these. LCD_BLON <= '1'; -- backlight is always on LCD_ON <= '1'; -- LCD is always on LCD_EN <= KEY(3); -- connect the clock to the LCD_en input LCD_RW <= '0'; -- always writing to the LCD -- Your state machine goes here end behavioural;