Revive Lost With Arduino

by miniil in Circuits > Arduino

363 Views, 2 Favorites, 0 Comments

Revive Lost With Arduino

20220117_144236.jpg

Do you remember Lost?

It was a famous drama television series from 2004 to 2010 with six seasons.

Lost is for me the best series I have ever seen.

To learn a little more about Arduino I realise a small project on the theme of my favorite series.

Supplies

20220117_145429.jpg
20220117_145408.jpg
20220117_145455.jpg
20220117_145439.jpg
20220117_145421.jpg

1X Arduino (or compatible with) control board

The control board is the core of a circuit. After promming, it can be used to control other components to achieve intended function. Here I choose a Freenove control board compatible with Arduino.

1X LCD 1602 Display Screen

The LCD 1602 Display Screen can display 2 lines of characters in 16 columns. It can display letters, numbers, symbols, ASCII code and so on.

1X I2C Interface

The I2C interface connects the serial input and parallel output module to the LCD 1602 Display Screen. This allows us to only use 4 lines to operate LCD 1602.

1X 4X4 Keypad

A Keypad Matrix is a device that integrates a number of keys in one package. Here there is 16 Keys).

8X jumpers male/male


4X jumpers male/female


You can find documentation for all components on Freenove website.

We also need a Programming Software. I use Arduino IDE to write and upload code to the control board. Arduino IDE is free and open source. You can download the corresponding installer according to your operating system from https://www.arduino.cc/en/Main/Software.

Connect and Test Keypad

FZCHPWCKYIP83BY.jpeg
keypadBack.png
tinkercadKeypadTest.png

As you can see, buttons on a keypad are arranged in rows and columns. Thus a 4X4 keypad has 4 rows and 4 columns.

Beneath each button is a membrane switch.

Each switch in a row is connected to the other switches in the row by a conductive trace underneath the pad.

Each switch in a column is connected the same way. One side of the switch is connected to all of the other switches in that column by a conductive trace.

Each row and column is brought out to a single pin, for a total of 8 pins on a 4X4 keypad.

Pressing a button closes the switch between a column and a row trace, allowing current to flow between a column pin and a row pin.

First I use tinkercad to virtualy reproduce and test the circuit of this first step.

If it is good I do it with real components and use Arduino IDE to upload code to the control board.

You need Keypad library wich is available via Arduino IDE library manager.

First step is OK, go on.

Downloads

Connect and Test LCD 1601

20220117_163304.jpg
I2C Schematic.png
20220117_161515.jpg
20220117_161721.jpg

According to the schematic diagram, connect I2C interface to control board.

After connect LCD 1602 to I2C interface (mine are already fixed together).

Then use Arduino IDE to write code and test LCD 1601 with l2C Interface. You also need the liquidcrystal-i2c library that you can install via Arduino IDE library manager.

If all goes well, you will see HELLO WORLD on LCD.

If you don't see anything on your LCD you may have to adjust brightness by rotating potentiometer in the backside of I2C interface (the blue component).

Create and Revive Lost

Revive Lost With Arduino
Counter_108.jpg

Remember... The Swan station contained a 108 minutes countdown timer.

The time was reset by entering the Numbers into the station's computer and pressing an execute button.

So in my code I create a countdown timer but only a 10 seconds countdown timer for the demo.

After this time, it is ask to enter the numbers and those are verified.

If numbers are correct, the countdown is displayed again. If not, we can try again.