VWV Microproject SR File
VWV Microproject SR File
1.1 Introduction:
Up-Counter:
An up counter is a digital device that sequentially counts in an ascending order,
typically starting from zero and incrementing by one with each clock pulse. This
counting mechanism is essential in digital circuits for keeping track of events or
measuring time intervals, playing a significant role in registers and counters. Up
counters can be implemented using various digital logic circuits, including flip-
flops, which are the basic building blocks of sequential logic. The maximum
count of an up counter depends on its bit width; for example, a 4-bit up counter
can count from 0 to 15. Reset functionality is often included in up counters,
allowing them to return to zero when needed. Up counters can be designed as
synchronous or asynchronous, where synchronous counters change states
simultaneously with the clock pulse and asynchronous counters change states
based on the previous output. They are widely used in applications such as
digital clocks, frequency counters, and event counters in various electronic
systems.
Truth Table :
1 1 0 0 0 0 0
0 1 1 0 0 0 0
0 1 2 0 0 0 1
0 1 3 0 0 1 0
0 1 4 0 0 1 1
0 1 5 0 1 0 0
0 1 6 0 1 1 1
0 1 7 0 1 1 0
0 1 8 0 1 1 1
0 1 9 1 0 0 0
0 1 10 1 0 0 1
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
use IEEE.STD_LOGIC_ARITH.ALL;
use IEEE.STD_LOGIC_UNSIGNED.ALL;
entity MOD_10 is
Port ( CLK : in STD_LOGIC;
LOAD : in STD_LOGIC;
CLR : in STD_LOGIC;
Q : inout STD_LOGIC_VECTOR (03 downto 0));
end MOD_10;
P1 : PROCESS (CLK,CLR)
BEGIN
IF (CLK'EVENT AND CLK ='1') THEN
IF CLR = '1' THEN
TMP <= "0000";
ELSIF LOAD = '1' THEN
IF TMP = "1001" THEN
1.5 Outputs :
1.6 Applications :
1.7 Conclusion :
flops. In this report we discussed about its working, truth table, implementation
using flip-flops and learn about it.
2.1 Introduction :
Initial State (S0): The machine starts in this state, waiting for the first
bit.
State S1 (0 detected): If the input is "0", the machine transitions to S1,
indicating that the first "0" of the target sequence has been seen.
State S2 (00 detected): If the input is "0" while in S1, the machine
transitions to S2, indicating that "00" has been detected.
State S3 (001 detected): If the input is "1" while in S2, the machine
transitions to S3, indicating that the complete sequence "001" has been
detected.
Block Diagram :
001
S.D.
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
use IEEE.STD_LOGIC_ARITH.ALL;
use IEEE.STD_LOGIC_UNSIGNED.ALL;
entity SQ_001 is
Port ( A : in STD_LOGIC;
CLK : in STD_LOGIC;
RESET : in STD_LOGIC;
Z : out STD_LOGIC);
end SQ_001;
ELSE
STATE <= ST0;
END IF;
WHEN ST1 => Z <= '0';
IF (A = '0') THEN
STATE <= ST2;
ELSE
STATE <= ST0;
END IF;
WHEN ST2 => Z <= '0';
IF (A = '0') THEN
STATE <= ST2;
ELSE
STATE <= ST3;
END IF;
WHEN ST3 => Z <= '1';
IF (A = '0') THEN
STATE <= ST2;
ELSE
STATE <= ST0;
END IF;
WHEN OTHERS => NULL;
END CASE;
END IF;
END PROCESS P0;
end Behavioral;
2.6 Applications :
2.7 Conclusion :
a finite state machine (FSM) to track input transitions and generate the
appropriate output. This technique is commonly applied in digital
communication
systems, signal processing, and error detection mechanisms. The developed
VHDL code can be further optimized or extended for detecting more complex
patterns, demonstrating the flexibility and scalability of FSM-based digital
designs.