Skip to content

Commit 8e9cfcb

Browse files
authored
Merge pull request #1 from UPB-PMRust/main
sync
2 parents e8b704c + b03aec6 commit 8e9cfcb

61 files changed

Lines changed: 1628 additions & 213 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
21.1 KB
Loading

website/versioned_docs/version-acs_cc/project/2026/adelina_maria.alexe/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ The project uses an STM32 Nucleo-U545RE-Q as the main microcontroller board, fea
5555
### Schematics
5656

5757
<!-- TODO: Add KiCad schematic exported as SVG -->
58-
<!--![Schematic](schematic.svg)-->
58+
![Schematic](images/schematic.webp)
5959

6060
### Bill of Materials
6161

website/versioned_docs/version-acs_cc/project/2026/alexandru.birsan02/images/diagram.svg

Lines changed: 3 additions & 0 deletions
Loading
Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
# Polargraph
2+
A vertical drawing machine that uses a polar coordinate system to create pen-on-paper art
3+
4+
:::info
5+
6+
**Author**: Alexandru-Vlad Bîrsan \
7+
**GitHub Project Link**: https://github.com/UPB-PMRust-Students/acs-project-2026-vldxndr
8+
9+
:::
10+
11+
## Description
12+
13+
Polargraph - Vertical Plotter
14+
15+
The Polargraph is a vertical DRP (Digital Reconstruction Plotter) that operates on a polar coordinate system. Unlike the traditional plotter or printer that works on a X Y axis the polargrah transforms polar coordinates into coordonates on the paper by using two motors fixed over the paper that hold wires that have variable lenghts so they can position the drawing tool where it needs to be.
16+
17+
18+
## Motivation
19+
20+
The idea came to me because I have previously studied architecture and have always wanted to have something that could draw using real writing utensils, because while a printer can draw exactly what you want using pin point accuracy it lacks the soul of a hand drawing. This project aims to have the accuracy of a printer while portraying a hand rendered drawing.
21+
22+
23+
## Architecture
24+
25+
![Diagram](./images/diagram.svg)
26+
27+
## Log
28+
29+
### Week 27 - 30 April
30+
31+
Wrote initial documentation and made the first diagram while ordering the parts. Decided to use preexisting software for transforming drawings into lists of instructions.
32+
33+
### Week 12 - 18 May
34+
35+
### Week 19 - 25 May
36+
37+
## Hardware
38+
39+
The Polargraph is powered by an external 12V DC source to ensure constant torque for the stepper motors. For development purposes, the STM32 Nucleo is tethered via USB for real-time G-Code streaming and debugging
40+
41+
### Schematics
42+
43+
44+
### Bill of Materials
45+
46+
| Device | Usage | Price |
47+
| :--- | :--- | :--- |
48+
| [STM32 Nucleo-U545](https://www.st.com/en/microcontrollers-microprocessors/stm32u545.html) | Main Controller (Brain of the project) | [Owned] |
49+
| [NEMA 17 Stepper Motor (1.7A)](https://www.optimusdigital.ro/ro/motoare-pas-cu-pas/106-motor-pas-cu-pas-nema-17-40mm-17a.html) | Axis movement (2 pieces required) | [130 RON](https://www.optimusdigital.ro) |
50+
| [TMC2208 Stepper Driver](https://www.optimusdigital.ro/ro/drivere-motoare-pas-cu-pas/2753-driver-motor-pas-cu-pas-tmc2208.html) | Silent motor control (2 pieces required) | [90 RON](https://www.optimusdigital.ro) |
51+
| [SG90 Micro Servo](https://www.optimusdigital.ro/ro/servomotoare/9-servomotor-sg90.html) | Pen lift mechanism | [15 RON](https://www.optimusdigital.ro) |
52+
| [12V 5A Power Supply](https://www.optimusdigital.ro/ro/surse-de-alimentare/123-sursa-de-alimentare-12v-5a.html) | External power for stepper motors | [55 RON](https://www.optimusdigital.ro) |
53+
| [GT2 Pulleys & Belt Kit](https://www.optimusdigital.ro/ro/curele-si-fulii/145-fulie-gt2-20-dinti-5mm.html) | Mechanical transmission system | [40 RON](https://www.optimusdigital.ro) |
54+
| [Breadboard MB-102](https://www.optimusdigital.ro/ro/prototipare/10-breadboard-830-puncte.html) | Prototyping and circuit connections | [15 RON](https://www.optimusdigital.ro) |
55+
| [Jumper Wires M-M / F-M](https://www.optimusdigital.ro/ro/fire-conectori-si-socluri/894-set-fire-tata-tata-65-buc.html) | Connecting components to Nucleo | [15 RON](https://www.optimusdigital.ro) |
56+
| [DC Jack Adapter](https://www.optimusdigital.ro/ro/fire-conectori-si-socluri/124-mufa-dc-mama-cu-terminal-block.html) | Connecting the 12V supply to breadboard | [5 RON](https://www.optimusdigital.ro) |
57+
| [Capacitor Kit (100uF)](https://www.optimusdigital.ro/ro/componente-pasive/220-condensator-electrolitic-100uf-35v.html) | Power spike protection for drivers | [5 RON](https://www.optimusdigital.ro) |
58+
59+
60+
## Software
61+
62+
| Library | Description | Usage |
63+
| :--- | :--- | :--- |
64+
| [stm32u5xx-hal](https://github.com/stm32-rs/stm32u5xx-hal) | Hardware Abstraction Layer | Managing GPIO for motor control, UART for G-Code streaming, and Timers for pulse generation. |
65+
| [embedded-hal](https://github.com/rust-embedded/embedded-hal) | Embedded Abstraction Traits | Provides a standard interface for peripheral drivers, ensuring modular and testable code. |
66+
| [micromath](https://github.com/tarkentat/micromath) | Fast Math Library | Used for efficient fixed-point and floating-point square root calculations in the Inverse Kinematics engine. |
67+
| [cortex-m-rt](https://github.com/rust-embedded/cortex-m-rt) | Startup and Runtime | Handles the entry point and reset handler for the ARM Cortex-M33 processor. |
68+
| [panic-halt](https://github.com/rust-embedded/panic-halt) | Panic Handler | Provides a simple panic strategy that halts the processor in case of critical software errors. |
69+
70+
71+
#### Host Software & Toolchain
72+
73+
To transform digital images into physical drawings, the project uses a multi-step toolchain:
74+
75+
1. **Vectorization/G-Code Generation**: I use DrawingBotV3 (or Inkscape with G-Code extensions). These tools allow me to convert standard images (JPG/PNG) into paths using algorithms like *Squiggle*, *TSP (Travelling Salesman Problem)*, or *Stippling*.
76+
2. **Path Optimization**: The software generates a list of G-Code commands (`G0`, `G1`) which represent coordinates in a Cartesian system.
77+
78+
## Links
79+
80+
1. [DrawingBotV3](https://drawingbotv3.com/) - The primary software for G-Code generation.
81+
2. [Polargraph Physics](https://github.com/euphy/polargraph/wiki/Polargraph-physics) - Detailed explanation of the inverse kinematics involved.
82+
3. [TMC2208 Datasheet](https://www.trinamic.com/fileadmin/assets/Products/ICs_Documents/TMC220x_TMC2224_datasheet_Rev1.09.pdf) - Technical specifications for the motor drivers.
83+
4. [Example](https://www.youtube.com/watch?v=aiw3hkDvp-M) - Working example

website/versioned_docs/version-acs_cc/project/2026/ana.mardaloescu2802/architecture.svg

Lines changed: 4 additions & 0 deletions
Loading
Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
# Portable Peak Flow Meter with Asthma Journal
2+
A portable medical device that measures lung function and tracks asthma evolution over time.
3+
4+
:::info
5+
6+
**Author**: Mardaloescu Ana \
7+
**GitHub Project Link**: [UPB-PMRust-Students/acs-project-2026-anamardaloescu2802](https://github.com/UPB-PMRust-Students/acs-project-2026-anamardaloescu2802)
8+
9+
:::
10+
11+
<!-- do not delete the \ after your name -->
12+
13+
## Description
14+
15+
A handheld peak flow meter built around the STM32U545 microcontroller that measures PEF (Peak Expiratory Flow) and FEV1 by analyzing differential pressure generated when the user exhales forcefully into a calibrated tube. Results are displayed in real time as a waveform graph on a 2.4" touchscreen TFT display, compared against the user's personal best and color-coded via an RGB LED, timestamped using a DS3231 real-time clock module, logged to a microSD card, and transmitted via Bluetooth to a mobile device for long-term trend visualization.
16+
17+
## Motivation
18+
19+
What motivated me specifically to chose this project was the gap between what exists and what patients actually need. Clinical spirometers are accurate but expensive and confined to hospitals. Cheap plastic peak flow meters give a single number with no history and no connectivity. I wanted to design something in between: a portable device that logs every measurement with an accurate timestamp, visualizes trends over time, and lets the patient share real data with their doctor at the next appointment instead of trying to describe how they have been feeling from memory.
20+
21+
## Architecture
22+
23+
- **Pressure sensor** (**MPXV7002DP**) measures the pressure difference generated when the user exhales through a **PVC tube** with a **calibrated 6mm orifice**. The output voltage is stepped down from **5V to 3.3V** via a **resistive voltage divider** before reaching the microcontroller.
24+
25+
- **STM32U545** samples the sensor at **~1kHz**, applies **Bernoulli's equation** to convert pressure into airflow **(L/min)**, detects the **PEF peak**, and computes **FEV1** by numerically integrating the **first second** of the flow curve.
26+
27+
- **TFT touchscreen** displays the **exhalation waveform** in real time and shows the final **PEF** and **FEV1** values at the end of each measurement. It also handles all **user input**, replacing physical buttons entirely.
28+
29+
- **RGB LED** provides an immediate **visual zone indicator****green**, **yellow**, or **red** — based on how the current **PEF** compares to the user's stored **personal best**.
30+
31+
- **MicroSD card** logs every measurement as a **timestamped CSV entry**, with accurate date and time provided by the **DS3231** real-time clock module.
32+
33+
- **Bluetooth module** transmits measurement data wirelessly to an **Android device** for **long-term trend visualization**.
34+
35+
![Architecture diagram](architecture.svg)
36+
37+
## Log
38+
39+
<!-- write your progress here every week -->
40+
41+
### Week 5 - 11 May
42+
Defined the concept of a portable respiratory monitoring device (peak flow meter).
43+
Chosen STM32 as the main microcontroller.
44+
Outlined system architecture and main hardware components.
45+
46+
### Week 12 - 18 May
47+
Selected main hardware components: pressure sensor, TFT display, RTC, microSD, Bluetooth module.
48+
Designed initial schematic and defined communication interfaces (SPI, I2C, UART, ADC).
49+
Completed STM32 pin mapping.
50+
Finalized system architecture and data flow (sensing, processing, display, logging, communication).
51+
Prepared system for firmware implementation and hardware testing.
52+
53+
### Week 19 - 25 May
54+
55+
## Hardware
56+
57+
- The heart of the device is the STM32U545 microcontroller, which handles all ADC sampling, signal processing, display rendering, and peripheral communication.
58+
- The MPXV7002DP differential pressure sensor is the most critical component — it measures the pressure drop across a 6mm calibrated orifice in the exhalation tube and converts it into a voltage that the STM32 reads through a resistive voltage divider, since the sensor outputs up to 5V while the STM32 ADC accepts a maximum of 3.3V.
59+
- The 2.4 inch TFT shield combines the ILI9341 display and an XPT2046 resistive touchscreen controller on a single board, handling both waveform visualization and all user input without the need for physical buttons.
60+
- The microSD module connects over the same SPI bus as the display using a dedicated chip select line and stores every measurement as a CSV file.
61+
- The DS3231 real-time clock module communicates over I2C and ensures every log entry carries an accurate date and time even after the device is powered off and back on.
62+
- The Bluetooth module handles wireless data transfer to an Android phone over a USART serial link.
63+
- The RGB LED is driven directly from three GPIO pins through current-limiting resistors and lights up green, yellow, or red depending on how the current measurement compares to the stored personal best.
64+
65+
### Schematics
66+
67+
![Full system schematic](schematic.svg)
68+
69+
70+
### Bill of Materials
71+
72+
<!-- Fill out this table with all the hardware components that you might need.
73+
74+
The format is
75+
```
76+
| [Device](link://to/device) | This is used ... | [price](link://to/store) |
77+
78+
```
79+
80+
-->
81+
82+
| Device | Usage | Price |
83+
|--------|--------|-------|
84+
| STM32U545 Development Board | Main microcontroller | - |
85+
| [MPXV7002DP Pressure Sensor Module](https://www.optimusdigital.ro/ro/senzori-senzori-de-presiune/1163-modul-senzor-de-presiune-mpxv7002dp.html) | Differential pressure measurement | 279.00 RON |
86+
| [DS3231 Real Time Clock Module](https://www.optimusdigital.ro/ro/altele/12432-modul-cu-ceas-in-timp-real-ds3231-fara-baterie.html) | Accurate timestamping for CSV log | 15.98 RON |
87+
| [Assorted LED Kit 310pcs + Resistors](https://www.optimusdigital.ro/ro/kituri-optimus-digital/9517-set-de-led-uri-asortate-de-5-mm-si-3-mm-310-buc-cu-rezistoare-bonus.html) | RGB LED indicator + current limiting resistors + voltage divider resistors | 26.99 RON |
88+
| [Bluetooth 4.0 Module with Adapter](https://www.optimusdigital.ro/ro/wireless-bluetooth/635-modul-cu-bluetooth-40-si-adaptor-compatibil-33v-si-5v.html) | Wireless data transmission to Android phone | 29.99 RON |
89+
| [4x Breadboard Combo SYB-500](https://www.optimusdigital.ro/ro/kituri/12463-set-4-breadboard-uri-combo-syb-500.html) | Prototyping | 49.99 RON |
90+
| [2.4" TFT Touchscreen Shield](https://www.optimusdigital.ro/ro/lcd-uri/3544-shield-cu-display-tft-cu-touchscreen-de-24.html) | Real-time waveform display and touch menu navigation | 65.44 RON |
91+
| [MicroSD Card Slot Module](https://www.optimusdigital.ro/ro/memorii/1516-modul-slot-card-compatibil-cu-microsd.html) | CSV measurement logging | 4.39 RON |
92+
| [Jumper Wires M-M 20cm (x10)](https://www.optimusdigital.ro/ro/fire-fire-cu-mufe/880-set-10-fire-colorate-separate-tata-tata-de-20-cm.html) | Breadboard connections | 5.95 RON |
93+
| [Jumper Wires F-M 20cm (x10)](https://www.optimusdigital.ro/ro/fire-fire-cu-mufe/879-fire-colorate-mama-tata-10p-20-cm.html) | Breadboard connections | 15.96 RON |
94+
| [Jumper Wires F-F 20cm (x10)](https://www.optimusdigital.ro/ro/fire-fire-cu-mufe/881-set-10-fire-colorate-separate-mama-mama-de-20-cm.html) | Breadboard connections | 9.90 RON |
95+
| [100nF Capacitors](https://www.optimusdigital.ro/ro/componente-electronice-condensatoare/27-capacitor-100nf50-pcs-set.html) | Sensor power supply decoupling | ~5 RON |
96+
| PVC tube 20mm + silicone tubing | Exhalation channel and sensor port connection | ~10 RON |
97+
98+
**Total: 519 RON**
99+
100+
## Software
101+
102+
| Library | Description | Usage |
103+
|---------|-------------|-------|
104+
| [st7789](https://github.com/almindor/st7789) | Display driver for ST7789 | Used for the display for the Pico Explorer Base |
105+
| [embedded-graphics](https://github.com/embedded-graphics/embedded-graphics) | 2D graphics library | Used for drawing to the display |
106+
107+
## Links
108+
109+
<!-- Add a few links that inspired you and that you think you will use for your project -->
110+
111+
1. [MPXV7002DP Datasheet - NXP](https://www.nxp.com/docs/en/data-sheet/MPXV7002.pdf)
112+
2. [How a peak flow meter works - Asthma UK](https://www.asthma.org.uk/advice/manage-your-asthma/peak-flow/)
113+
3. [Bernoulli equation for flow measurement](https://www.engineeringtoolbox.com/bernoulli-equation-d_183.html)

website/versioned_docs/version-acs_cc/project/2026/ana.mardaloescu2802/schematic.svg

Lines changed: 5 additions & 0 deletions
Loading
30.2 KB
Loading
Lines changed: 136 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,136 @@
1+
# Self-Balancing Cube
2+
3+
A self-balancing cube controlled by an STM32 microcontroller, using IMU feedback and internal reaction wheels to balance on an edge or corner.
4+
5+
:::info
6+
7+
**Author**: Ana-Maria-Raluca Lupu \
8+
**GitHub Project Link**: [acs-project-2026-lupuana](https://github.com/UPB-PMRust-Students/acs-project-2026-lupuana)
9+
10+
:::
11+
12+
<!-- do not delete the \ after your name -->
13+
14+
## Description
15+
16+
This project implements a self-balancing cube based on reaction-wheel control. The system reads motion and orientation data from an IMU sensor, estimates the cube state, and computes corrective motor commands in real time. Three internal motors spin reaction wheels to generate stabilizing torques, allowing the cube to recover balance and remain upright on an edge or corner.
17+
18+
## Motivation
19+
20+
I chose this project because it combines embedded programming, control systems, electronics, mechanical design, and real-time testing in a single system. It is a good practical challenge because it requires both hardware integration and software development, especially sensor processing, feedback control, and actuator coordination on an STM32 platform.
21+
22+
## Architecture
23+
24+
The main architecture components of the project are:
25+
26+
- **Sensing layer**
27+
Reads acceleration and angular velocity data from the IMU.
28+
29+
- **State estimation layer**
30+
Processes raw IMU data and computes the current orientation and angular motion of the cube.
31+
32+
- **Control layer**
33+
Runs the balancing algorithm and computes correction values for each axis.
34+
35+
- **Actuation layer**
36+
Sends control signals to the three reaction-wheel motors.
37+
38+
- **Communication and tuning layer**
39+
Allows calibration and parameter adjustment through a Bluetooth serial connection.
40+
41+
- **Power layer**
42+
Supplies the motors directly from the battery and powers the logic through a regulated 5V rail.
43+
44+
### Architecture Diagram
45+
46+
```mermaid
47+
flowchart LR
48+
subgraph PWR["Power Layer"]
49+
BATT["3S LiPo Battery 11.1V, 500mAh"]
50+
REG["5V Regulator"]
51+
BUZ["5V Buzzer"]
52+
end
53+
54+
subgraph SENS["Sensing Layer"]
55+
IMU["MPU6050 IMU"]
56+
end
57+
58+
subgraph PROC["Processing and Control"]
59+
STM["STM32 Microcontroller"]
60+
STATE["State Estimation"]
61+
CTRL["Control Algorithm"]
62+
CAL["Calibration and Parameter Tuning"]
63+
end
64+
65+
subgraph COMM["Communication Layer"]
66+
BT["HC-05 Bluetooth Module"]
67+
USER["User / Serial Commands"]
68+
end
69+
70+
subgraph ACT["Actuation Layer"]
71+
MOT["3x Brushless Motors / Reaction Wheels"]
72+
end
73+
74+
subgraph PHY["Physical System"]
75+
CUBE["Self-Balancing Cube"]
76+
end
77+
78+
IMU -->|Motion data| STM
79+
STM --> STATE
80+
STATE --> CTRL
81+
CTRL -->|Motor commands| MOT
82+
MOT -->|Stabilizing torque| CUBE
83+
CUBE -->|Motion/orientation changes| IMU
84+
85+
USER -->|Bluetooth commands| BT
86+
BT --> CAL
87+
CAL --> STM
88+
89+
BATT -->|11.1V| MOT
90+
BATT --> REG
91+
REG -->|5V| STM
92+
REG -->|5V| IMU
93+
REG -->|5V| BT
94+
REG -->|5V| BUZ
95+
96+
```
97+
98+
## Log
99+
100+
### Week 14 - 29 April
101+
102+
- Finalized project theme and received approval.
103+
- Researched and ordered components.
104+
105+
### Week 4 - 10 May
106+
107+
- Components arrived
108+
109+
### Week 11 - 17 May
110+
111+
- Tested components separately
112+
- Started assembling the project
113+
114+
## Hardware
115+
116+
The hardware platform is built around an STM32 microcontroller, an MPU6050 IMU for motion sensing, three brushless motors with encoders for the reaction wheels, a 3S LiPo battery for power, a 5V regulator for the logic section, a Bluetooth module for tuning, and a buzzer for status feedback.
117+
118+
## Schematics
119+
120+
![Schematics](./images/schematic.webp)
121+
122+
## Bill of Materials
123+
124+
| Device | Usage | Price | Link |
125+
|---|---|---:|---|
126+
| Dupont wire kit | Prototyping and signal wiring | 24.39 RON | [AliExpress](https://www.aliexpress.com/item/4000203371860.html?spm=a2g0o.order_list.order_list_main.5.b7a61802PaQuli) |
127+
| 2x MPU6050 GY-521 | IMU sensing | 48.84 RON | [AliExpress](https://www.aliexpress.com/item/1005008796700745.html?spm=a2g0o.order_list.order_list_main.11.b7a61802PaQuli) |
128+
| 3x Nidec 24H brushless servo motors | Reaction-wheel actuation | 138.57 RON | [AliExpress](https://www.aliexpress.com/item/1005005779471604.html?spm=a2g0o.order_list.order_list_main.17.b7a61802PaQuli) |
129+
| HC-05 Bluetooth module | Wireless tuning and calibration | 24.35 RON | [AliExpress](https://www.aliexpress.com/item/32582656795.html?spm=a2g0o.order_list.order_list_main.23.b7a61802PaQuli) |
130+
| 3S LiPo 11.1V 500mAh battery | Main power source | 85.33 RON | [AliExpress](https://www.aliexpress.com/item/1005006702079264.html?spm=a2g0o.order_list.order_list_main.29.b7a61802PaQuli) |
131+
| Active 5V buzzer | Audio feedback / status signal | 15.72 RON | [AliExpress](https://www.aliexpress.com/item/1005010321957502.html?spm=a2g0o.order_list.order_list_main.35.b7a61802PaQuli) |
132+
| LM7805 5V regulator module | Logic power regulation | 16.72 RON | [AliExpress](https://www.aliexpress.com/item/1005005382976127.html?spm=a2g0o.order_list.order_list_main.41.b7a61802PaQuli) |
133+
| 3S LiPo balance charger | Battery charging | 28.24 RON | [AliExpress](https://www.aliexpress.com/item/1005007620618797.html?spm=a2g0o.order_list.order_list_main.47.b7a61802PaQuli) |
134+
| ON/OFF switch | Main power control | 21.29 RON | [AliExpress](https://www.aliexpress.com/item/1005009232308550.html?spm=a2g0o.order_list.order_list_main.53.b7a61802PaQuli) |
135+
136+
## Software

0 commit comments

Comments
 (0)