Você está na página 1de 19

22 dias até o Halloween - Desafiamos você a experimentar esses petiscos nojentos (mas deliciosos) de Halloween

(https://www.instructables.com/Halloween-Food/) !

Projetos Concursos Professores


Conecte-se(https://www.instructables.com/account/login/?nxtPg=) In
(/projects) (/contest) (/teachers) (/search)
(/)

(https://www.instructables.com/contest/classroom2023/?instructables)

MicroMote: o controle remoto por gestos


baseado em ESP-Now
Por Mukesh_Sankhla (/member/Mukesh_Sankhla/) em Circuitos (/circuits/) > de Controle Remoto
(/circuits/remote-control/projects/)
7.924 49 0 Apresentou

Download Favorito
auto=webp&frame=1&width=1024&
(https://content instruc

auto=webp&frame=1&width=1024&height=1024&fit=bounds&md=d62c064825fe2874aa2be52f72384940)
(https://content instructables com/FAO/1NZA/LN1RBIN3/FAO1NZALN1RBIN3 png? auto=webp&frame=1&width=1024&
(https://content instruc

Mais do
(/member/Mukesh_Sankhla/) autor:
Por
Mukesh_Sankhla Seguir
(/member/Mukesh_Sankhla/)
Sobre: ​Sou estudante de Ciência da Computação. Adoro brincar com eletrônica e códigos.
Fazendo novos projetos. Mais sobre Mukesh_Sankhla » (/member/Mukesh_Sankhla/)

Apresentando MicroMote: o controle remoto por gestos baseado em


ESP-Now

Você está pronto para assumir o controle de seus dispositivos inteligentes


com um aceno de mão? Não procure mais, MicroMote, o revolucionário
Gesture Remote baseado em ESP32 S3. Este dispositivo inovador e
compacto, medindo apenas 4 cm, foi criado para transformar a maneira
como você interage com seus aparelhos eletrônicos inteligentes, lâmpadas
e muito mais.

Características principais:

● ESP32 S3 Powerhouse: MicroMote é alimentado pelo ESP32 S3, um


microcontrolador de última geração que oferece desempenho e eficiência
aprimorados para comunicação perfeita com seus dispositivos
inteligentes.
● Tecnologia de detecção de gestos: Com um sensor de gestos integrado,
o MicroMote permite controlar seus dispositivos com movimentos
simples das mãos. Agite a mão para ajustar o volume, mudar de canal ou
diminuir as luzes – é como mágica na ponta dos dedos.
● Protocolo ESP-NOW: MicroMote utiliza o protocolo ESP-NOW para
comunicação ultrarrápida e confiável com outros dispositivos. Diga adeus
ao incômodo de processos complexos de emparelhamento e desfrute de
conectividade instantânea.
● Compacto e portátil: o formato pequeno do MicroMote o torna
incrivelmente portátil e fácil de transportar no bolso ou prender no
chaveiro. Leve-o com você aonde quer que você vá e tenha controle sobre
seus dispositivos, não importa onde você esteja.
● Ampla compatibilidade: o MicroMote foi projetado para funcionar
perfeitamente com uma variedade de aparelhos eletrônicos inteligentes,
lâmpadas e muito mais. É o seu controle remoto multifuncional para um
mundo conectado.

 Adicionar dica V Faça uma pergunta | Comente Download

Suprimentos

(https://content
auto=webp&frame=1&width=1024&height=1024
instructables com/FO1/1QS5/LN1RBIO7/F

(https://content
auto=webp&frame=1&width=1024&height=1024&fit=bounds)
instructables com/FKQ/DR76/LN1RBIO9/FKQDR76LN1RBIO9 jpg? (https://content
auto=webp&frame=1&width=1024&height=1024
instructables com/FVA/RHO7/LN1RBIO8/F
1x Estúdio Semente XIAO ESP32S3
(https://www.hackster.io/products/buy/107179?
s=BAhJIhM1MDQ0ODcsUHJvamVjdAY6BkVG%0A)

1x sensor de gesto IR inteligente Seeed Studio Grove


(https://www.hackster.io/products/buy/107178?
s=BAhJIhM1MDQ0ODcsUHJvamVjdAY6BkVG%0A)

1x Small 3.7v Lithium Polymer Battery (https://amzn.to/3PBn72B)

1x Small Screw (https://amzn.to/3EVWoJb)

1x 3D Printed Housing

1x 3D Printed Cover

Sponsored By NextPCB

This project is successfully completed because of the help and support from
NextPCB -Reliable Multilayer PCB Manufacturer. NextPCB is one of the most
experienced PCB manufacturers in Global, has specialized in the PCB and
assembly industry for over 15 years.

Order high-quality, reliable PCB starting at $1.9, multilayer starting at $6.9:

https://www.nextpcb.com/pcb-quote (https://www.nextpcb.com/pcb-
quote)

Enjoy free PCB assembly for 5 boards:

https://www.nextpcb.com/pcb-assembly-quote
(https://www.nextpcb.com/pcb-assembly-quote)

DFM free online PCB Gerber viewer:

https://www.nextpcb.com/free-online-gerber-viewer.html
(https://www.nextpcb.com/free-online-gerber-viewer.html)

 Add Tip V Ask Question | Comment Download

Step 1: Gesture Sensor Operating Plane


​(https://wiki.seeedstudio.com/grove_gesture_paj7660/#operating-
plane)The gesture operation distance is 15 to 30 cm, the farthest cannot
exceed 35 cm. Based on Sensor FOV 78.3° (horizontal) and 62.9°(vertical), and
the operating area is 48 x 36 cm² at 30 cm.

In addition to the distance to the sensor, you also need to pay attention to
where the sensor is placed. On the front of the sensor, in the upper left
corner, there is a small human shape. If you see the figure standing upright,
then you have placed it in the correct position. If it is upside down, then it is
likely that you will not get an accurate recognition result.

As background noise may impact the accuracy of gesture recognition, it is


recommended to avoid the relative higher reflective background object
behind the palm. In normal gesture recognition condition, recommend at
least 35cm distance between palm and background.

 Add Tip V Ask Question | Comment Download

Step 2: Supported Gesture Types

Finger (N=0~5): 0 ~ 5 fingers at top of fist

N Finger Push (N=1~5): 0~5 fingers move forward toward sensor

Pinch: 2-finger close to pinch, open to release

Rotation CW/CCW: Move wrist in a circular pattern

Hand Swipe Right or Left: Swipe and move both hands away from each
other for some distance

Tap: 1-finger click (fingers disappear)

Grab: 5-finger to 0-finger

Thumb Up: Thumb at top of fist

Down Thumb: at bottom of fist


Above are all the gesture types supported by the Grove Smart IR Gesture
Sensor (PAJ7660), for this MicroMote I used only the 0~5 Finger and 0~5
Fingers Push gestures. Do refer the documentation to include other gestures
in the MicroMote.
 Add Tip V Ask Question | Comment Download

Step 3: ESP-Now

auto=webp&frame=1&width=1024&height=1024&fit=bounds&md=885bf6f4dbe72c9b5dca351b91333fb
(https://content instructables com/FR9/LNCG/LN1RBKJD/FR9LNCGLN1RBKJD png?

ESP-Now, short for "Espressif Simple Protocol Now," is a wireless


communication protocol developed by Espressif Systems, a company known
for its popular ESP8266 and ESP32 series of Wi-Fi and Bluetooth-enabled
microcontrollers. ESP-Now is designed for low-power, peer-to-peer (P2P)
communication between ESP8266 and ESP32 devices. It is particularly well-
suited for IoT (Internet of Things) applications where low latency, high
reliability, and low power consumption are essential.

MicroMote is built upon the ESP-Now protocol, allowing it to transmit


various signals and messages to different ESP32-based systems. These
messages can encompass a wide range of data types, including numbers and
strings. Each receiving device can be configured with a predefined identifier
and trigger messages, enabling it to interpret incoming messages as triggers
for various actions. These actions might include turning lights on or off,
adjusting brightness levels, and many other customizable functions.
Importantly, the same message sent by the sender device can serve as a
trigger point for these actions on the receiver device, creating a versatile
and flexible communication system.

The trigger message can either be common across multiple devices or


unique to each device. This flexibility allows you to control common devices
simultaneously, as demonstrated in this example. Alternatively, you can
control individual devices separately, tailoring actions to specific needs or
preferences. This versatility provides a powerful means of managing and
customizing your IoT network to suit different scenarios and requirements.

Refer ESP-Now guide by Drone Bot Workshop


(https://dronebotworkshop.com/esp-now/) to get deep into the concept.
 Add Tip V Ask Question | Comment Download
Step 4: CAD Design and 3D Printing

auto=webp&frame=1&width=1024&height=1024&
(https://content instructables com/FGT

3 Mo
auto=webp&frame=1&width=1024&fit=bounds&md=54b5bd23d2200a8f82647837443f96e9)
(https://content instructables com/FN2/NRFC/LN1RBJDV/FN2NRFCLN1RBJDV png? auto=webp&frame=1&width=1024&height=1024&
(https://content instructables com/FSG

I designed MicroMote in Autodesk Fusion 360


(https://www.autodesk.in/products/fusion-360/overview?
panel=buy&mktvar002=afc_in_nmpi_ppc&AID=13084956&PID=8206971&gc
lid=33b0c6c4c9911feeaa89a3d03bf01794&gclsrc=3p.ds&ds_rl=1232401&ds_
rl=1232404&ds_rl=1232437&&cjevent=33b0c6c4c9911feeaa89a3d03bf01794
&click_id=33b0c6c4c9911feeaa89a3d03bf01794&gclid=33b0c6c4c9911feeaa
89a3d03bf01794&gclsrc=3p.ds&term=1-YEAR&tab=subscription&plc=F360),
I used datasheets and scale to measure the dimensions of different
components and designed the model. I have attached both stl files and the
original Fusion 360 model.

You can directly download The MicroMote stl files


(https://github.com/MukeshSankhla/MicroMote) and 3D print them.

Or

You can modify the design that I have attached in Fusion 360 software and
proceed.
MicroMote (https://a360.co/3EV0OQD)

MicroMote Abrir no Fusion 360 Fazer download

▴ ▴ ▴
w v A f d S o e C r n 

 Add Tip V Ask Question | Comment Download

Step 5: Sensor Configuration


The Grove Smart IR Gesture Sensor supports a wide range of communication
protocols with a choice of I2C, SPI and USB. The different modes are selected
directly via a 4 position DIP switch on the back.

The diagram and table below will show you how to select the mode you
wish to use with the 4 position DIP switch.

For MicroMote I used I2C protocol, so just set your gesture sensor to I2C
mode by positioning down the switch 2.

 Add Tip V Ask Question | Comment Download


Step 6: Connecting Battery

auto=webp&frame=1&width=1024&h
(https://content instructab

auto=webp&frame=1&width=1024&height=1024&fit=bounds&md=6feb36aabef939af2ec841d4cabd64d0)
(https://content instructables com/FPE/GWL4/LN1RBM6X/FPEGWL4LN1RBM6X png? auto=webp&frame=1&width=1024&h
(https://content instructa

● Begin by soldering the battery wires and header pins onto the XIAO ESP32
board.
● Use the above pin diagram for connecting battery.
● Since the XIAO ESP32 board comes with built-in battery charging circuitry
that includes overcharge protection, you can use the Type-C port on the
XIAO ESP32 to charge the connected battery. This feature simplifies your
project setup, as you won't need to implement an additional battery
charging circuit. Just plug in the Type-C cable, and the board will take care
of charging the battery safely.

 Add Tip V Ask Question | Comment Download

Step 7: XIAO ESP32 + Sensor Connection

auto=webp&frame=1&width=1024&h
(https://content instructab

auto=webp&frame=1&width=1024&height=1024&fit=bounds&md=bf4c3c8816c08c5800d970792cef7152)
(https://content instructables com/FUZ/UKZP/LN1RBKRA/FUZUKZPLN1RBKRA jpg? auto=webp&frame=1&width=1024&h
(https://content instructa
Connecting the gesture sensor to the ESP32 is a straightforward process.
Simply insert the XIAO ESP32 board directly into the Grove Gesture Sensor's
female connector, ensuring that the USB-C port on the XIAO ESP32 is
oriented outward. This plug-and-play setup makes it easy to integrate the
gesture sensor into your project.

 Add Tip V Ask Question | Comment Download

Step 8: Other Board + Sensor Connection

auto=webp&frame=1&width=1024&height=1024&fit=bounds&md=d719657a6107423c5995794dd7d07
(https://content instructables com/FHE/FIRT/LN1RBL6Z/FHEFIRTLN1RBL6Z jpg?

You have two options for connecting the gesture sensor to other boards:

1. Using Jumper Wires: If you're connecting the gesture sensor to a board


that doesn't have a Grove connector, you can use 4 jumper wires. Simply
connect GND on the sensor to GND on your board, VCC to 3.3V/Vin, SCL to
SCL, and SDA to SDA. This method allows for flexible integration with
various microcontrollers.
2. Using a Grove Cable: Alternatively, if your board supports the Grove
connector, you can use a Grove cable to easily connect the gesture
sensor. This method simplifies the connection process and is convenient if
your board has a Grove interface.

 Add Tip V Ask Question | Comment Download


Step 9: Final Assembly

auto=webp&frame=1&width=1024
(https://content instruct

auto=webp&frame=1&width=1024&height=1024&fit=bounds&md=a74e6c98c5b52c8097341d4ab1855b77)
(https://content instructables com/FVR/TV77/LN1RBM49/FVRTV77LN1RBM49 jpg? auto=webp&frame=1&width=1024&
(https://content instruc

To assemble the project:

1. Align the Type-C port on the XIAO ESP32 with the corresponding opening
in the 3D printed housing.
2. Carefully place the circuitry into the housing, ensuring that component
fits snugly.
3. Slide the top cover onto one side of the housing.
4. Use a small screw to fix the top cover securely onto the housing, ensuring
that the entire assembly is stable and well-enclosed.
 Add Tip V Ask Question | Comment Download

Step 10: Code

auto=webp&frame=1&width=1024&height=1024&fit=bounds&md=9a615b94a7a1d9b341e431c2b44c2476)
(https://content instructables com/FVW/0223/LN1RBRQ4/FVW0223LN1RBRQ4 jpg? auto=webp&frame=1&width=1024&
(https://content instruc

● Download the Grove Gesture Sensor library (https://github.com/Seeed-


Studio/Grove_Gesture/tree/dev)​
(https://wiki.seeedstudio.com/grove_gesture_paj7660/#installation)
● Since you have downloaded the zip Library, open your Arduino IDE, click
on Sketch > Include Library > Add .ZIP Library. Choose the zip file you just
downloaded,and if the library install correct, you will see Library added
to your libraries in the notice window. Which means the library is installed
successfully.

● Also you should install the Arduino ESP32 boards in board manager, you
can follow Getting Started | Seeed Studio Wiki
(https://wiki.seeedstudio.com/xiao_esp32s3_getting_started/) to install.
● Now copy paste the code, select the board type, search for xiao in the
development board on the left. select XIAO_ESP32S3, select the port and
upload the code.
Remote(Sender) Code

/* Project : MicroMote
* makerbrains.com 2023
* Author : Mukesh Sankhla
*/

#include <WiFi.h>
#include "Gesture.h"
#include <esp_now.h>

pag7660 Gesture; // Combined mode is used by default

int deviceNo = 1;

//Universal Mac Address


uint8_t broadcastAddress[] = {0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF};

//Message(Data) send and receive doc


typedef struct messageData
{
int color = 0;
} messageData;

messageData deviceData; //Local Data


messageData recData; //Received Data

i f

● Take a any ESP32 board that you have to use it as test receiver and upload
the following code.

Receiver Code

/* Project : MicroMote
* makerbrains.com 2023
* Author : Mukesh Sankhla
*/

#include <esp_now.h>
#include <WiFi.h>

//Universal Mac Address


uint8_t broadcastAddress[] = {0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF};

//Message(Data) send and receive doc


typedef struct messageData
{
int color = 0;
} messageData;

messageData deviceData; //Local Data


messageData recData; //Received Data

// Create peer interface


esp_now_peer_info_t peerInfo;

//Called when data is sent


void OnDataSent(const uint8_t *mac_addr, esp_now_send_status_t status) {
i i ( )
● After uploading the code open the terminal by connecting receiver
device, parallelly turn on the MicroMote by charging the battery and make
few gestures on the terminal you will see the incoming messages.

 Add Tip V Ask Question | Comment Download


Step 11: Conclusion
auto=webp&frame=1&width=1024&h
(https://content instructa

auto=webp&frame=1&width=1024&h
(https://content instructa
In the demonstration video, I utilized Rainbow Lights
(https://www.instructables.com/Rainbow-Lamps-Wireless-Syncronized-
Lamps/) that I had previously built as the receiver devices. The battery
shown in the project was not used and is old, so it was not functional as
intended. Therefore, I did not include the battery in my MicroMote. However,
connecting the battery is a straightforward process.

I chose not to incorporate a power ON/OFF switch in the MicroMote because


auto=webp&frame=1&width=1024&h
(https://content instructab
I plan to experiment with the Deep Sleep modes of the ESP32 in the future.
You can easily add a switch with simple additional steps if needed.

Overall, MicroMote is a fun and compact project with limitless applications.


The only limit is your creativity and how you choose to use it. If you enjoyed
this project, please let me know in the comments below. If you've recreated
or made any modifications to the project, don't forget to share your
experience in the "I Made It" section. Thank you for your interest, and see you
next time :)

 Add Tip V Ask Question | Comment Download

Be the First to Share


Did you make this project? Share it with us!

I Made It!

Recommendations
(/Build-a-DIGITAL-MAGIC-MIRROR/) (/How-to-Make-a-RC-P-51D-Mustang-Scaled-
Model-With-F/)
Build a DIGITAL MAGIC MIRROR (/Build-
a-DIGITAL-MAGIC-MIRROR/) by DIY Como fazer um modelo em escala de
Machines (/member/DIY+Machines/) in 3D Mustang RC P-51D com Fusion 360

 8
(/How-to-Make-a-RC-P-51D-Mustang-

 8
126 7.2K
47 7,1 mil

(/contest/halloween23/) (/contest/wood2023/)

 Adicionar dica

V Faça uma pergunta

| Postar comentário

Temos uma política de ser legal .


Por favor, seja positivo e construtivo.

Adicionar imagens Publicar

Categorias Sobre nós Recursos


 Circuitos  Vivendo Quem nós somos Mapa do site
(/circuits/) (/living/) (/about/) (/sitemap/)

 Oficina  Fora Por que publicar? Ajuda (/how-to-write-


(/workshop/) (/outside/) (/create/) a-great-instructable/)

 Arte  Contato (/contact/)


(/craft/) Professores
 Culinária (/teachers/)
(/cooking/)
Ache-nos

(https://www.instagram.com/instructables/) (https://www.tiktok.com/@instructables)

© 2023 Autodesk, Inc.

Termos de serviço Declaração de privacidade Configurações de privacidade| Avisos Legais e Marcas


(http://usa.autodesk.com/adsk/servlet/item?(http://usa.autodesk.com/adsk/servlet/item?Não venda ou compartilhe minhas informações Registradas
siteID=123112&id=21959721) siteID=123112&id=21292079) pessoais (http://usa.autodesk.com/legal-
| | (https://www.autodesk.com/company/legal- notices-trademarks/)
notices-trademarks/ccpa-do-not-sell)
|
(http://www.autodesk.com)

Você também pode gostar