📄 tonetaba.vhd
字号:
Library ieee;
Use ieee.std_logic_1164.all;
Entity tonetaba is
Port( index : in std_logic_vector(3 downto 0);
code : out std_logic_vector(3 downto 0);
high : out std_logic;
tone : out std_logic_vector(10 downto 0));
End;
Architecture one of tonetaba is
Begin
Search : process(index)
Begin
Case index is
When "0000"=>tone<="11111111111";code<="0000";high<='0';--2047,休止符
When "0001"=>tone<="00110000010";code<="0001";high<='0';--773,低音1
When "0010"=>tone<="01110010000";code<="0010";high<='0';--912,低音2
When "0011"=>tone<="10000001100";code<="0011";high<='0';--1036,低音3,
When "0101"=>tone<="10010101101";code<="0101";high<='0';--1197,低音5
When "0110"=>tone<="10100001010";code<="0110";high<='0';--1290,低音6
When "0111"=>tone<="10101011100";code<="0111";high<='0';--1372,低音7
When "1000"=>tone<="10110000010";code<="1000";high<='1';--1410,中音1
When "1001"=>tone<="10111001000";code<="1001";high<='1';--1480,中音2
When "1010"=>tone<="11000000110";code<="1010";high<='1';--1542,中音3
When "1100"=>tone<="11001010110";code<="1100";high<='1';--1622,中音5
When "1101"=>tone<="11010000100";code<="1101";high<='1';--1668,中音6
When "1111"=>tone<="11011000000";code<="1111";high<='1';--1728,高音1
When others => null;
End case;
End process;
End;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -