Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
115 changes: 58 additions & 57 deletions TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,107 +1,108 @@
---
title: My Super Awesome Tutorial
date: 1970-01-01
title: Motion Interface Tutorial
date: 2025-05-19
authors:
- name: John Doe
- name: Mary Jane
- name: Majd Abu-Shamiyeh
---

![relevant graphic or workshop logo](image/path)
![ESP32+MPU-6050](images/ESP32-MPU6050-Module-Accelerometer-Gyroscope-Temperature-Sensor-Arduino.webp)

## Introduction

Write a short section on what the tutorial is aiming to accomplish.
What is the motivation behind the tutorial?
What do you want readers to gain from the tutorial?
This tutorial is aiming to teach how to interface an accelerometer sensor with an ESP32 Dev Board to detect motion. The motivation behind this tutorial is to help measure forces in all directions which allow to detect shakes, tilts and falls. I want readers to understand how to detect any type of motion and understand how to link the accelerometer with the Dev Board and how they can work correspondingly.

### Learning Objectives

- Bullet list of skills/concepts to be covered

Any additional notes from the developers can be included here.
- Understanding the basic functionalities of a three-axis acclerometer
- Configure and ESP32 board to communicate with a sensor
- How to read data and interpret the sensor
- How to impliment motion detection (shaking, tilting and ext.)
- Alarm motion event using LED indicator/sound.

### Background Information

Describe your topic here. What does it do? Why do you use it?
Are there other similar things to use? What are the pros and cons?
Explain important concepts that are necessary to understand.
Include (and cite if needed) any visuals that will help the audience understand.
Accelerometers are useful in measuring accelration in m/s^2. The MPU-6050 is an effective sensor that can communicate with board using I^2C or SPI to offer a slution.
I am using an MPU-6050 because it offers a combination of a 3‑axis accelerometer and a 3‑axis gyroscope in one chip. It is a 16-bit ADC and offers high resolution. It can store a high amount of data and can be supported ESP32 libraries. However, the only drawback is it's high power usage. An ADXL345 is an alterantive that uses low power but only detects linear motion, unlike an PU-6050 which is more effective in all types of motions (ex.rotational).

## Getting Started

For any software prerequisites, write a simple excerpt on each
technology the participant will be expecting to download and install.
Aim to demystify the technologies being used and explain any design
decisions that were taken. Walk through the installation processes
in detail. Be aware of any operating system differences.
For hardware prerequisites, list all the necessary components that
the participant will receive. A table showing component names and
quantities should suffice. Link any reference sheets or guides that
the participant may need.
The following are stylistic examples of possible prerequisites,
customize these for each workshop.

### Required Downloads and Installations

List any required downloads and installations here.
Make sure to include tutorials on how to install them.
You can either make your own tutorials or include a link to them.
1. Arduino IDE
- visit Arduino page
- download latest version of Arduino IDE
- Launch Arduino
2. ESP32 Board Support for Arduino
- https://youtu.be/HY8MFMrGo3k?si=LE2I5AAdRno9ZNeh
3. MPU6050 library download
- https://youtu.be/I6cBs3yStf8?si=gQ7pF3agDsci_hiU

### Required Components

List your required hardware components and the quantities here.

| Component Name | Quanitity |
| -------------- | --------- |
| | |
| | |

| Component Name | Quanitity |
| -------------- | --------- |
| ESP32 DevBoard | 1 |
| MPU 6050 Acceleroneter | 1 |
|Jumper Wires | 4 |
|USB-C | 1 |
|Breadboard | 1 |
### Required Tools and Equipment
- Computer with USB-C port
- Breadboard
- Jumper Wires

List any tools and equipment you need here.
(Ex, computer, soldering station, etc.)

## Part 01: Name
## Part 01: Sensor Wiring and Communiaction

### Introduction

Briefly introduce what you are teaching in this section.
Wiring the MPU 6050 sensor to the SP32 dev board to allow them to communicate

### Objective

- List the learning objectives of this section
Connect to power and confirm the MPU-6050 adress to prove connection.

### Background Information

Give a brief explanation of the technical skills learned/needed
in this challenge. There is no need to go into detail as a
separation document should be prepared to explain more in depth
about the technical skills
- Understand how ESP32 Dev board functionality in relation to Arduino
- Learn how to connect MPU 6050 with board
- Volage compatibility, ensure both devices are compatable to avoid damages
- Debugging to confirm that the address is of the MPU 6050 sucessfully stored
- Wiring and lining pins up for pairing the devices.

### Components

- List the components needed in this challenge
- ESP32 Dev Board
- MPU 6050
- Jumper wires

### Instructional

Teach the contents of this section
1. Place components on breadboard (MPU-6050 and ESP32) so that they are alligned appropriately and GND pins allign with power rails.
2. Conmect ESP32 3V3 pin to MPU-6050 VCC pin
3. Connect ESP32 GND pin to MPU-6050 GND pin
4. Connect ESP32 SDA pin to MPU-6050 SDA pin
5. Connect ESP32 SCL pin to MPU-6050 SCL pin
6. Connect MPU-6050 pin to GND and set it's address
7. Upload I^2C sketch and verify that device is found using serial monitor

## Example

### Introduction

Introduce the example that you are showing here.
The I^2C scanner confirms that the MPU-6050 is connected and the sensor is communicating with the board effectively.

### Example

Present the example here. Include visuals to help better understanding
Example Output on Scanner:
I2C scanner
Found I2C device at "adress"
Found 1 devices

### Analysis

Explain how the example used your tutorial topic. Give in-depth analysis of each part and show your understanding of the tutorial topic
Found I2C device at "adress" tells the user that the MPU-6050 has been found and it's responding. Found device ensures that no errors have been found and the device is successfully connected.

## Additional Resources

Arduino Guide: https://www.arduino.cc/en/Guide/
MPU-6050 Datasheet: https://invensense.tdk.com/wp-content/uploads/2015/02/MPU-6000-Datasheet1.pdf
### Useful links

List any sources you used, documentation, helpful examples, similar projects etc.
(https://www.youtube.com/watch?v=RiYnucfy_rs)