Final project for Arduino Basics course 2025 in SENAC Ribeirão Preto - Brazil.
The game consists of converting a 4-bit binary number as quickly as possible to its hexadecimal representation (maximum value of F).
The player has 99 seconds of available time to read all 16 numbers of 4-bit binary, convert it to its hexadecimal representation and find the right answer by pressing UP button and answering by pressing OK button.
The binary number is shown both in the LCD and leds.
The best player is the one who answers correctly all the number conversions before the time is up.
The project architecture is based in MVC concepts: Game.h for Model , ShowState.h for View and StateMachine.h for Controller.
EXPANDED TECHNICAL DETAILS
Computer Science Educational Hardware
B1TS to HEX is an interactive puzzle game designed to teach the fundamentals of binary-to-hexadecimal conversion through tactile gameplay.
- Binary Input Matrix: Features 8 high-quality toggle switches representing a single "Byte" (8 bits). As the user flips the switches, the Arduino calculates the corresponding Hexadecimal value in real-time.
- Dynamic Challenge Engine: The system generates a target Hex value on a high-contrast I2C OLED screen. The user must match their switch positions to the target within a set time limit, increasing the difficulty as they progress.
Logic Visualization
- Bitwise Shifting Core: The firmware uses bitwise operations (
<<and|) to assemble the 8-bit binary input into a single decimal integer for efficient comparison, providing a foundational lesson in low-level data manipulation.