0% found this document useful (0 votes)
65 views

'Mission Impossible' Bomb Arduino

Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
65 views

'Mission Impossible' Bomb Arduino

Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Design and Implementation of a 'Mission Impossible'

Style Countdown Timer Using Arduino and 7-


Segment Displays
Rivera Medina Paola Sofía1, Ortiz Franco Humberto Antonio2, Muñoz Pérez Gerardo Alejandro3 &
Martínez Torres Diego Ivan4
Universidad Politecnica de Yucatan
Mérida, Yucatán, México

[email protected], [email protected], [email protected] & [email protected]

Abstract— This report outlines the design and implementation of essential for numerical displays in various
a "Mission Impossible" style bomb simulation using Arduino.
The device features a countdown timer that starts from a applications.
random number between 10 and 99, decrementing to 00,
signaling a game over. The timer can be modified by A 7-segment display is an electronic display
disconnecting specific cables, each programmed to alter the device for displaying decimal numerals. It consists
countdown speed or trigger a win/loss condition. The materials
used include two 7-segment displays, an Arduino board, two of seven LEDs (hence the name) arranged in a
CD4511 decoders, a NOT logic gate, protoboard wires, Dupont rectangular fashion. Each LED is called a segment
cables, and a passive buzzer. because when illuminated, it forms part of a digit.
Keywords— Arduino, 7-Segment Display, CD4511 Decoder, II. DEVELOPMENT
NOT Gate, Countdown Timer, Digital Systems, Bomb
Simulation. The materials required for this project include
two 7-segment displays, an Arduino board, two
I. INTRODUCTION CD4511 decoders, a NOT logic gate, various
The project leverages the Arduino protoboard and Dupont wires, and a passive buzzer.
microcontroller for its versatility and ease of use in These components were chosen for their
prototyping. Arduino provides an excellent compatibility and ease of integration with the
platform for integrating various components like Arduino platform.
displays, decoders, and buzzers.

Arduino is an open-source electronics platform


based on easy-to-use hardware and software. It
consists of a microcontroller, a development
environment (IDE), and a programming language.
Arduino boards can read inputs and turn them into
Fig. 1. Materials
outputs, operating on simple instructions provided
by the user. Its versatility and accessibility make it The code provided for this project initializes the
ideal for educational purposes and hobbyist projects. hardware components and sets up a random
countdown timer. It uses functions to display
The CD4511 is a BCD to 7-segment numbers on the 7-segment displays and plays the
latch/decoder/driver that can drive a 7-segment "Mission Impossible" theme melody using the
display. It accepts binary-coded decimal (BCD) passive buzzer. The countdown can be adjusted by
inputs and converts them to the appropriate 7- disconnecting specific cables that modify the
segment code to display numbers. This makes it timer's speed or trigger win/lose conditions. The
code also handles the display logic for the tens and
units digits of the countdown timer and includes This allowed for verification of the code's
functions to play different melodies for win and functionality and the planning of the circuit layout.
lose scenarios. The simulation confirmed that the countdown timer
and cable disconnection logic operated as intended.
The code begins by defining pins and variables
for various components such as the speaker, control
cables, and the pins for the 7-segment displays.
Initially, the speaker pin and display pins are
configured, and the counter is initialized with a
random number between 10 and 99. In the setup
function, pin modes are defined and the random
number generator is seeded. The main loop function
handles the core logic of the program, continuously
updating the counter value and displaying the
corresponding numbers on the tens and units
displays using specific functions for each number Fig. 3. Tinkercad simulation.
(cerou, unou, dosu, etc.).
III. RESULTS
The playMelody function continuously plays the The project was a success. The bomb simulation
Mission Impossible theme melody, utilizing the performed as expected, with the countdown timer
playTone and playNote functions to generate the accurately decrementing from a random starting
appropriate tones. Game logic includes checks to point and the "Mission Impossible" theme playing
determine if any cable is disconnected, which correctly through the buzzer. The cable
modifies the counter speed or triggers win/lose disconnection mechanism effectively modified the
conditions, such as the loseGame function that countdown speed and triggered the appropriate
resets the counter and plays an indicative melody. win/lose conditions. No significant issues were
Additionally, victory and defeat melodies encountered during testing, and the final
(winmelody and angrymelody) are played based on implementation met all project requirements.
game conditions.

The display is updated in each loop cycle, and the


counting speed is adjusted according to the state of
the cables, providing auditory and visual feedback
on the game's status.

The code will be attached for further analysis. Fig. 4. Final Circuit

IV. CONCLUSION
This project successfully demonstrated the
integration of multiple digital components using
Arduino to create an interactive bomb simulation.
The use of 7-segment displays, CD4511 decoders,
and a passive buzzer provided a functional and
engaging representation of a countdown timer. The
ability to modify the timer using cable
Fig. 2. Code disconnections added an interactive element,
enhancing the educational value of the project.
A simulation was conducted using Tinkercad, an Future improvements could include adding more
online platform for creating and testing circuits.
complex win/lose conditions or integrating wireless
control for additional interactivity.
REFERENCES

[1] Banzi, M., & Shiloh, M. (2020). Getting Started with Arduino: The
Open Source Electronics Prototyping Platform (4th ed.). Maker Media,
Inc.
[2] Monk, S. (2019). Programming Arduino: Getting Started with Sketches
(2nd ed.). McGraw-Hill Education.
[3] Margolis, M. (2020). Arduino Cookbook (3rd ed.). O'Reilly Media.
[4] Levy, T. (2018). Atmel AVR Programming: Learning to Write
Software for Hardware. Maker Media, Inc.
[5] Floyd, T. L. (2014). Digital Fundamentals (11th ed.). Pearson.
[6] Mazidi, M. A., Causey, C., & Naimi, S. (2016). The AVR
Microcontroller and Embedded Systems Using Assembly and C.
Pearson.
[7] Ibrahim, D. (2012). Microcontroller Projects in C for the 8051. Newnes.
[8] Meier, R. (2012). Programming the Mobile Web (2nd ed.). O'Reilly
Media.
[9] Buchla, D. M., & McLellan, W. T. (2015). Applied Electronic
Instrumentation and Measurement (3rd ed.). Oxford University Press.
[10] Horowitz, P., & Hill, W. (2015). The Art of Electronics (3rd ed.).
Cambridge University Press.
[11] Anand, M. M. (2018). Digital Electronics: Principles and Applications
(8th ed.). Cengage Learning.
[12] Wakerly, J. F. (2018). Digital Design: Principles and Practices (5th ed.).
Pearson.

You might also like