[an error occurred while processing this directive]
|
process (d(0),clk)
begin
control_d <= d;
case control_d(3 downto 1) is
when "000" =>
if d(0)'event and ( d(0) = '0' or d(0) = '1') then counter4 <= 0; end if;
if clk'event and clk = '0' then counter4 <= counter4 + 1; end if;
if d(0) = '0' then
if (counter4 < 520) and (counter4 > 0) then outrele(0) <= '1';
elsif counter4 > 519 and counter4 < 999 then outrele(0) <= '0';
end if;
end if;
if d(0) = '1' then
if (counter4 < 520) and (counter4 > 0) then outrele(1) <= '1';
elsif counter4 > 519 and counter4 < 999 then outrele(1) <= '0';
end if;
end if;
when "001" =>
if d(0)'event and ( d(0) = '0' or d(0) = '1') then counter5 <= 0; end if;
if clk'event and clk = '0' then counter5 <= counter5 + 1; end if;
if d(0) = '0' then
if (counter5 < 520) and (counter5 > 0) then outrele(2) <= '1';
elsif counter5 > 519 and counter5 < 999 then outrele(2) <= '0';
end if;
end if;
if d(0) = '1' then
if (counter5 < 520) and (counter5 > 0) then outrele(3) <= '1';
elsif counter5 > 519 and counter5 < 999 then outrele(3) <= '0';
end if;
end if;
when "010" =>
if d(0)'event and ( d(0) = '0' or d(0) = '1') then counter6 <= 0; end if;
if clk'event and clk = '0' then counter6 <= counter6 + 1; end if;
if d(0) = '0' then
if (counter6 < 520) and (counter6 > 0) then outrele(4) <= '1';
elsif counter6 > 519 and counter6 < 999 then outrele(4) <= '0';
end if;
end if;
if d(0) = '1' then
if (counter6 < 520) and (counter6 > 0) then outrele(5) <= '1';
elsif counter6 > 519 and counter6 < 999 then outrele(5) <= '0';
end if;
end if;
when others => null;
end case;
end process;
E-mail: info@telesys.ru