Projects / Ideas / Bit sequence detector

Bit sequence detector

IntermediateLearningIdeaReviewed
In short

How do you build a bit sequence detector?

You tap a one button and a zero button to enter bits, and the Nano lights an LED whenever the last three bits match a chosen pattern, such as 101. A small state machine drawn as a diagram first, then built in code, showing how overlapping matches are handled. You need Arduino Nano, Tactile push button 6 mm × 2, LED 5 mm red, LED 5 mm green, Resistor 220 Ω × 2, Breadboard 830 Tie Points and Jumper wires male to male (40 pcs, 20 cm).

Level
Intermediate
Time
About 80 min
Parts
7
An idea, not a guided build yet. Goal, parts and steps; no wiring, code or tests. Copy it to My Garage to plan it.
Goal

Light an LED when a bit pattern appears.

Parts list

How to build it

  1. Draw the state diagram on paper
  2. Read the two bit buttons
  3. Move between states on each bit
  4. Light the LED on a match
  5. Allow overlapping patterns

Related projects

Common questions

What parts do I need for the bit sequence detector?

Arduino Nano, Tactile push button 6 mm × 2, LED 5 mm red, LED 5 mm green, Resistor 220 Ω × 2, Breadboard 830 Tie Points and Jumper wires male to male (40 pcs, 20 cm).

How long does the bit sequence detector take to build?

About 80 minutes for a intermediate maker.