This repository contains the codebase for a controller made for children using Arduino. The device was created as a class project for INFO-I341, Prototyping for Arduino, offered by Indiana University during the Spring 2023 semester.
The Arduino Children's Controller is a custom-made device designed specifically for children. It features four large, round buttons and one smaller Ctrl button, all placed within a colorful LEGO board. The controller's design aims to provide an engaging and intuitive interface for children to interact with.
button.mp4
The buttons were inspired by morse code telegraph machines. When the user pressed down on the button section's circular LEGO piece, the cylinder piece below presses the tactile button. The hinge section forces the button section to go back up.
Each button has a unique top, allowing children to differentiate between them by touch alone. The distinctive design elements help children easily identify the buttons and enhance their overall experience while using the controller.
The controller was built with the following components:
- 1 Arduino Pro Micro Controller
- LEGO bricks
- 5 Mini breadboards
- 5 LEDs
- 5 Buttons
- Jumper Wires
The main file in this repository is controller.ino
. It handles user input in the form of button presses and provides two different functionalities depending on whether the Ctrl button is pressed or not. The code is designed to work with Windows and Chrome.
The controller.ino
file provides the following functionality:
-
A struct called
Button
is defined to store the properties of each button. The properties include the button pin, LED pin, button state (pressed or not), URL of the playlist/video, the value of the key needed for the shortcut, and a boolean to check if the shortcut requires the Shift key. -
Upon setting up the Arduino, the code opens serial communication and activates the keyboard class to emulate keystrokes on the connected computer.
-
If a regular button is pressed while in the "playlist" state, the code emulates the keystrokes "Left Ctrl + L" to jump to the address bar in Chrome. Then it types the URL of the playlist stored in the corresponding
Button
struct and navigates to the playlist. -
If a regular button is pressed while in the "shortcut" state, the code emulates the keystrokes defined in the corresponding
Button
struct. -
If the Ctrl button is pressed, the code switches between the "playlist" and "shortcut" states.
To use this codebase and set up the Arduino Children's Controller, follow the steps below:
- Clone the repository to your local machine.
git clone https://github.com/vtlanglois/ArduinoKidController-I341.git
-
Connect your Arduino board to your computer.
-
Open the
controller.ino
file in the Arduino IDE. -
Configure the necessary settings, such as board type and port, in the Arduino IDE.
-
Upload the code to the Arduino board.
-
Connect the buttons and LEDs to the appropriate pins on the Arduino board, as specified in the
Button
struct within the code. -
Connect the Arduino board to the computer running Chrome.
-
Ensure that Chrome is open and the active window.
-
Test the functionality by pressing the buttons and observing the desired behavior in Chrome.
Contributions to the project are welcome. If you find any issues or have suggestions for improvements, please open an issue or submit a pull request on the repository.
This project is licensed under the MIT License. Feel free to use, modify, and distribute the code for personal and commercial purposes.