Skip to content

Commit 52bb87b

Browse files
Project/ali.khalghamouz (#1350)
* docs: -added kicad scheme and hardware mvp photo * update: full revamp of personal page. * fix: Links order * fix: kicadscheme.webp resolution * fix: embedded image check fail * Update website/versioned_docs/version-fils_en/project/2026/ali.khalghamouz/index.md Co-authored-by: Omer Genan <81963672+genan2003@users.noreply.github.com> * Update website/versioned_docs/version-fils_en/project/2026/ali.khalghamouz/index.md Co-authored-by: Omer Genan <81963672+genan2003@users.noreply.github.com> --------- Co-authored-by: Omer Genan <81963672+genan2003@users.noreply.github.com>
1 parent 1767186 commit 52bb87b

8 files changed

Lines changed: 57 additions & 46 deletions

File tree

website/versioned_docs/version-fils_en/project/2026/ali.khalghamouz/architecture.svg

Lines changed: 0 additions & 4 deletions
This file was deleted.
8.06 KB
Loading
37.6 KB
Loading
36.7 KB
Loading
20.6 KB
Loading
66.5 KB
Loading
Lines changed: 57 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# OxiNMP
2-
Digital Signal Processing on a INMP microphone, having multiple voice effects chosen by the user.
2+
A visualiser of your voice and a game where you can also use your voice as a controller
33

44
:::info
55

@@ -12,68 +12,76 @@ Digital Signal Processing on a INMP microphone, having multiple voice effects ch
1212

1313
## Description
1414

15-
My project's purpose is to have multiple integrated DSP algorithms (aiming to implement 4) that transform the captured audio into audio with multiple effects, kind of like a Voice Changer. I aim to have an 8-bit Retro audio effect, a high pitch effect, a low pitch effect and a sci-fi sounding effect (kind of like Dalke).
15+
My project's purpose is to use my voice to control different stuff. My first Idea was a waveform analyzer, but then as I procrastinated (like everyone, on short-form content) I came across another one of those type of filter-game videos( the one with flappy birds controlled by your voice), so.... another state to my loop was added: FlappyApp!
1616

1717
## Motivation
1818

19-
Choosing this project was because of a mix of my interest in mathematics and wanting to learn DMA (used for audio input/output leaving the processor more power to do the DSP required for the sound effects)more in-depth.
19+
Choosing this project was because of a mix of my interest in mathematics, signals and wanting to learn DMA (used for audio input/output and SPI, leaving the processor more power to render the states of the display) more in-depth.
2020

2121
## Architecture
2222

2323
- **INMP441 Module:** It sends clean digital audio arryas straight to the STM32 via I2S
24-
- **STM32:** Calculates FFT to draw on the screen and the algorithms for the audio effects.
25-
- **UDA1334A:** Takes the I2S output from the STM32 and outputs it into a 3.5mm Jack where you connect speakers or headphones.
24+
- **STM32U545REQ:** Provides the User Button, computing power, and a (quite helpful for my waveform analyzer) FPU for my project.
2625
- **SPI TFT LCD Display:** Chose an SPI screen over a I2C screen because it handles video better than I2C. I2C is too slow for smooth video.
2726

2827

29-
![Architecture Diagram](./architecture.svg)
28+
![Architecture Diagram](./architecture.webp)
3029

3130
## Log
3231

3332
<!-- write your progress here every week -->
3433

35-
### Week 5 - 11 May
34+
### The 3 Week Sprint (*week 12,13,14*)
3635

37-
### Week 12 - 18 May
36+
**Disclaimer: This project was partailly changed as you probably saw (previously, a DSP and sound visualiser) because of my AMAZING soldering skills and AMAZING electronics knowledge (I burnt my first DAC and couldn't get the 2nd one to work properly...) I suspected many things, including low impedance headphones, but none of my fixes quite worked and reached a good conclusion. So I did what an engineer would and found another way to use the components I already had in Week 2**
37+
#### Week I
38+
This week was a week of just learning stuff, understanding and, well headaches with the clock tree diagram from the official stm datasheet... I needed to understand the MSIS and Master Clock and PLL math so I can run my board at 160Mhz for the purpose of running the Screen at a smoother 20Mhz.
39+
I configured the PLL by the end of the week, set up the Mic and read a lot about buffers (ring buffers, DMA)
40+
#### Week II
41+
Week 2 I thought about my project (this was the week where I realised I couldn't possibly get my DAC work and I tried a lot of DMA fixes and everything I could find online...)
42+
After pivoting to this Visualiser and Game Idea I mapped out a state machine and how the display would work and the game logic for optimizing SPI so It doesn't run at 2 frames per second. I thought about how the pipes of the game would appear/dissapear so I don't update the display at every game event(moving forward, pipes appearing on-screen, dying, etc)
43+
#### Week III
44+
Final week(this was a packed week):
45+
Added DC Cut Off filter. Layered out my files and directories to be easy to access and read. Soldered everything together on a perfboard again and actually got better audio. Added game logic and Visualiser logic (optimized for the SPI display). Final polishes and good luck to me!
3846

39-
### Week 19 - 25 May
4047

4148
## Hardware
4249

43-
Microcontroller: STM32U545RE Nucleo (Core logic)
50+
Microcontroller: STM32U545RE Nucleo (Core logic + User Button)
4451

4552
Input: INMP441 I2S Microphone (Captures audio)
4653

47-
Output: UDA1334A I2S DAC (Plays audio)
54+
Display: SPI TFT LCD (Shows States: Menu -> Flappy -> Visualiser)
4855

49-
Display: SPI TFT LCD (Shows visualizer)
56+
**First Iteration (MVP):**
5057

51-
Interface: 4x Tactile Buttons (Changes effects)
58+
![hardware_phase_one](./hardware_one.webp)
5259

53-
**Assembled hardware shown below (MVP):**
60+
*My amazing Soldering Skills(failed attempt):*
5461

55-
![hardware_phase_one](./hardware_one.webp)
62+
![hardware_phase_two](./hardware_failed.webp)
5663

57-
### Schematics
64+
**My final iteration of this project's hardware**
5865

59-
![KiCad Schematic](./kicadscheme.svg)
66+
I used a star point for 3V3 and GND. I tried keeping wires as short as possible (4-10cm) because of the SPI and I2S connection as these can be really skewed from the electromagnetic fields generated by the current (wires act as antennas).
67+
I could have also soldered a capacitor between 3V3 and GND but didn't have any at my disposal and the electrical noise was quite manageable, so I was satisfied.
6068

61-
### Bill of Materials
69+
![hardware_phase_three](./hardware_final_one.webp)
70+
71+
![hardware_phase_three](./hardware_final_two.webp)
6272

63-
<!-- Fill out this table with all the hardware components that you might need.
73+
![hardware_phase_three](./hardware_final_three.webp)
6474

65-
The format is
66-
```
67-
| [Device](link://to/device) | This is used ... | [price](link://to/store) |
75+
### Schematics
6876

69-
```
77+
![KiCad Schematic](./kicadscheme.webp)
78+
79+
### Bill of Materials
7080

71-
-->
7281
| Device | Usage | Price |
7382
|--------|--------|-------|
7483
|[STM32 Nucleo-U545RE](__https://www.st.com/en/evaluation-tools/nucleo-u545re.html__) | The microcontroller | [Borrowed]() |
7584
| [INMP441 I2S Microphone](__https://invensense.tdk.com/products/inmp441/__) | Captures ambient audio digitally via I2S, bypassing analog ADC noise. | [21 RON](__https://www.bitmi.ro/module-electronice/modul-microfon-omnidirectional-interfata-i2s-mems-inmp441-11003.html__) |
76-
| [UDA1334A I2S DAC Module](__https://learn.adafruit.com/adafruit-i2s-stereo-decoder-uda1334a__) | Decodes processed digital audio to an analog signal via a 3.5mm jack. | [37 RON](__https://www.emag.ro/decodor-dac-stereo-uda1334a-convertor-digital-analogic-i2s-3-3-v-5-v-s-038/pd/D9WPHR3BM__) |
7785
| [ILI9341 3.2" TFT LCD Touchscreen](__https://www.adafruit.com/product/1743__) | Displays UI, audio visualizations, and status information; touch input via SPI. | [84 RON](__https://www.emag.ro/display-tft-lcd-3-2-inch-320x240-touchscreen-14pini-spi-ili9341-arduino-rx407/pd/D7Q411YBM/__) |
7886
| [Starting Electronics Kit](__https://www.emag.ro/kit-start-componente-electronice-ai777/pd/DXRJ4TMBM/__) | Contains Miscellaneous components like resistors,breadboard,etc | [51 RON](__https://www.emag.ro/kit-start-componente-electronice-ai777/pd/DXRJ4TMBM/__) |
7987

@@ -82,23 +90,30 @@ The format is
8290

8391
| Library | Description | Usage |
8492
|---------|-------------|-------|
85-
| [embassy-stm32](https://crates.io/crates/embassy-stm32) | Hardware Abstraction Layer for STM32 | Used for accessing I2S, SPI, DMA, and GPIO peripherals asynchronously. |
86-
| [embassy-executor](https://crates.io/crates/embassy-executor) | Async runtime for embedded systems | Used for managing and scheduling concurrent tasks (audio pipeline, UI, buttons). |
87-
| [embassy-sync](https://crates.io/crates/embassy-sync) | Synchronization primitives for async | Used for safely passing audio data buffers between async tasks via channels. |
88-
| [embedded-graphics](https://crates.io/crates/embedded-graphics) | `no_std` 2D graphics library | Used for drawing the real-time audio waveforms and frequency bars on the display. |
89-
| [mipidsi](https://crates.io/crates/mipidsi) | Display driver for MIPI DSI displays | Used as the hardware driver for the ILI9341 or ST7789 SPI TFT LCD. |
90-
| [microfft](https://crates.io/crates/microfft) | Fast Fourier Transform library for `no_std` | Used for calculating the frequency spectrum for the audio visualizer. |
91-
92-
93+
| [embassy-stm32](https://crates.io/crates/embassy-stm32) | Hardware Abstraction Layer (HAL) for STM32 microcontrollers | Async Embassy framework for STM32 peripherals |
94+
| [embassy-executor](https://crates.io/crates/embassy-executor) | Lightweight `no_std` async executor | Task scheduling and execution on embedded systems |
95+
| [embassy-sync](https://crates.io/crates/embassy-sync) | Synchronization primitives for Embassy | Signals, channels, and mutexes between async tasks |
96+
| [embassy-time](https://crates.io/crates/embassy-time) | Timekeeping and timer utilities | Delays, timeouts, and periodic timers |
97+
| [embassy-futures](https://crates.io/crates/embassy-futures) | Future extensions and utilities | Combining and managing async futures |
98+
| [embassy-embedded-hal](https://crates.io/crates/embassy-embedded-hal) | Bridge between Embassy and `embedded-hal` traits | Compatibility with standard embedded-hal drivers |
99+
| [embedded-graphics](https://crates.io/crates/embedded-graphics) | 2D graphics library for embedded systems | Drawing primitives, text, and shapes on displays |
100+
| [mipidsi](https://crates.io/crates/mipidsi) | Display driver framework for MIPI DSI/SPI displays | Driving the ILI9341 screen |
101+
| [heapless](https://crates.io/crates/heapless) | Stack-allocated data structures | Strings and Vecs without dynamic memory allocation |
102+
| [defmt](https://crates.io/crates/defmt) & [defmt-rtt](https://crates.io/crates/defmt-rtt) | Efficient deferred formatting framework | Logging over RTT during development |
103+
| [cortex-m](https://crates.io/crates/cortex-m) & [cortex-m-rt](https://crates.io/crates/cortex-m-rt) | Low-level Cortex-M hardware access and startup runtime | Core ARM peripheral access and boot initialization |
104+
| [panic-probe](https://crates.io/crates/panic-probe) | Panic handler for `defmt` and `probe-run` | Printing panic messages and exiting cleanly |
105+
| [static_cell](https://crates.io/crates/static_cell) | Safe lock-free static variable initialization | Initializing DMA buffers and drivers as statics |
106+
| [embedded-hal-bus](https://crates.io/crates/embedded-hal-bus) | Utilities for sharing SPI/I2C buses | Safely sharing buses among multiple devices |
107+
| [cortex-m-semihosting](https://crates.io/crates/cortex-m-semihosting) | Semihosting support for Cortex-M | Debug I/O via the debug probe connection |
93108

94109
<!-- Add a few links that inspired you and that you think you will use for your project -->
95110
## Links
96-
97-
1. [Embassy-rs Official Book](https://embassy.dev/book/)
98-
2. [STM32 NUCLEO-U545RE Board Documentation](https://www.st.com/en/evaluation-tools/nucleo-u545re.html#documentation)
99-
3. [INMP441 I2S Digital Microphone Official Datasheet](https://invensense.tdk.com/wp-content/uploads/2015/02/INMP441.pdf)
100-
4. [Adafruit UDA1334A I2S DAC Guide](https://learn.adafruit.com/adafruit-i2s-stereo-decoder-uda1334a/overview)
101-
5. [embedded-graphics Rust Crate Documentation](https://docs.rs/embedded-graphics/latest/embedded_graphics/)
102-
6. [mipidsi Rust Crate Documentation](https://docs.rs/mipidsi/latest/mipidsi/)
103-
7. [microfft Rust Crate Documentation](https://docs.rs/microfft/latest/microfft/)
104-
8. [STM32U5 Series Reference Manual](https://www.st.com/resource/en/reference_manual/rm0456-stm32u575585-armbased-32bit-mcus-stmicroelectronics.pdf)
111+
1. [The best channel ever](https://www.youtube.com/@Rohde-Schwarz)
112+
2. [The I2S implementation that made me understand](https://www.youtube.com/watch?v=qNLvoSQCx60)
113+
3. [Embassy-rs Official Book](https://embassy.dev/book/)
114+
4. [STM32 NUCLEO-U545RE Board Documentation](https://www.st.com/en/evaluation-tools/nucleo-u545re.html#documentation)
115+
5. [INMP441 I2S Digital Microphone Official Datasheet](https://invensense.tdk.com/wp-content/uploads/2015/02/INMP441.pdf)
116+
6. [Adafruit UDA1334A I2S DAC Guide](https://learn.adafruit.com/adafruit-i2s-stereo-decoder-uda1334a/overview)
117+
7. [embedded-graphics Rust Crate Documentation](https://docs.rs/embedded-graphics/latest/embedded_graphics/)
118+
8. [mipidsi Rust Crate Documentation](https://docs.rs/mipidsi/latest/mipidsi/)
119+
9. [STM32U5 Series Reference Manual](https://www.st.com/resource/en/reference_manual/rm0456-stm32u575585-armbased-32bit-mcus-stmicroelectronics.pdf)
83.7 KB
Loading

0 commit comments

Comments
 (0)