Ticker

6/recent/ticker-posts

Header Ads Widget


 

JK Flip_Flop

 JK Flip-Flop

 

 

CODE 

library IEEE;
use IEEE STD_LOGIC_1164.all;

entity JKFF is
    port(j, k, clk, rst :in STD_LOGIC;
            q, qb:out STD_LOGIC);
end JKFF;

architecture Behavioral of JKFF is
begin
    process(j, k, clk, rst)
    begin
        if rst='1' then
            q<='0';
            qb<='0';
            elsif (clk'event and clk='1' )then
            if(j/=k) then
                q<=j;
                qb<=not j;

            elsif(s='1' and r='1') then

            q<='not j';

            qb<='j';     
        end if;
        end if;
        end process;
end Behavioral;

Post a Comment

0 Comments