
Corrector de postura
agustin-arg/Posture
Dispositivo electrónico de corrección de postura corporal

An open wearable electronics project built around an ESP32 NodeMCU-32S. The project combines activity tracking, heart-rate sensing, GPS movement data, stress estimation, a rechargeable power concept, a custom PCB, and a…
Smartwatch is an open-source printed circuit board by loueydaly, from the loueydaly/Smartwatch repository on GitHub. It is a 2-layer board of 39 × 66 mm with 8 parts on 37 nets, routed with 41 tracks and 0 vias.
It is built around the NODEMCU-32SLUA. Its parts include 4 connectors, 1 capacitor, 1 resistor, 1 IC and 1 diode. It belongs with the wearables boards and the ESP8266 boards of this library.
An open wearable electronics project built around an ESP32 NodeMCU-32S. The project combines activity tracking, heart-rate sensing, GPS movement data, stress estimation, a rechargeable power concept, a custom PCB, and a 3D-printed/mechanical smartwatch enclosure.
The repository contains three connected deliverables:
code_smartwatch/: PlatformIO firmware and a browser dashboardconception_smartwatch/: SolidWorks mechanical and component design filespcb_smartwatch/: KiCad schematic and PCB layout files
Figure 1. Mechanical render included with the smartwatch concept files.
The current firmware is designed to calculate and display:
The browser dashboard is prepared to display BPM, stress, steps, calories, and distance from JSON messages received over MQTT. The current ESP32 firmware prints these values to the USB serial console but does not yet publish MQTT messages; connecting the firmware telemetry to the dashboard is the next integration step.
MPU6050 accelerometer ─┐
├─ I2C at 400 kHz ─> ESP32 NodeMCU-32S
MAX30102 pulse sensor ─┘ │
├─ Serial2 / GPS
├─ USB serial telemetry
└─ MQTT bridge/dashboard (planned)
Battery -> power electronics -> ESP32 + sensors
Mechanical enclosure + custom KiCad PCB hold the electronics together.The firmware is located in code_smartwatch/ and uses PlatformIO with the Arduino framework. Its target is nodemcu-32s.
The project configuration includes:
The exact dependency declarations are in code_smartwatch/platformio.ini. PlatformIO downloads dependencies into .pio, which is intentionally excluded from Git.
The firmware reads acceleration on a 50 ms interval. It calculates the acceleration magnitude:
magnitude = sqrt(ax^2 + ay^2 + az^2)A step is counted when the magnitude exceeds MOTION_THRESHOLD and the cooldown interval has elapsed. The current defaults are:
| Parameter | Value |
|---|---|
| Motion threshold | 12000 |
| Step cooldown | 250 ms |
| Step update interval | 50 ms |
| Accelerometer range | +/-8 g |
| Gyroscope range | +/-500 deg/s |
| Sensor filter bandwidth | 21 Hz |
These values require calibration against the final enclosure orientation, wrist position, and user movement.
The MAX30102 is initialized on the shared I2C bus at fast speed. The firmware reads the infrared signal, detects beats using an adaptive threshold, calculates BPM from beat-to-beat intervals, and smooths the value with a ten-sample average.
The heart-rate update runs every 20 ms. Values outside the accepted 20 to 255 BPM range are ignored. The source also calculates HRV as the standard deviation of collected RR intervals and converts HRV into a heuristic stress percentage.
This is an educational signal-processing implementation, not a medical device. Optical readings depend strongly on fit, skin contact, ambient light, movement, sensor placement, and calibration.
GPS is connected to Serial2 with:
| Setting | Value |
|---|---|
| RX pin | GPIO16 |
| TX pin | GPIO17 |
| Baud rate | 9600 |
| Update interval | 1000 ms |
TinyGPSPlus parses incoming NMEA data. When a valid location is available, the firmware stores latitude, longitude, speed in km/h, and accumulated distance. Distance is calculated using the haversine formula with an Earth radius of 6,371,000 m, and movements below one meter are ignored.
Calories are estimated from two simple models:
step_calories = step_count * 0.04
distance_calories = distance_km * user_weight_kg * 1.036
calories_burned = max(step_calories, distance_calories)The current user weight is 70 kg. Stress is derived from HRV using piecewise linear mapping. Both outputs are estimates for prototyping and should not be interpreted as clinical measurements.
The main loop schedules independent update tasks:
The current inactivity timer is initialized at startup but is not refreshed by sensor activity in the checked-in code. The sleep path should be completed before relying on battery-saving behavior.
Open a monitor at 115200 baud to see startup status and periodic data similar to:
============================
Smartwatch Data
============================
Steps: 42 steps
Heart Rate: 78 BPM
Distance: 0.12 km
Calories: 4.8 kcal
Stress Level: 35.0%
GPS: 36.000000, 10.000000
Speed: 2.5 km/h
============================The GPS lines appear only after TinyGPSPlus reports a valid location.
code_smartwatch/dashboard/index.html is a static browser dashboard with cards for:
It uses the browser MQTT client library and currently connects to:
wss://test.mosquitto.org:8081The expected MQTT topic is smartwatch/parameters and the expected JSON shape is:
{
"bpm": 78,
"stress": 35,
"steps": 42,
"calories": 4.8,
"distance": 0.12
}The public broker and topic are demonstration defaults. Configure a private broker and authentication before using real personal data. A firmware MQTT client or a host-side serial-to-MQTT bridge must be added to connect the ESP32 serial output to this dashboard.
conception_smartwatch/ contains the mechanical assembly and component models, including:
These files are intended for SolidWorks. Keep the assembly references together when opening the main smartwatch assembly.
pcb_smartwatch/ contains the KiCad project:
smartwatch.kicad_pro: project settingssmartwatch.kicad_sch: schematicsmartwatch.kicad_pcb: PCB layouttest/: separate test-board schematic and layoutThe local KiCad plot/session files and backup directories are excluded from version control. Before manufacturing, run an electrical rules check, verify footprints and connector pinouts, review power and charging safety, and generate fresh fabrication outputs from the KiCad project.
code_smartwatch/ as the PlatformIO project directory.pio runpio run --target uploadpio device monitor -b 115200The upload port may need to be selected explicitly with upload_port or the PlatformIO device menu.
code_smartwatch/
platformio.ini PlatformIO target and library dependencies
src/main.cpp Sensor initialization and scheduling loop
src/functions.cpp Step, heart-rate, GPS, HRV, stress, and calorie logic
dashboard/index.html MQTT-backed browser dashboard
conception_smartwatch/
SolidWorks assemblies and component models
pcb_smartwatch/
KiCad schematic, PCB, and test-board projects
README.md Project description and setup guidespo2 exists in the data structure but is not calculated.No separate project license has been added. Add an appropriate license before distributing or publishing the repository.
| Qty | Value | Footprint | References |
|---|---|---|---|
| 3 | Conn_01x04 | Connector_JST:JST_XH_B4B-XH-AM_1x04_P2.50mm_Vertical | J1, J4, J5 |
| 1 | C_Polarized | Capacitor_THT:CP_Radial_D5.0mm_P2.50mm | C1 |
| 1 | LED | LED_THT:LED_D3.0mm | D1 |
| 1 | NODEMCU-32S | esp32 node mcu:MODULE_NODEMCU-32S | U1 |
| 1 | R | Resistor_THT:R_Axial_DIN0204_L3.6mm_D1.6mm_P2.54mm_Vertical | R1 |
| 1 | Screw_Terminal_01x02 | TerminalBlock:TerminalBlock_Altech_AK300-2_P5.00mm | J3 |
It measures 39 × 66 mm and has 2 copper layers, 1.6 mm thick.
8 parts, built around the NODEMCU-32SLUA. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.
From the loueydaly/Smartwatch repository on GitHub, at the commit this page was made from: the board is pcb_smartwatch/smartwatch.kicad_pcb and its schematic pcb_smartwatch/smartwatch.kicad_sch. PCBKit opens the board in the browser, with nothing to install.
Its repository states no licence, so its author keeps all rights: ask loueydaly before reusing the design.

agustin-arg/Posture
Dispositivo electrónico de corrección de postura corporal

unla-investigacion-desarrollo/ecosistema-iot
Antes de desarrollar el sistema final, realizamos una etapa de exploración donde investigamos y experimentamos con las siguientes tecnologías:


bytecod3/lora-life-jacket
Electronic device for life jackets with LORA data transmission

hopkinskong/eie553-iot-hardware
ESP32 IOT Smart Lock Device Hardware Schematic and PCB used in the course "EIE553 Security in Data Communication".

2026MakerClub/PCB
projects with pcb, custom and commonly used schemes, footprints...etc.

ANTzacalie/termo-pro-esp32
Full-featured smart thermostat built on the ESP32 platform.
