User Tools

Site Tools


projects:maps21:s:dcont:code:cpld2:cpld2

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
projects:maps21:s:dcont:code:cpld2:cpld2 [2024/05/09 19:31]
carsten [Erläuterungen]
projects:maps21:s:dcont:code:cpld2:cpld2 [2024/05/12 10:23] (current)
carsten
Line 13: Line 13:
 | **Stroke[4..0]** = Bitstring[4..0] Eingangsvariable 1ms-Takt  ^ c_measurement_range_wl ✔  | = Länge Bitstring der Balkenanzeige = 7  | | **Stroke[4..0]** = Bitstring[4..0] Eingangsvariable 1ms-Takt  ^ c_measurement_range_wl ✔  | = Länge Bitstring der Balkenanzeige = 7  |
 | **Mode[2..0]** = Bitstring Mode[1..0] Eingangsvariable ^ c_num_measurement_ranges ✔  | = Anzahl Messbereich als Integerzahl = 3  | | **Mode[2..0]** = Bitstring Mode[1..0] Eingangsvariable ^ c_num_measurement_ranges ✔  | = Anzahl Messbereich als Integerzahl = 3  |
-| **led_columns(t)**  ^  |  | 
 |  ^ c_period_wl ✔  | = Länge Perioden Bitstring[5..0] = 50  | |  ^ c_period_wl ✔  | = Länge Perioden Bitstring[5..0] = 50  |
 +| **led_columns(t)** = sieben Spalten  ^ c_num_led_columns  | = Anzahl der Spalten[6..0]   |
 +| **led_rows_red(t)** = zehn Zeilen rot  ^  |  |
 +| **led_rows_green(t)** = zehn Zeilen green  ^  |  |
 +| rotary_switch_debounced  ^ c_rotary_switch_wl  | = Länge Kodiererstring = 3  |
 +| rotary_switch_debounced_d1  ^  |  |
 +|  ^  |  |
 +|  ^  |  |
 +|  ^  |  |
 ^ ^^^ ^ ^^^
-| p_drive_led_rows: Prozess LED-Treiber  ||| +<color /#DDFFDD>**p_debounce_and_handle_switches**</color>  ||| 
-p_debounce_and_handle_switches  ||| +| <color /#DDFFDD>**p_count**</color>  ||| 
- +| <color /#DDFFDD>**p_drive_led_rows: Prozess LED-Treiber**</color>  ||| 
 +<color /#DDFFDD>**p_drive_led_columns**</color>  ||| 
 + 
 ===== Code Orginal ===== ===== Code Orginal =====
  
Line 95: Line 105:
  period_cntr <= period_cntr + 1;  period_cntr <= period_cntr + 1;
  end if;  end if;
- -- create blink signal with 1 Hz+ -- create blink signal with 1 Hz: 1 bei 24 0 Priode 49!
  if period_cntr = to_unsigned(c_num_20ms_periods / 2 - 1, c_period_wl) then  if period_cntr = to_unsigned(c_num_20ms_periods / 2 - 1, c_period_wl) then
  blink_signal <= '1';  blink_signal <= '1';
Line 173: Line 183:
  -- debounce switches  -- debounce switches
  for i in 0 to c_rotary_switch_wl - 1 loop  for i in 0 to c_rotary_switch_wl - 1 loop
- debounce_array(i)(0) <= rotary_switch(i);+ debounce_array(i)(0) <= rotary_switch(i); -- Aktuelles Schaltersignal
  for d in 1 to c_debounce_time_ms - 1 loop  for d in 1 to c_debounce_time_ms - 1 loop
- debounce_array(i)(d) <= debounce_array(i)(d - 1);+ debounce_array(i)(d) <= debounce_array(i)(d - 1); --  Schaltergeschichte bis vor 4ms
  end loop;  end loop;
  if debounce_array(i) = (c_debounce_time_ms - 1 downto 0 => '0') then -- check for five consecutive equal signal states  if debounce_array(i) = (c_debounce_time_ms - 1 downto 0 => '0') then -- check for five consecutive equal signal states
projects/maps21/s/dcont/code/cpld2/cpld2.1715275905.txt.gz · Last modified: 2024/05/09 19:31 by carsten