vhdl语言:如何将正弦信号的数字数据输入到wm8731并通过示波器测得正弦波? 300C
  • 我已经将正弦信号的数字部分编好 这部分代码有3个功能:1. 输出不同频率的信号 2.人为控制输出有限周期的信号 3.可以输出正弦波和三角波 详细问题:一个信号可以通过wm8731里的DA-转换器将数字信号转换成模拟信号,但是我怎么用vhdl语言去调用wm8731将并行的数字信号的数据输入到wm8731里面去 ``` entity generator_gai is port( clk,reset,zustand: in bit; --clk: 50MHz,PIN_L1; reset:SW9,PIN_L2; -- zustand: SW8,PIN_M1, Um zwischen die Sinussignal und Dreiecksignal zu wechseln. Zustand = 1: Dreiecksignal; Zustand = 0: Sinussignal; key: in bit_vector(3 downto 0); --Die Frequenz der Signal wird durch Switches von 0 bis 9999 Hz eingestellt. Spg: out integer range 256 downto 0; -- Spg: die Spannungswert der Signal Schalter: in bit_vector(7 downto 0); -- Die Zahl der Ausgabe der Signal wird durch Switches eingestellt. R: out bit; -- Ausgang der Rechtecksignal eine: out bit_vector(6 downto 0); -- Beispiel: 9876: za=6, zehn=7, hundert=8, tausend=9. Die 4 Ausgangen bedeuten, dass der Wert auf der 7-Segment dargestellt wird. zehn: out bit_vector(6 downto 0); hundert: out bit_vector(6 downto 0); tausend: out bit_vector(6 downto 0)); end generator_gai;

architecture structure of generator_gai is
signal cnt,cnt_folge,f_divide: integer range 50000000 downto 0; -- f_divide: frequenz-divide, Man möchte eine Frequenz bestimmen, muss man die Count beschränkt.
signal f_divide_halbe: integer range 25000000 downto 0;
signal sw0,sw1,sw2,sw3,sw4,sw5,sw6,sw7,sw_ges: integer range 512 downto 0; -- diese Parameter bedeuten den Wert der Schalter. a: die 1.Schalter und bedeutet 0 und 1. b: die 2.Schalter und bedeutet 0 und 2.......
signal clk1,Swg_clk: bit;-- clk1:Frequenz der Signal. Swg_clk: wenn man möchte die Taste benutzen, muss man die Schwingung beseitigen. Deshalb kann man mit der Periode sichern, dass die Tastt schon gedrückt wird.
signal Swg_cnt,Swg_cnt_folge: integer range 10000 downto 0; -- Count zum Vermeiden der Schwingung
signal key0_count,key0_count_folge,key1_count,key1_count_folge,key2_count,key2_count_folge,key3_count,key3_count_folge,clk1_count: integer range 5000000 downto 0;
signal clk1_count_folge: integer range 5000001 downto 0;
signal eine1,zehn1,hundert1,tausend1: integer range 10 downto 0; -- Die Wert der Frequenz
signal num,num_folge: integer range 255 downto 0;-- num: sie ist die Abszisse(X-wert).
signal periode,periode_folge: integer range 0 to 255; -- Die Anzahl der Ausgabe des Signals
signal key0,key0_folge: integer range 10 downto 0; -- Die Werte der Frequenz des Signals
signal key1,key1_folge: integer range 100 downto 0;

signal key2,key2_folge: integer range 1000 downto 0;
signal key3,key3_folge,key_ges: integer range 10000 downto 0;

begin
Z_Speicher:process(clk)
begin
if reset = '1' then
periode <= 1;
elsif clk = '1' and clk'event then
cnt <= cnt_folge; Swg_cnt <= Swg_cnt_folge; key0_count <= key0_count_folge; key1_count <= key1_count_folge;
key2_count <= key2_count_folge; key3_count <= key3_count_folge; key0 <= key0_folge; key1 <= key1_folge;
key2 <= key2_folge; key3 <= key3_folge; clk1_count <= clk1_count_folge; periode <= periode_folge;
end if;
if reset = '1' then
num <= 255;
elsif clk1 = '1' and clk1'event then
num <= num_folge;
end if;
end process Z_Speicher;

UE_SN:process(cnt,Swg_clk,key,reset)
begin
if cnt >= f_divide then
cnt_folge <= 0;
else
cnt_folge <= cnt + 1;
end if;
if Schalter(0) = '1' then
sw0 <= 1;
else
sw0 <= 0;
end if;
if Schalter(1) = '1' then
sw1 <= 2;
else
sw1 <= 0;
end if;
if Schalter(2) = '1' then
sw2 <= 4;
else
sw2 <= 0;
end if;
if Schalter(3) = '1' then
sw3 <= 8;
else
sw3 <= 0;
end if;
if Schalter(4) = '1' then
sw4 <= 16;
else
sw4 <= 0;
end if;
if Schalter(5) = '1' then
sw5 <= 32;
else
sw5 <= 0;
end if;
if Schalter(6) = '1' then
sw6 <= 64;
else
sw6 <= 0;
end if;
if Schalter(7) = '1' then
sw7 <= 128;
else
sw7 <= 0;
end if;
sw_ges <= sw0 + sw1 + sw2 + sw3 + sw4 + sw5 + sw6 + sw7;

if Swg_cnt >= 10000 then -- Festfrequenz 5kHz: 200us;
Swg_cnt_folge <= 0;
else
Swg_cnt_folge <= Swg_cnt + 1;
end if;

if reset = '1' then
key0_folge <= 0; key1_folge <= 0; key2_folge <= 0; key3_folge <= 0;

elsif clk = '1' and clk'event then
if clk1 = '1' then

clk1_count_folge <= clk1_count + 1; -- Das Signal kommt viele Peak auf dem Anfangsplatz aus. Deshalb muss man diese Peak vermeiden.
else
if clk1_count > 20 then
clk1_count_folge <= 0;
if num >= 255 then
periode_folge <= periode + 1;
if sw_ges = 128 then -- Wenn SW7(Schalter(7)) = 1, dann läuft das Signal immer.
num_folge <= 0;
else
if sw_ges >= periode then
num_folge <= 0;

        else 
          num_folge <= 255;
            periode_folge <= sw_ges + 1;
        end if;
      end if;
  else
    num_folge <= num + 1;
  end if; 
else
    clk1_count_folge <= 0;
end if;

end if;
if key(0) = '0' then
key0_count_folge <= key0_count + 1;
else
if key0_count > 500000 then -- Wenn man ein Key drücken, soll man die Schwingung vermeiden.
key0_count_folge <= 0;
if key0 < 9 then
key0_folge <= key0 + 1;
else
key0_folge <= 0;
end if;
else
key0_count_folge <= 0;
end if;
end if;
if key(1) = '0' then
key1_count_folge <= key1_count + 1;
else
if key1_count > 500000 then
key1_count_folge <= 0;
if key1 < 90 then
key1_folge <= key1 + 10;
else
key1_folge <= 0;
end if;
else
key1_count_folge <= 0;
end if;
end if;
if key(2) = '0' then
key2_count_folge <= key2_count + 1;
else
if key2_count > 500000 then
key2_count_folge <= 0;
if key2 < 900 then
key2_folge <= key2 + 100;
else
key2_folge <= 0;
end if;
else
key2_count_folge <= 0;
end if;
end if;
if key(3) = '0' then
key3_count_folge <= key3_count + 1;
else
if key3_count > 500000 then
key3_count_folge <= 0;
if key3 < 9000 then
key3_folge <= key3 + 1000;
else
key3_folge <= 0;
end if;
else
key3_count_folge <= 0;
end if;
end if;
end if;
if key0 = 0 and key1 = 0 and key2 = 0 and key3 = 0 then
f_divide <= 0;
else
f_divide <= 50000000/(key0 + key1 + key2 + key3);
end if;
eine1 <= key0;
zehn1 <= key1/10;
hundert1 <= key2/100;
tausend1 <= key3/1000;
end process UE_SN;

AUS_SN:process(eine1,zehn1,hundert1,tausend1,cnt)
begin
case eine1 is when 0 => eine <= "1000000"; -- Die Binärcode des Nummer für 7-Segment
when 1 => eine <= "1111001";
when 2 => eine <= "0100100";
when 3 => eine <= "0110000";
when 4 => eine <= "0011001";
when 5 => eine <= "0010010";
when 6 => eine <= "0000011";
when 7 => eine <= "1111000";
when 8 => eine <= "0000000";
when others => eine <= "0011000";
end case;
case zehn1 is when 0 => zehn <= "1000000";
when 1 => zehn <= "1111001";
when 2 => zehn <= "0100100";
when 3 => zehn <= "0110000";
when 4 => zehn <= "0011001";
when 5 => zehn <= "0010010";
when 6 => zehn <= "0000011";
when 7 => zehn <= "1111000";
when 8 => zehn <= "0000000";
when others => zehn <= "0011000";
end case;
case hundert1 is when 0 => hundert <= "1000000";
when 1 => hundert <= "1111001";
when 2 => hundert <= "0100100";
when 3 => hundert <= "0110000";
when 4 => hundert <= "0011001";
when 5 => hundert <= "0010010";
when 6 => hundert <= "0000011";
when 7 => hundert <= "1111000";
when 8 => hundert <= "0000000";
when others => hundert <= "0011000";
end case;
case tausend1 is when 0 => tausend <= "1000000";
when 1 => tausend <= "1111001";
when 2 => tausend <= "0100100";
when 3 => tausend <= "0110000";
when 4 => tausend <= "0011001";
when 5 => tausend <= "0010010";
when 6 => tausend <= "0000011";
when 7 => tausend <= "1111000";
when 8 => tausend <= "0000000";
when others => tausend <= "0011000";
end case;
if Swg_cnt >= 5000 then
Swg_clk <= '1';
else
Swg_clk <= '0';
end if;
if cnt >= f_divide/2 then
clk1 <= '1';
else
clk1 <= '0';
end if;
R <= clk1;
if zustand = '1' then
case num is when 0 => Spg <= 64; when 33 => Spg <= 97; when 66 => Spg <= 126; when 99 => Spg <= 93;
when 1 => Spg <= 65; when 34 => Spg <= 98; when 67 => Spg <= 125; when 100 => Spg <= 92;
when 2 => Spg <= 66; when 35 => Spg <= 99; when 68 => Spg <= 124; when 101 => Spg <= 91;
when 3 => Spg <= 67; when 36 => Spg <= 100; when 69 => Spg <= 123; when 102 => Spg <= 90;
when 4 => Spg <= 68; when 37 => Spg <= 101; when 70 => Spg <= 122; when 103 => Spg <= 89;
when 5 => Spg <= 69; when 38 => Spg <= 102; when 71 => Spg <= 121; when 104 => Spg <= 88;
when 6 => Spg <= 70; when 39 => Spg <= 103; when 72 => Spg <= 120; when 105 => Spg <= 87;
when 7 => Spg <= 71; when 40 => Spg <= 104; when 73 => Spg <= 119; when 106 => Spg <= 86;
when 8 => Spg <= 72; when 41 => Spg <= 105; when 74 => Spg <= 118; when 107 => Spg <= 85;
when 9 => Spg <= 73; when 42 => Spg <= 106; when 75 => Spg <= 117; when 108 => Spg <= 84;
when 10 => Spg <= 74; when 43 => Spg <= 107; when 76 => Spg <= 116; when 109 => Spg <= 83;
when 11 => Spg <= 75; when 44 => Spg <= 108; when 77 => Spg <= 115; when 110 => Spg <= 82;
when 12 => Spg <= 76; when 45 => Spg <= 109; when 78 => Spg <= 114; when 111 => Spg <= 81;
when 13 => Spg <= 77; when 46 => Spg <= 110; when 79 => Spg <= 113; when 112 => Spg <= 80;
when 14 => Spg <= 78; when 47 => Spg <= 111; when 80 => Spg <= 112; when 113 => Spg <= 79;
when 15 => Spg <= 79; when 48 => Spg <= 112; when 81 => Spg <= 111; when 114 => Spg <= 78;
when 16 => Spg <= 80; when 49 => Spg <= 113; when 82 => Spg <= 110; when 115 => Spg <= 77;
when 17 => Spg <= 81; when 50 => Spg <= 114; when 83 => Spg <= 109; when 116 => Spg <= 76;
when 18 => Spg <= 82; when 51 => Spg <= 115; when 84 => Spg <= 108; when 117 => Spg <= 75;
when 19 => Spg <= 83; when 52 => Spg <= 116; when 85 => Spg <= 107; when 118 => Spg <= 74;
when 20 => Spg <= 84; when 53 => Spg <= 117; when 86 => Spg <= 106; when 119 => Spg <= 73;
when 21 => Spg <= 85; when 54 => Spg <= 118; when 87 => Spg <= 105; when 120 => Spg <= 72;
when 22 => Spg <= 86; when 55 => Spg <= 119; when 88 => Spg <= 104; when 121 => Spg <= 71;
when 23 => Spg <= 87; when 56 => Spg <= 120; when 89 => Spg <= 103; when 122 => Spg <= 70;
when 24 => Spg <= 88; when 57 => Spg <= 121; when 90 => Spg <= 102; when 123 => Spg <= 69;
when 25 => Spg <= 89; when 58 => Spg <= 122; when 91 => Spg <= 101; when 124 => Spg <= 68;
when 26 => Spg <= 90; when 59 => Spg <= 123; when 92 => Spg <= 100; when 125 => Spg <= 67;
when 27 => Spg <= 91; when 60 => Spg <= 124; when 93 => Spg <= 99; when 126 => Spg <= 66;
when 28 => Spg <= 92; when 61 => Spg <= 125; when 94 => Spg <= 98; when 127 => Spg <= 65;
when 29 => Spg <= 93; when 62 => Spg <= 126; when 95 => Spg <= 97; when 128 => Spg <= 64;
when 30 => Spg <= 94; when 63 => Spg <= 127; when 96 => Spg <= 96; when 129 => Spg <= 63;
when 31 => Spg <= 95; when 64 => Spg <= 128; when 97 => Spg <= 95; when 130 => Spg <= 62;
when 32 => Spg <= 96; when 65 => Spg <= 127; when 98 => Spg <= 94; when 131 => Spg <= 61;

              when 132 => Spg <= 60; when 162 => Spg <= 30; when 192 => Spg <= 0; when 222 => Spg <= 30;
              when 133 => Spg <= 59; when 163 => Spg <= 29; when 193 => Spg <= 1; when 223 => Spg <= 31;
              when 134 => Spg <= 58; when 164 => Spg <= 28; when 194 => Spg <= 2; when 224 => Spg <= 32;
              when 135 => Spg <= 57; when 165 => Spg <= 27; when 195 => Spg <= 3; when 225 => Spg <= 33;
              when 136 => Spg <= 56; when 166 => Spg <= 26; when 196 => Spg <= 4; when 226 => Spg <= 34;
              when 137 => Spg <= 55; when 167 => Spg <= 25; when 197 => Spg <= 5; when 227 => Spg <= 35;
              when 138 => Spg <= 54; when 168 => Spg <= 24; when 198 => Spg <= 6; when 228 => Spg <= 36;
              when 139 => Spg <= 53; when 169 => Spg <= 23; when 199 => Spg <= 7; when 229 => Spg <= 37;
              when 140 => Spg <= 52; when 170 => Spg <= 22; when 200 => Spg <= 8; when 230 => Spg <= 38;
             when 141 => Spg <= 51; when 171 => Spg <= 21; when 201 => Spg <= 9; when 231 => Spg <= 39;
              when 142 => Spg <= 50; when 172 => Spg <= 20; when 202 => Spg <= 10; when 232 => Spg <= 40;
              when 143 => Spg <= 49; when 173 => Spg <= 19; when 203 => Spg <= 11; when 233 => Spg <= 41;
              when 144 => Spg <= 48; when 174 => Spg <= 18; when 204 => Spg <= 12; when 234 => Spg <= 42;
              when 145 => Spg <= 47; when 175 => Spg <= 17; when 205 => Spg <= 13; when 235 => Spg <= 43;
              when 146 => Spg <= 46; when 176 => Spg <= 16; when 206 => Spg <= 14; when 236 => Spg <= 44;
             when 147 => Spg <= 45; when 177 => Spg <= 15; when 207 => Spg <= 15; when 237 => Spg <= 45;
              when 148 => Spg <= 44; when 178 => Spg <= 14; when 208 => Spg <= 16; when 238 => Spg <= 46;
              when 149 => Spg <= 43; when 179 => Spg <= 13; when 209 => Spg <= 17; when 239 => Spg <= 47;
              when 150 => Spg <= 42; when 180 => Spg <= 12; when 210 => Spg <= 18; when 240 => Spg <= 48;
              when 151 => Spg <= 41; when 181 => Spg <= 11; when 211 => Spg <= 19; when 241 => Spg <= 49;                
              when 152 => Spg <= 40; when 182 => Spg <= 10; when 212 => Spg <= 20; when 242 => Spg <= 50;
             when 153 => Spg <= 39; when 183 => Spg <= 9; when 213 => Spg <= 21; when 243 => Spg <= 51;
              when 154 => Spg <= 38; when 184 => Spg <= 8; when 214 => Spg <= 22; when 244 => Spg <= 52;
              when 155 => Spg <= 37; when 185 => Spg <= 7; when 215 => Spg <= 23; when 245 => Spg <= 53;
              when 156 => Spg <= 36; when 186 => Spg <= 6; when 216 => Spg <= 24; when 246 => Spg <= 54;
              when 157 => Spg <= 35; when 187 => Spg <= 5; when 217 => Spg <= 25; when 247 => Spg <= 55;
              when 158 => Spg <= 34; when 188 => Spg <= 4; when 218 => Spg <= 26; when 248 => Spg <= 56;
              when 159 => Spg <= 33; when 189 => Spg <= 3; when 219 => Spg <= 27; when 249 => Spg <= 57;
              when 160 => Spg <= 32; when 190 => Spg <= 2; when 220 => Spg <= 28; when 250 => Spg <= 58;
              when 161 => Spg <= 31; when 191 => Spg <= 1; when 221 => Spg <= 29; when 251 => Spg <= 59;

              when 252 => Spg <= 60; when 253 => Spg <= 61; when 254 => Spg <= 62; when 255 => Spg <= 63;                 
              end case;

elsif zustand = '0' then
case num is when 0 => Spg <= 128; when 33 => Spg <= 221; when 66 => Spg <= 256; when 99 => Spg <= 212;
when 1 => Spg <= 131; when 34 => Spg <= 223; when 67 => Spg <= 256; when 100 => Spg <= 209;
when 2 => Spg <= 134; when 35 => Spg <= 225; when 68 => Spg <= 255; when 101 => Spg <= 207;
when 3 => Spg <= 137; when 36 => Spg <= 227; when 69 => Spg <= 255; when 102 => Spg <= 204;
when 4 => Spg <= 141; when 37 => Spg <= 229; when 70 => Spg <= 255; when 103 => Spg <= 202;
when 5 => Spg <= 144; when 38 => Spg <= 231; when 71 => Spg <= 254; when 104 => Spg <= 199;
when 6 => Spg <= 147; when 39 => Spg <= 233; when 72 => Spg <= 254; when 105 => Spg <= 196;
when 7 => Spg <= 150; when 40 => Spg <= 234; when 73 => Spg <= 253; when 106 => Spg <= 194;
when 8 => Spg <= 153; when 41 => Spg <= 236; when 74 => Spg <= 252; when 107 => Spg <= 191;
when 9 => Spg <= 156; when 42 => Spg <= 238; when 75 => Spg <= 251; when 108 => Spg <= 188;
when 10 => Spg <= 159; when 43 => Spg <= 239; when 76 => Spg <= 250; when 109 => Spg <= 186;
when 11 => Spg <= 162; when 44 => Spg <= 241; when 77 => Spg <= 250; when 110 => Spg <= 183;
when 12 => Spg <= 165; when 45 => Spg <= 242; when 78 => Spg <= 249; when 111 => Spg <= 180;
when 13 => Spg <= 168; when 46 => Spg <= 244; when 79 => Spg <= 247; when 112 => Spg <= 177;
when 14 => Spg <= 171; when 47 => Spg <= 245; when 80 => Spg <= 246; when 113 => Spg <= 174;
when 15 => Spg <= 174; when 48 => Spg <= 246; when 81 => Spg <= 245; when 114 => Spg <= 171;
when 16 => Spg <= 177; when 49 => Spg <= 247; when 82 => Spg <= 244; when 115 => Spg <= 168;
when 17 => Spg <= 180; when 50 => Spg <= 249; when 83 => Spg <= 242; when 116 => Spg <= 165;
when 18 => Spg <= 183; when 51 => Spg <= 250; when 84 => Spg <= 241; when 117 => Spg <= 162;
when 19 => Spg <= 186; when 52 => Spg <= 250; when 85 => Spg <= 239; when 118 => Spg <= 159;
when 20 => Spg <= 188; when 53 => Spg <= 251; when 86 => Spg <= 238; when 119 => Spg <= 156;
when 21 => Spg <= 191; when 54 => Spg <= 252; when 87 => Spg <= 236; when 120 => Spg <= 153;
when 22 => Spg <= 194; when 55 => Spg <= 253; when 88 => Spg <= 234; when 121 => Spg <= 150;
when 23 => Spg <= 196; when 56 => Spg <= 254; when 89 => Spg <= 233; when 122 => Spg <= 147;
when 24 => Spg <= 199; when 57 => Spg <= 254; when 90 => Spg <= 231; when 123 => Spg <= 144;
when 25 => Spg <= 202; when 58 => Spg <= 255; when 91 => Spg <= 229; when 124 => Spg <= 141;
when 26 => Spg <= 204; when 59 => Spg <= 255; when 92 => Spg <= 227; when 125 => Spg <= 137;
when 27 => Spg <= 207; when 60 => Spg <= 255; when 93 => Spg <= 225; when 126 => Spg <= 134;
when 28 => Spg <= 209; when 61 => Spg <= 256; when 94 => Spg <= 223; when 127 => Spg <= 131;
when 29 => Spg <= 212; when 62 => Spg <= 256; when 95 => Spg <= 221; when 128 => Spg <= 128;
when 30 => Spg <= 214; when 63 => Spg <= 256; when 96 => Spg <= 219; when 129 => Spg <= 125;
when 31 => Spg <= 216; when 64 => Spg <= 256; when 97 => Spg <= 216; when 130 => Spg <= 122;
when 32 => Spg <= 219; when 65 => Spg <= 256; when 98 => Spg <= 214; when 131 => Spg <= 119;

            when 132 => Spg <= 115; when 162 => Spg <= 33; when 192 => Spg <= 0; when 222 => Spg <= 33;
            when 133 => Spg <= 112; when 163 => Spg <= 31; when 193 => Spg <= 0; when 223 => Spg <= 35;
            when 134 => Spg <= 109; when 164 => Spg <= 29; when 194 => Spg <= 0; when 224 => Spg <= 37;
            when 135 => Spg <= 106; when 165 => Spg <= 27; when 195 => Spg <= 0; when 225 => Spg <= 40;
            when 136 => Spg <= 103; when 166 => Spg <= 25; when 196 => Spg <= 1; when 226 => Spg <= 42;
            when 137 => Spg <= 100; when 167 => Spg <= 23; when 197 => Spg <= 1; when 227 => Spg <= 44;
            when 138 => Spg <= 97; when 168 => Spg <= 22; when 198 => Spg <= 1; when 228 => Spg <= 47;
            when 139 => Spg <= 94; when 169 => Spg <= 20; when 199 => Spg <= 2; when 229 => Spg <= 49;
            when 140 => Spg <= 91; when 170 => Spg <= 18; when 200 => Spg <= 2; when 230 => Spg <= 52;
           when 141 => Spg <= 88; when 171 => Spg <= 17; when 201 => Spg <= 3; when 231 => Spg <= 54;
            when 142 => Spg <= 85; when 172 => Spg <= 15; when 202 => Spg <= 4; when 232 => Spg <= 57;
            when 143 => Spg <= 82; when 173 => Spg <= 14; when 203 => Spg <= 5; when 233 => Spg <= 60;
            when 144 => Spg <= 79; when 174 => Spg <= 12; when 204 => Spg <= 6; when 234 => Spg <= 62;
            when 145 => Spg <= 76; when 175 => Spg <= 11; when 205 => Spg <= 6; when 235 => Spg <= 65;
            when 146 => Spg <= 73; when 176 => Spg <= 10; when 206 => Spg <= 7; when 236 => Spg <= 68;
           when 147 => Spg <= 70; when 177 => Spg <= 9; when 207 => Spg <= 9; when 237 => Spg <= 70;
            when 148 => Spg <= 68; when 178 => Spg <= 7; when 208 => Spg <= 10; when 238 => Spg <= 73;
            when 149 => Spg <= 65; when 179 => Spg <= 6; when 209 => Spg <= 11; when 239 => Spg <= 76;
            when 150 => Spg <= 62; when 180 => Spg <= 6; when 210 => Spg <= 12; when 240 => Spg <= 79;
            when 151 => Spg <= 60; when 181 => Spg <= 5; when 211 => Spg <= 14; when 241 => Spg <= 82;               
            when 152 => Spg <= 57; when 182 => Spg <= 4; when 212 => Spg <= 15; when 242 => Spg <= 85;
           when 153 => Spg <= 54; when 183 => Spg <= 3; when 213 => Spg <= 17; when 243 => Spg <= 88;
            when 154 => Spg <= 52; when 184 => Spg <= 2; when 214 => Spg <= 18; when 244 => Spg <= 91;
            when 155 => Spg <= 49; when 185 => Spg <= 2; when 215 => Spg <= 20; when 245 => Spg <= 94;
            when 156 => Spg <= 47; when 186 => Spg <= 1; when 216 => Spg <= 22; when 246 => Spg <= 97;
            when 157 => Spg <= 44; when 187 => Spg <= 1; when 217 => Spg <= 23; when 247 => Spg <= 100;
            when 158 => Spg <= 42; when 188 => Spg <= 1; when 218 => Spg <= 25; when 248 => Spg <= 103;
            when 159 => Spg <= 40; when 189 => Spg <= 0; when 219 => Spg <= 27; when 249 => Spg <= 106;
            when 160 => Spg <= 37; when 190 => Spg <= 0; when 220 => Spg <= 29; when 250 => Spg <= 109;
            when 161 => Spg <= 35; when 191 => Spg <= 0; when 221 => Spg <= 31; when 251 => Spg <= 112;

            when 252 => Spg <= 115; when 253 => Spg <= 119; when 254 => Spg <= 122; when 255 => Spg <= 128;               
            end case;

end if;
end process AUS_SN;

end structure;

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
vhdl语言如何设计图像处理系统
-
VHDL错误:Error (10500): VHDL syntax error at adff.vhd(16) near text "process"; expecting "if"
-
VHDL在testbench里的二进制变量循环+1
-
VHDL语言中关于运算符
-
密码锁,关于eda语言的vhdl
-
VHDL 语言三位计数器
-
用VHDL或Verilog语言设计RS232接口数据转发协议
-
vhdl语言SIGNAL i : integer range 0 to 31;
-
求一个vhdl语言写的键盘防抖程序
-
vhdl点阵只亮一个,无法扫描?
-
用vhdl语言设计一个11分频电路
-
求大神VHDL数字时钟设计 所有的源程序 编译和仿真
-
用vhdl实现0到15平方运算。
-
急~关于VHDL串口驱动的问题
-
可控脉冲发生器(用vhdl语言编写)
-
求基于VHDL的16QAM调制解调设计代码?
-
用vhdl语言设计(7,4)循环码
-
vhdl编译时显示已使用但未定义
-
8255VHDL语言波形问题
-
Linux文件操作高频使用命令
文章目录0.新建操作:1.查看操作2.删除操作3.复制操作4.移动操作:5.重命名操作:6.解压压缩操作 0.新建操作: mkdir abc #新建一个文件夹 touch abc.sh #新建一个文件 1.查看操作 查看目录: ll #显示目录文件详细信息 查看文件内容: cat|head|tail命令 cat abc.txt #查看abc的内容 head -5 abc.txt #...
程序员实用工具网站
目录 1、搜索引擎 2、PPT 3、图片操作 4、文件共享 5、应届生招聘 6、程序员面试题库 7、办公、开发软件 8、高清图片、视频素材网站 9、项目开源 10、算法 11、在线工具宝典大全 程序员开发需要具备良好的信息检索能力,为了备忘(收藏夹真是满了),将开发过程中常用的网站进行整理。 1、搜索引擎 1.1、秘迹搜索 一款无敌有良心、无敌安全的搜索引擎,不会收...
史上最详细的IDEA优雅整合Maven+SSM框架(详细思路+附带源码)
网上很多整合SSM博客文章并不能让初探ssm的同学思路完全的清晰,可以试着关掉整合教程,摇两下头骨,哈一大口气,就在万事具备的时候,开整,这个时候你可能思路全无 ~中招了咩~ ,还有一些同学依旧在使用eclipse或者Myeclipse开发,我想对这些朋友说IDEA 的编译速度很快,人生苦短,来不及解释了,直接上手idea吧。这篇文章每一步搭建过程都测试过了,应该不会有什么差错。本文章还有个比较优秀的特点,就是idea的使用,基本上关于idea的操作都算是比较详细的,所以不用太担心不会撸idea!最后,本文
我花了一夜用数据结构给女朋友写个H5走迷宫游戏
起因 又到深夜了,我按照以往在csdn和公众号写着数据结构!这占用了我大量的时间!我的超越妹妹严重缺乏陪伴而 怨气满满! 而女朋友时常埋怨,认为数据结构这么抽象难懂的东西没啥作用,常会问道:天天写这玩意,有啥作用。而我答道:能干事情多了,比如写个迷宫小游戏啥的! 当我码完字准备睡觉时:写不好别睡觉! 分析 如果用数据结构与算法造出东西来呢? ...
BMP、GIF、TIFF、PNG、JPG和SVG格式图像的特点
目录 1、BMP格式图像 2、GIF格式图像 3、TIFF格式图像 4、PNG格式图像 5、JPG格式图像 6、SVG格式图像 7、总结 7.1、有损vs无损 7.2、索引色vs直接色 7.3、点阵图vs矢量图 7.4、总结 一张图片可以储存为多种格式,为什么有的几十KB,有的几百MB,有的静止不动,有的是好几个画面循环播放?在项目开发的过程中经常会读取或保存图像...
高级软件工程师教会我的那些事儿
【CSDN编者按】以人为鉴,可明得失。对于新手程序员来说,面对复杂的开发需求很容易因为经验不足或技术不够娴熟等原因而踩坑。本文的作者表示:坐在高级软件工程师旁边工作或许可以事半功倍!长达一年的观察学习,他收获了包括编写代码、测试、设计、部署以及监控的一系列的长足进步。 声明:本文已获作者翻译授权,原文(https://neilkakkar.com/things-I-learnt-from-...
nginx学习,看这一篇就够了:下载、安装。使用:正向代理、反向代理、负载均衡。常用命令和配置文件
文章目录前言一、nginx简介1. 什么是 nginx 和可以做什么事情2.Nginx 作为 web 服务器3. 正向代理4. 反向代理5. 动静分离6.动静分离二、Nginx 的安装三、 Nginx 的常用命令和配置文件四、 Nginx 配置实例 1 反向代理五、 Nginx 配置实例 2 负载均衡六、 Nginx 配置实例 3 动静分离七、 Nginx 的高可用集群 前言 一、nginx简介...
MySQL数据库—SQL汇总
一、准备 下文整理常见SQL语句的用法,使用MySQL5.7测试,参考了尚硅谷MySQL教程及用例。用例sql: 链接: https://pan.baidu.com/s/1tb3-12MRNFjV8drFlN6wzg&amp;shfl=sharepset 密码: fc2h 为了方便查阅可从右侧目录快速索引 二、DQL(Data Query Language)数据查询语言 1、语句顺序 书写顺序...
黑客入门,从HTB开始
Hack the box 是国外的一个靶机平台,里面的靶机包含多种系统类型,并且里面可以利用的漏洞类型多种多样,有很多靶机其实非常贴近实战情景。因此 HTB 是一个很好的学习渗透测试靶场。 之前在 HTB 也玩过一些机器。里面的机器难度有好几个档次,insane 难度的一般都是极其困难的,这种机器一般让我对着大神的 Writeup 我可能都没有办法复现出来。之前也有在公众号上分享过几篇 H...
动画:用动画给女朋友讲解 TCP 四次分手过程
作者 | 小鹿 来源 | 公众号:小鹿动画学编程 写在前边 大家好,我们又见面了,做为一个业余的动画师,上次的用动画的形式讲解 TCP 三次握手过程再各大平台收到了广大读者的喜爱,说文章有趣、有货、有内容,也受到了很多读者的关注。很多读者留言说什么时候用动画讲一讲 TCP 四次挥手的过程,为了应大家的要求,今天我们就生动有趣的用动画给大家分享 TCP 四次挥手(分手)过程。 动画:用动画给...
程序员必须掌握的核心算法有哪些?
由于我之前一直强调数据结构以及算法学习的重要性,所以就有一些读者经常问我,数据结构与算法应该要学习到哪个程度呢?,说实话,这个问题我不知道要怎么回答你,主要取决于你想学习到哪些程度,不过针对这个问题,我稍微总结一下我学过的算法知识点,以及我觉得值得学习的算法。这些算法与数据结构的学习大多数是零散的,并没有一本把他们全部覆盖的书籍。下面是我觉得值得学习的一些算法以及数据结构,当然,我也会整理一些看过...
SQL基本语法入门 看这里就够了
SQL执行顺序 第一步:执行FROM 第二步:WHERE条件过滤 第三步:GROUP BY 分组 第四步:执行SELECT 投影列 第五步:HAVING条件过滤 第六步:执行ORDER BY排序 一、创建、删除库 -- 创建新数据库 CREATE DATABASE 数据库名; -- 删除数据库 DROP DATABASE 数据库名; 二、增加 1、添加列名、设置主键、设...
如何优化MySQL千万级大表,我写了6000字的解读
这是学习笔记的第2138篇文章 千万级大表如何优化,这是一个很有技术含量的问题,通常我们的直觉思维都会跳转到拆分或者数据分区,在此我想做一些补充和梳理,想和大家做一些这方面的经验总结,也欢迎大家提出建议。 从一开始脑海里开始也是火光四现,到不断的自我批评,后来也参考了一些团队的经验,我整理了下面的大纲内容。 既然要吃透这个问题,我们势必要回到本源,我把这个...
面试最后一问:你有什么问题想问我吗?
尽管,我们之前分享了这么多关于面试的主题: 高薪必备的一些Spring Boot高级面试题 面试必问:设计模式遵循的面向对象设计原则! 面试必问:怎么保证缓存与数据库的双写一致性? 27道高频Spring面试题,你能答对几个? 唠唠面试常问的:面向对象六大原则 一文高效图解二叉树面试题 Java面试中最高频的那20%知识点是什么? 百度面试题:求数组最大值 ... 然而,最后这个90%可见...
python 程序员进阶之路:从新手到高手的100个模块
在知乎和CSDN的圈子里,经常看到、听到一些 python 初学者说,学完基础语法后,不知道该学什么,学了也不知道怎么用,一脸的茫然。近日,CSDN的公众号推送了一篇博客,题目叫做《迷思:Python 学到什么程度可以面试工作?》,真实反映了 python 程序员在成长过程中的一些困惑。
Python——画一棵漂亮的樱花树(不同种樱花+玫瑰+圣诞树喔)
最近翻到一篇知乎,上面有不少用Python(大多是turtle库)绘制的树图,感觉很漂亮,我整理了一下,挑了一些我觉得不错的代码分享给大家(这些我都测试过,确实可以生成) one 樱花树 动态生成樱花 效果图(这个是动态的): 实现代码 import turtle as T import random import time # 画樱花的躯干(60,t) def Tree(branch, ...
Linux/C/C++ 不可错过的好书
来源:公众号【编程珠玑】 作者:守望先生 ID:shouwangxiansheng 前言 经常有读者让我推荐书籍,这次我就把我私藏的计算机书单分享给你们!不过由于时间匆忙,不会进行更加详细的介绍。 声明 由于每个人的情况不一样,推荐的书并不一定适合你,也不一定适合当前阶段的你,有的书籍可能存在内容重复,所以根据自己的阶段情况进行选择即可。虽说如此,以下书单中提单的书均为优质书籍。...
计算机处理器基础原理笔记
一、CPU指令电路 1. 计算机每执行一条指令的过程,可以分解成这样几个步骤。 (1)Fetch(取得指令),也就是从PC寄存器里找到对应的指令地址,根据指令地址从内存里把具体的指令,加载到指令寄存器中,然后把PC寄存器自增,在未来执行下一条指令。 (2)Decode(指令译码),也就是根据指令寄存器里面的指令,解析成要进行什么样的操作,是MIPS指令集的R、I、J中哪一种指令,具体要操作哪...
单点登录(SSO)
一、SSO(单点登录)介绍 SSO英文全称Single SignOn,单点登录。SSO是在多个应用系统中,用户只需要登录一次就可以访问所有相互信任的应用系统。它包括可以将这次主要的登录映射到其他应用中用于同一个用户的登录的机制。它是目前比较流行的企业业务整合的解决方案之一。 实现机制 当用户第一次访问应用系统1的时候,因为还没有登录,会被引导到认证系统中进行登录;根据用户提供的登录信息,认证...
漫话:什么是 https ?这应该是全网把 https 讲的最好的一篇文章了
今天这篇文章,讲通过对话的形式,让你由浅入深着知道,为什么 Https 是安全的。 一、对称加密 一禅:在每次发送真实数据之前,服务器先生成一把密钥,然后先把密钥传输给客户端。之后服务器给客户端发送真实数据的时候,会用这把密钥对数据进行加密,客户端收到加密数据之后,用刚才收到的密钥进行解密。如图: 当然,如果客户端要给服务器发送数据,也是采用这把密钥来加密,这里为了方便,我采用单方向...
HTML CSS整理笔记
常见字体单位: 1.em 移动端常用的字体尺寸单位,说白em就相当于“倍”,比如设置当前的div的字体大小为1.5em,则当前的div的字体大小为:当前div继承的字体大小*1.5。 但当div进行嵌套时,em始终按当前div继承的字体大小来缩放。 2.rem r是root的意思,即相对于根节点html的font-size进行缩放,当有嵌套关系时,嵌套关系的元素的字体大小始终按照根节点的字体大小...
相关热词 c# 增加元素 c#控制台简单加法 c# 服务端框架 c# 判断事件是否注册 c#中is和has c# udp 连接超时 c#词典 c#实现排列组合 c# oss 上传 c#判断输入的是否为ip