Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
16 years ago

How to use VHDL to write a kind of LED light program?

How to make an LED light by writing VHDL code program? i am just leanning VHDL.thank you !

5 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    It is very easy. Refer to below:

    library IEEE;

    use IEEE.std_logic_1164.all;

    Entity LED_light is

    port ( LED_out : out std_logic);

    end LED_light;

    Architechture RTL of LED_light is

    begin

    LED <= '1';

    end RTL;
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    library IEEE;

    use IEEE.std_logic_1164.all;

    Entity LED_light is

    port ( LED_out : out std_logic);

    end LED_light;

    architecture RTL of LED_light is

    begin

    LED_out<= '1';

    end RTL;
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    It is very easy. Refer to below:

    library IEEE;

    use IEEE.std_logic_1164.all;

    Entity LED_light is

    port ( LED_out : out std_logic);

    end LED_light;

    Architechture RTL of LED_light is

    begin

    LED <= '1';

    end RTL;

    --- Quote End ---

    Hi,

    Do u know how to control the brightness of the output LED in Quartus 2?.

    Ex. OFF (Stage1)>Dim (Stage2)>Full brightness (Stage3). I just need the logic, no need to type the full code here. Any help would be appreciated.

    Thanks,

    Anish