title: " Error (10822): HDL error at pong_game.vhd(350): couldn't implement registers for assignments on this clock edge"
body: <p>I have recently created a pong game in VHDL, the simulation looks pretty and the game behaves well. The game is a 1 vs 1. Each player has a a racket symbolized by two lit leds above and below the led matrix.</p>
  
  <p>The ball is symbolized by lit leds scrolling at the ends of the led matrix and they have to be punched by the rackets displayed by two push buttons ( a left button and a right button for each player).</p>
  
  <p>I'm using a cpld maxII equipped with a 50 Mhz clock. So i divided the frequency to control the scrolling of the leds.</p>
  
  <p>After i have played many games with my little sister (she enjoyed it a lot :D), I decided make it funnier. The idea is to variate the frequency of the scrolling leds after 3,6,9,12,15 pushed balls. When the counter (named cnt_win) is below 3, the scrolling is slow and the frequency is increasing untill the cnt_win reaches 15. When one player fails the counter equals 0 ...</p>
  
  <p>I use many clocks  to variate the frequency and made the game more attracive but it doesn't work due to the error " Error (10822): HDL error at pong_game.vhd(350): couldn't implement registers for assignments on this clock edge".</p>
  
  <pre><code>library ieee;
  use ieee.std_logic_1164.all;
  use IEEE.std_logic_unsigned.all;
  
  
  entity pong_game is 
  
  port(
           d1 : in std_logic; -- right push button player 1
           g1 : in std_logic; -- left  push button player 1
           d2 : in std_logic; -- "               " player 2
           g2 : in std_logic; -- "               " player 2
           clk_50Mhz : in std_logic;
           clk_20hz : buffer std_logic :='0';
           RST : in std_logic;  -- reset button
           leds : buffer std_logic_vector (30 downto 1);
           led_barre_2 : buffer std_logic_vector (5 downto 1):="00011";
           led_barre_1 : buffer std_logic_vector (5 downto 1):="00011"  
           );
  
  end pong_game;
  
  architecture pong_game_arch of pong_game is
  constant position1 : std_logic_vector(5 downto 1) := "00011";
  constant position2 : std_logic_vector(5 downto 1) := "00110";
  constant position3 : std_logic_vector(5 downto 1) := "01100";
  constant position4 : std_logic_vector(5 downto 1) := "11000";
  
  type etat is (led1,led2,led3,led4,led5,led6_1,led7_1_g,led7_1_d,led8_1_g,led8_1_d,led9_1_g,led9_1_d,led10_1,led11_1,led12_1_g,led12_1_d,led13_1_g,led13_1_d,led14_1_g,led14_1_d,led15_1,    
              led16_1,led17_1_g,led17_1_d,led18_1_g,led18_1_d,led19_1_g,led19_1_d,led20_1,led21_1,led22_1_g,led22_1_d,led23_1_g,led23_1_d,led24_1_g,led24_1_d,led25_1,led26,led27,led28,led29,led30,
              led6_2,led7_2_g,led7_2_d,led8_2_g,led8_2_d,led9_2_g,led9_2_d,led10_2,led11_2,led12_2_g,led12_2_d,led13_2_g,led13_2_d,led14_2_g,led14_2_d,led15_2,led16_2,led17_2_g,led17_2_d,led18_2_g,led18_2_d,led19_2_g,led19_2_d,
              led20_2,led21_2,led22_2_g,led22_2_d,led23_2_g,led23_2_d,led24_2_g,led24_2_d,led25_2,        
              led6_init,
              led7_init,
              led8_init,
              led9_init,
              led10_init,
              led11_init_1,
              led11_init_2,
              led12_init_1,
              led12_init_2,
              led13_init_1,
              led13_init_2,
              led14_init_1,
              led14_init_2,
              led15_init_1,
              led15_init_2,        -- Sequence led initiale
              led16_init_1,
              led16_init_2,
              led17_init_1,
              led17_init_2,
              led18_init_1,
              led18_init_2,
              led19_init_1,
              led19_init_2,
              led20_init_1,
              led20_init_2,
              led21_init,
              led22_init,
              led23_init,
              led24_init,
              led25_init,
              all_led_loose_on,
              all_led_loose_off);
  
  signal etat_present, etat_futur : etat :=led11_init_1; -- etat initial
  
  signal cnt : integer range 11 to 20 :=11; -- Permet de choisir quelle led initial
  
  signal cnt1 : integer range 3 downto 0 :=0; -- gère les positions de led_barre_1
  signal cnt2 : integer range 3 downto 0 :=0; -- idem pour led_barre_2
  
  --signal clk_20hz : std_logic :='0'; -- gère les boutons poussoirs gauche-droite
  
  ---------  gère les sequences de leds avec 4 signals d'horloge  -----------
  
  signal clk_0 : std_logic :='0'; -- niveau lent
  signal clk_1 : std_logic :='0'; -- niveau normal    
  signal clk_2 : std_logic :='0'; -- niveau rapide
  signal clk_3 : std_logic :='0'; -- niveau très rapide
  
  
  
  signal cnt_clk_20 : std_logic_vector  (22 downto 1):= (others=&gt;'0');
  signal cnt_clk_0  : std_logic_vector  (25 downto 1):= (others=&gt;'0');
  signal cnt_clk_1  : std_logic_vector  (24 downto 1):= (others=&gt;'0');
  signal cnt_clk_2  : std_logic_vector  (24 downto 1):= (others=&gt;'0');
  signal cnt_clk_3  : std_logic_vector  (24 downto 1):= (others=&gt;'0');
  
  --------------------------------------------------------------------------------
  
  --------  choix binaire des fréquences de défilements --------------------------
  
  constant lent     : std_logic_vector (1 downto 0) :="00";
  constant normal   : std_logic_vector (1 downto 0) :="01";
  constant rapide   : std_logic_vector (1 downto 0) :="10";
  constant rapide_v : std_logic_vector (1 downto 0) :="11";
  
  signal choix      : std_logic_vector (1 downto 0) :=lent;
  
  signal cnt_win    : integer range 15 downto 0 :=0;
  
  begin
  
  diviseur_clk : process(clk_50Mhz)
  
                  begin 
  
                      if rising_edge(clk_50Mhz) then
  
                          if cnt_clk_0 &lt; "1011111010111100001000000" then  --25.000.000
                              cnt_clk_0 &lt;= cnt_clk_0+'1';
                          else
                              clk_0&lt;=not(clk_0);
                              cnt_clk_0&lt;= (others =&gt; '0');
                          end if;
  
                          if cnt_clk_1 &lt; "111001001110000111000000" then  --15.000.000
                              cnt_clk_1&lt;=cnt_clk_1+'1';
                          else
                              clk_1&lt;=not(clk_1);
                              cnt_clk_1&lt;= (others =&gt;'0');
                          end if;
  
                          if cnt_clk_2 &lt; "100110001001011010000000" then  --10.000.000
                              cnt_clk_2&lt;=cnt_clk_2+'1';
                          else
                              clk_2&lt;=not(clk_2);
                              cnt_clk_2&lt;= (others=&gt;'0');
                          end if;
  
                          if cnt_clk_3 &lt; "11100100111000011100000" then  --7.500.000
                              cnt_clk_3 &lt;= cnt_clk_3+'1';
                          else
                              clk_3&lt;=not(clk_3);
                              cnt_clk_3&lt;= (others=&gt;'0');
                          end if;
  
                          if cnt_clk_20 &lt; "1001100010010110100000" then --2.500.000
                              cnt_clk_20&lt;=cnt_clk_20+'1';
                          else
                              clk_20hz&lt;=not(clk_20hz);
                              cnt_clk_20&lt;= (others =&gt;'0');
                          end if;
  
                      end if;-- rising_edge
  
  
  end process diviseur_clk ;
  
  position_1 : process (clk_20hz,d1,g1)
  
  begin
  
      if rising_edge(clk_20hz) then
  
  case cnt1 is
  
          when 0=&gt;
  
      if d1='1' and g1='0' then
  
      led_barre_1&lt;="00110";
  
          cnt1&lt;=1;
  
      end if;
  
          when 1=&gt;
  
      if d1='1' and g1='0' then
  
      led_barre_1&lt;="01100";
  
      cnt1&lt;=2;
  
  
  
      elsif d1='0' and g1='1' then
  
      led_barre_1&lt;="00011";
  
      cnt1&lt;=0;
  
      end if;
  
  
  
          when 2=&gt;
  
      if d1='1' and g1='0' then
  
      led_barre_1&lt;="11000";
  
          cnt1&lt;=3;
  
      elsif d1='0' and g1='1' then
  
      led_barre_1&lt;="00110";
  
          cnt1&lt;=1;
  
      end if;
  
          when 3 =&gt;
  
          if d1='0' and g1='1' then
  
          led_barre_1&lt;="01100";
  
          cnt1&lt;=2;
  
          end if;
  
          when others =&gt;
  
          end case;
  
          end if;
  
  end process position_1;
  
  position_2 : process (clk_20hz,d2,g2)
  
  begin
  
      if rising_edge(clk_20hz) then
  
  case cnt2 is
  
          when 0=&gt;
  
      if d2='1' and g2='0' then
  
      led_barre_2&lt;="00110";
  
          cnt2&lt;=1;
  
      end if;
  
          when 1=&gt;
  
      if d2='1' and g2='0' then
  
      led_barre_2&lt;="01100";
  
      cnt2&lt;=2;
  
  
  
      elsif d2='0' and g2='1' then
  
      led_barre_2&lt;="00011";
  
      cnt2&lt;=0;
  
      end if;
  
  
  
          when 2=&gt;
  
      if d2='1' and g2='0' then
  
      led_barre_2&lt;="11000";
  
          cnt2&lt;=3;
  
      elsif d2='0' and g2='1' then
  
      led_barre_2&lt;="00110";
  
          cnt2&lt;=1;
  
      end if;
  
          when 3 =&gt;
  
          if d2='0' and g2='1' then
  
          led_barre_2&lt;="01100";
  
          cnt2&lt;=2;
          end if;
  
          when others =&gt;
  
          end case;
  
          end if;
  
  end process position_2;
  
  --end architecture pong_game_arch;
  
  
  --architecture led_matrix of pong_game is 
  
  
  compteur : process(clk_50Mhz)
  
  begin
  
      if rising_edge(clk_50Mhz) then
  
          if cnt &lt; 20 then
  
              cnt&lt;= cnt+1;
  
          else
  
              cnt&lt;=11;
  
          end if;
  
      end if;
  
  end process compteur ;
  
  
  initialisation : process(RST,clk_0,clk_1,clk_2,clk_3)
  
  begin
  
  
      if RST='1' then
  
          case cnt is 
  
              when 11 =&gt; etat_present &lt;= led11_init_1;
              when 12 =&gt; etat_present &lt;= led12_init_1;
              when 13 =&gt; etat_present &lt;= led13_init_1;
              when 14 =&gt; etat_present &lt;= led14_init_1;
              when 15 =&gt; etat_present &lt;= led15_init_1;
              when 16 =&gt; etat_present &lt;= led16_init_2;
              when 17 =&gt; etat_present &lt;= led17_init_2;
              when 18 =&gt; etat_present &lt;= led18_init_2;
              when 19 =&gt; etat_present &lt;= led19_init_2;
              when 20 =&gt; etat_present &lt;= led20_init_2;
  
          end case ;
  
      else 
  
          case choix is
  
              when lent =&gt;                             -- choice of the 
                                                       -- frequency (the error 
                                                       -- occurs here )
  
                  if rising_edge(clk_0) then
  
                      etat_present &lt;= etat_futur;
  
                  end if;
  
              when normal =&gt;
  
                  if rising_edge(clk_1) then
  
                      etat_present &lt;= etat_futur;
  
                  end if;
  
              when rapide =&gt;
  
                  if rising_edge(clk_2) then
  
                  etat_present &lt;= etat_futur;
  
                  end if;
  
              when rapide_v =&gt;
  
                  if rising_edge(clk_3) then
  
                  etat_present &lt;= etat_futur;
  
                  end if;
  
              end case ;
  
      end if;
  
  end process initialisation ;
  
  sequence_led : process(etat_present,led_barre_1,led_barre_2)
  
  begin
  
  case etat_present is
  
  -- sequence initiale
  
  when led6_init =&gt;
  
      etat_futur &lt;= led1;
  
  when led7_init =&gt;
  
      etat_futur &lt;= led2;
  
  when led8_init =&gt;
  
      etat_futur &lt;= led3;
  
  when led9_init =&gt;
  
      etat_futur &lt;= led4;
  
  when led10_init =&gt;
  
      etat_futur &lt;= led5;
  
  
  when led11_init_2 =&gt;
  
      etat_futur &lt;= led6_init;
  
  when led12_init_2 =&gt;
  
      etat_futur &lt;= led7_init;
  
  when led13_init_2 =&gt;
  
      etat_futur &lt;= led8_init;
  
  when led14_init_2 =&gt;
  
      etat_futur &lt;= led9_init;
  
  when led15_init_2 =&gt;
  
      etat_futur &lt;= led10_init;
  
  when led16_init_2 =&gt;
  
      etat_futur &lt;= led11_init_2;
  
  when led17_init_2 =&gt;
  
      etat_futur &lt;= led12_init_2;
  
  when led18_init_2 =&gt;
  
      etat_futur &lt;= led13_init_2;
  
  when led19_init_2 =&gt;
  
      etat_futur &lt;= led14_init_2;
  
  when led20_init_2 =&gt;
  
      etat_futur &lt;= led15_init_2;
  
  when led11_init_1 =&gt;
  
      etat_futur &lt;= led16_init_1;
  
  when led12_init_1 =&gt;
  
          etat_futur &lt;= led17_init_1;
  
  when led13_init_1 =&gt;
  
          etat_futur &lt;= led18_init_1;
  
  when led14_init_1 =&gt;
  
          etat_futur &lt;= led19_init_1;
  
  when led15_init_1 =&gt;
  
          etat_futur &lt;= led20_init_1;
  
  when led16_init_1 =&gt;
  
          etat_futur &lt;= led21_init;
  
  when led17_init_1 =&gt;
  
          etat_futur &lt;= led22_init;
  
  when led18_init_1 =&gt;
  
          etat_futur &lt;= led23_init;
  
  when led19_init_1 =&gt;
  
          etat_futur &lt;= led24_init;
  
  when led20_init_1 =&gt;
  
          etat_futur &lt;= led25_init;
  
  when led21_init =&gt;
  
          etat_futur &lt;= led26;
  
  when led22_init =&gt; 
  
          etat_futur &lt;= led27;
  
  when led23_init =&gt;
  
          etat_futur &lt;= led28;
  
  when led24_init =&gt;
  
          etat_futur &lt;= led29;
  
  when led25_init =&gt;
  
          etat_futur &lt;= led30;
  
  -- fin sequence initiale
  
  when led1 =&gt;
  
      if led_barre_1 = position1 then
  
          etat_futur &lt;= led7_1_d;
  
              if cnt_win &lt; 15 then 
  
                  cnt_win &lt;= cnt_win + 1;
  
              end if;
  
      else
  
          etat_futur &lt;= all_led_loose_on;
          cnt_win &lt;= 0;
  
      end if;
  
  
  when led2 =&gt;
  
      if led_barre_1 = position1 then
  
          etat_futur &lt;= led8_1_d;
  
              if cnt_win &lt; 15 then 
  
                  cnt_win &lt;= cnt_win + 1;
  
              end if;
  
      elsif led_barre_1 = position2 then
  
          etat_futur &lt;= led6_1;
  
              if cnt_win &lt; 15 then 
  
                  cnt_win &lt;= cnt_win + 1;
  
              end if;
  
      else 
  
          etat_futur &lt;= all_led_loose_on;
  
          cnt_win &lt;= 0;
  
      end if;
  
  when led3 =&gt;
  
      if led_barre_1 = position2 then
  
          etat_futur &lt;= led9_1_d;
  
              if cnt_win &lt; 15 then 
  
                  cnt_win &lt;= cnt_win + 1;
  
              end if;
  
      elsif led_barre_1 = position3 then
  
          etat_futur &lt;= led7_1_g;
  
              if cnt_win &lt; 15 then 
  
                  cnt_win &lt;= cnt_win + 1;
  
              end if;
  
      else
  
  
          etat_futur &lt;= all_led_loose_on;
  
          cnt_win &lt;= 0;
  
      end if;
  
  when led4 =&gt;
  
      if led_barre_1 = position3 then
  
          etat_futur &lt;= led10_1;
  
              if cnt_win &lt; 15 then 
  
                  cnt_win &lt;= cnt_win + 1;
  
              end if;
  
      elsif led_barre_1 = position4 then
  
          etat_futur &lt;= led8_1_g;
  
              if cnt_win &lt; 15 then 
  
                  cnt_win &lt;= cnt_win + 1;
  
              end if;
  
      else
  
          etat_futur &lt;= all_led_loose_on;
  
          cnt_win &lt;= 0;
  
      end if;
  
  when led5=&gt;
  
      if led_barre_1 = position4 then
  
          etat_futur &lt;= led9_1_g;
  
          if cnt_win &lt; 15 then 
  
              cnt_win &lt;= cnt_win + 1;
  
          end if; 
  
      else
  
          etat_futur&lt;= all_led_loose_on;
  
          cnt_win &lt;= 0;
  
      end if;
  
  when led6_1=&gt;
  
      etat_futur &lt;= led12_1_d;
  
  when led6_2=&gt;
  
      etat_futur &lt;= led2;
  
  when led7_1_g =&gt;
  
      etat_futur &lt;= led11_1;
  
  when led7_1_d=&gt;
  
      etat_futur &lt;= led13_1_d;
  
  when led7_2_g =&gt;
  
      etat_futur &lt;= led1;
  
  when led7_2_d =&gt;
  
      etat_futur &lt;= led3;
  
  when led8_1_g =&gt;
  
      etat_futur &lt;= led12_1_g;
  
  when led8_1_d =&gt;
  
      etat_futur &lt;= led14_1_d;
  
  when led8_2_g =&gt;
  
      etat_futur &lt;= led2;
  
  when led8_2_d =&gt;
  
      etat_futur &lt;= led4;
  
  when led9_1_g =&gt;
  
      etat_futur &lt;= led13_1_g;
  
  when led9_1_d =&gt;
  
      etat_futur &lt;= led15_1;
  
  when led9_2_g =&gt;
  
      etat_futur &lt;= led3;
  
  when led9_2_d =&gt;
  
      etat_futur &lt;= led5;
  
  when led10_1 =&gt;
  
      etat_futur &lt;= led14_1_g;
  
  when led10_2 =&gt;
  
      etat_futur &lt;= led4;
  
  when led11_1 =&gt;
  
      etat_futur &lt;= led17_1_d;
  
  when led11_2 =&gt;
  
      etat_futur &lt;= led7_2_d;
  
  when led12_1_g =&gt;
  
      etat_futur &lt;= led16_1;
  
  when led12_1_d =&gt;
  
      etat_futur &lt;= led18_1_d;
  
  when led12_2_g =&gt;
  
      etat_futur &lt;= led6_2;
  
  when led12_2_d =&gt;
  
      etat_futur &lt;= led8_2_d;
  
  when led13_1_g =&gt;
  
      etat_futur &lt;= led17_1_g;
  
  when led13_1_d =&gt;
  
      etat_futur &lt;= led19_1_d;
  
  when led13_2_g =&gt;
  
      etat_futur &lt;= led7_2_g;
  
  when led13_2_d =&gt;
  
      etat_futur &lt;= led9_2_d;
  
  when led14_1_g =&gt;
  
      etat_futur &lt;= led18_1_g;
  
  when led14_1_d =&gt;
  
      etat_futur &lt;= led20_1;
  
  when led14_2_g =&gt;
  
      etat_futur &lt;= led8_2_g;
  
  when led14_2_d =&gt;
  
      etat_futur &lt;= led10_2;
  
  when led15_1 =&gt;
  
      etat_futur &lt;= led19_1_g;
  
  when led15_2 =&gt;
  
      etat_futur &lt;= led9_2_g;
  
  when led16_1 =&gt;
  
      etat_futur &lt;= led22_1_d;
  
  when led16_2 =&gt;
  
      etat_futur &lt;= led12_2_d;
  
  when led17_1_g =&gt;
  
      etat_futur &lt;= led21_1;
  
  when led17_1_d =&gt;
  
      etat_futur &lt;= led23_1_d;
  
  when led17_2_g =&gt;
  
      etat_futur &lt;= led11_2;
  
  when led17_2_d =&gt;
  
      etat_futur &lt;= led13_2_d;
  
  when led18_1_g =&gt;
  
      etat_futur &lt;= led22_1_g;
  
  when led18_1_d =&gt;
  
      etat_futur &lt;= led24_1_d;
  
  when led18_2_g =&gt;
  
      etat_futur &lt;= led12_2_g;
  
  when led18_2_d=&gt;
  
      etat_futur &lt;= led14_2_d;
  
  when led19_1_g =&gt;
  
      etat_futur &lt;= led23_1_g;
  
  when led19_1_d =&gt;
  
      etat_futur &lt;= led25_1;
  
  when led19_2_g =&gt;
  
      etat_futur &lt;= led13_2_g;
  
  when led19_2_d =&gt;
  
      etat_futur &lt;= led15_2;
  
  when led20_1 =&gt;
  
      etat_futur &lt;= led24_1_g;
  
  when led20_2 =&gt;
  
      etat_futur &lt;= led14_2_g;
  
  when led21_1 =&gt;
  
      etat_futur &lt;= led27;
  
  when led21_2 =&gt;
  
      etat_futur &lt;= led17_2_d;
  
  when led22_1_g =&gt;
  
      etat_futur &lt;= led26;
  
  when led22_1_d=&gt;
  
      etat_futur &lt;= led28;
  
  when led22_2_g =&gt;
  
      etat_futur &lt;= led16_2;
  
  when led22_2_d=&gt;
  
      etat_futur &lt;= led18_2_d;
  
  when led23_1_g =&gt;
  
      etat_futur &lt;= led27;
  
  when led23_1_d =&gt;
  
      etat_futur &lt;= led29;
  
  when led23_2_g =&gt;
  
      etat_futur &lt;= led17_2_g;
  
  when led23_2_d =&gt;
  
      etat_futur &lt;= led19_2_d;
  
  when led24_1_g =&gt;
  
      etat_futur &lt;= led28;
  
  when led24_1_d =&gt;
  
      etat_futur &lt;= led30;
  
  when led24_2_g =&gt;
  
      etat_futur &lt;= led18_2_g;
  
  when led24_2_d =&gt;
  
      etat_futur &lt;= led20_2;
  
  when led25_1 =&gt;
  
      etat_futur &lt;= led29;
  
  when led25_2 =&gt;
  
      etat_futur &lt;= led19_2_g;
  
  when led26 =&gt;
  
      if led_barre_2=position1 then
  
          etat_futur&lt;=led22_2_d;
  
          if cnt_win &lt; 15 then 
  
              cnt_win &lt;= cnt_win + 1;
  
          end if;
  
      else --loose
  
          etat_futur &lt;= all_led_loose_on;
  
          cnt_win &lt;= 0;
  
      end if;
  
  when led27 =&gt;
  
      if led_barre_2=position1 then
  
          etat_futur&lt;=led23_2_d;
  
          if cnt_win &lt; 15 then 
  
              cnt_win &lt;= cnt_win + 1;
  
          end if;
  
      elsif led_barre_2=position2 then
  
          etat_futur&lt;=led21_2;
  
          if cnt_win &lt; 15 then 
  
              cnt_win &lt;= cnt_win + 1;
  
          end if;
  
      else --loose
  
          etat_futur &lt;= all_led_loose_on;
  
          cnt_win &lt;= 0;
      end if;
  
  when led28 =&gt;
  
      if led_barre_2=position2 then
  
          etat_futur &lt;= led24_2_d;
  
          if cnt_win &lt; 15 then 
  
              cnt_win &lt;= cnt_win + 1;
  
          end if;
  
      elsif led_barre_2=position3 then
  
          etat_futur &lt;= led22_2_g;
  
          if cnt_win &lt; 15 then 
  
              cnt_win &lt;= cnt_win + 1;
  
          end if;
  
      else 
  
          etat_futur &lt;= all_led_loose_on;
  
          cnt_win &lt;= 0;
  
      end if;
  
  when led29 =&gt;
  
      if led_barre_2 = position4 then
  
      etat_futur &lt;= led23_2_g;
  
      if cnt_win &lt; 15 then 
  
              cnt_win &lt;= cnt_win + 1;
  
      end if;
  
      elsif led_barre_2 = position3 then
  
      etat_futur &lt;= led25_2;
  
      if cnt_win &lt; 15 then 
  
          cnt_win &lt;= cnt_win + 1;
  
      end if;
  
      else
  
          etat_futur &lt;= all_led_loose_on;
  
          cnt_win &lt;= 0;
  
      end if;
  
  when led30 =&gt;
  
      if led_barre_2 = position4 then
  
          etat_futur &lt;= led24_2_g;
  
          if cnt_win &lt; 15 then 
  
              cnt_win &lt;= cnt_win + 1;
  
          end if;
  
      else
  
          etat_futur &lt;= all_led_loose_on;
  
          cnt_win &lt;= 0;
  
      end if;
  
  when all_led_loose_on =&gt;                       -- cycle entre ces deux états
  
      etat_futur &lt;= all_led_loose_off;                  -- jusqu'à ce que RST = '1'
  
  when all_led_loose_off =&gt;
  
      etat_futur &lt;= all_led_loose_on;
  
  end case ;
  
  end process sequence_led ;
  
  
  affichage_sequence : process(etat_present)
  begin
  
  case etat_present is
  
  when led1 =&gt;
  
      leds &lt;= ( 1 =&gt; '1', others =&gt; '0');
  
  when led2 =&gt;
  
      leds &lt;= ( 2 =&gt; '1', others =&gt; '0');
  
  when led3 =&gt;
  
      leds &lt;= ( 3 =&gt; '1', others =&gt; '0');
  
  when led4 =&gt;
  
      leds &lt;= ( 4 =&gt; '1', others =&gt; '0');
  
  when led5=&gt;
  
      leds &lt;= ( 5 =&gt; '1', others =&gt; '0');
  
  when led6_1|led6_2|led6_init=&gt;
  
      leds &lt;= ( 6 =&gt; '1', others =&gt; '0');
  
  when led7_1_d|led7_1_g|led7_2_d|led7_2_g|led7_init =&gt;
  
      leds &lt;= ( 7 =&gt; '1', others =&gt; '0');
  
  when led8_1_d|led8_1_g|led8_2_d|led8_2_g|led8_init =&gt;
  
      leds &lt;= ( 8 =&gt; '1', others =&gt; '0');
  
  when led9_1_d|led9_1_g|led9_2_d|led9_2_g|led9_init =&gt;
  
      leds &lt;= ( 9 =&gt; '1', others =&gt; '0');
  
  when led10_1|led10_2|led10_init =&gt;
  
      leds &lt;= ( 10 =&gt; '1', others =&gt; '0');
  
  when led11_1|led11_2|led11_init_1|led11_init_2 =&gt;
  
      leds &lt;= ( 11 =&gt; '1', others =&gt; '0');
  
  when led12_1_g|led12_1_d|led12_2_g|led12_2_d|led12_init_1|led12_init_2 =&gt;
  
      leds &lt;= ( 12 =&gt; '1', others =&gt; '0');
  
  when led13_1_g|led13_1_d|led13_2_g|led13_2_d|led13_init_1|led13_init_2 =&gt;
  
      leds &lt;= ( 13 =&gt; '1', others =&gt; '0');
  
  when led14_1_d|led14_1_g|led14_2_g|led14_2_d|led14_init_1|led14_init_2 =&gt;
  
      leds &lt;= ( 14 =&gt; '1', others =&gt; '0');
  
  when led15_1|led15_2|led15_init_1|led15_init_2 =&gt;
  
      leds &lt;= ( 15 =&gt; '1', others =&gt; '0');
  
  when led16_1|led16_2|led16_init_1|led16_init_2 =&gt;
  
      leds &lt;= ( 16 =&gt; '1', others =&gt; '0');
  
  when led17_1_g|led17_1_d|led17_2_g|led17_2_d|led17_init_1|led17_init_2 =&gt;
  
      leds &lt;= ( 17 =&gt; '1', others =&gt; '0');
  
  when led18_1_g|led18_1_d|led18_2_g|led18_2_d|led18_init_1|led18_init_2 =&gt;
  
      leds &lt;= ( 18 =&gt; '1', others =&gt; '0');
  
  when led19_1_g|led19_1_d|led19_2_g|led19_2_d|led19_init_1|led19_init_2 =&gt;
  
      leds &lt;= ( 19 =&gt; '1', others =&gt; '0');
  
  when led20_1|led20_2|led20_init_1|led20_init_2 =&gt;
  
      leds &lt;= ( 20 =&gt; '1', others =&gt; '0');
  
  when led21_1|led21_2|led21_init =&gt;
  
      leds &lt;= ( 21 =&gt; '1', others =&gt; '0');
  
  when led22_1_g|led22_1_d|led22_2_g|led22_2_d|led22_init =&gt;
  
      leds &lt;= ( 22 =&gt; '1', others =&gt; '0');
  
  when led23_1_g|led23_1_d|led23_2_g|led23_2_d|led23_init =&gt;
  
      leds &lt;= ( 23 =&gt; '1', others =&gt; '0');
  
  when led24_1_g|led24_1_d|led24_2_g|led24_2_d|led24_init =&gt;
  
      leds &lt;= ( 24 =&gt; '1', others =&gt; '0');
  
  when led25_1|led25_2|led25_init =&gt;
  
      leds &lt;= ( 25 =&gt; '1', others =&gt; '0');
  
  when led26 =&gt;
  
      leds &lt;= ( 26 =&gt; '1', others =&gt; '0');
  
  when led27 =&gt;
  
      leds &lt;= ( 27 =&gt; '1', others =&gt; '0');
  
  when led28 =&gt;
  
      leds &lt;= ( 28 =&gt; '1', others =&gt; '0');
  
  when led29 =&gt;
  
      leds &lt;= ( 29 =&gt; '1', others =&gt; '0');
  
  when led30 =&gt;
  
      leds &lt;= ( 30 =&gt; '1', others =&gt; '0');
  
  when all_led_loose_on =&gt;
  
      leds &lt;= (others =&gt;'1');
  
  when all_led_loose_off =&gt;
  
      leds &lt;= (others =&gt;'0');
  
  end case ;
  
  end process affichage_sequence ;
  variation_frequence : process (cnt_win) 
  begin
  
  case cnt_win is 
  
  when 0|1|2|3  =&gt; choix &lt;= lent ;
  when 4|5|6    =&gt; choix &lt;= normal ;
  when 7|8|9    =&gt; choix &lt;= rapide ;
  when 10|11|12 =&gt; choix &lt;= normal ;
  when 13|14|15 =&gt; choix &lt;= rapide_v;
  end case;
  end process variation_frequence ;
  end architecture pong_game_arch;
  </code></pre>
  
  <p>The error occurs at the process "initialisation".</p>