You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: website/versioned_docs/version-fils_en/project/2026/delia.vasile1402/index.md
+17-7Lines changed: 17 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,7 +10,7 @@ A virtual pet that lives, grows, and misses you when you're away
10
10
11
11
## Description
12
12
13
-
A Tamagotchi (digital pet) built on the STM32 NUCLEO-U545RE-Q microcontroller, programmed entirely in Rust. The system uses a finite state machine with concurrent async tasks. It provides visual feedback via an OLED screen, audio feedback via a PWM-driven passive buzzer, and accepts input via three physical buttons (Feed, Play, Sleep). The pet's state (hunger, happiness, fatigue) degrades over time using the microcontroller's internal RTC, so the pet continues to age even when the device is idle.
13
+
A Tamagotchi (digital pet) built on the STM32 NUCLEO-U545RE-Q microcontroller, programmed entirely in Rust. The system uses a finite state machine with 11 distinct pet states and 5 concurrent async tasks running on the Embassy framework. It provides visual feedback via an SH1106 OLED screen with custom pixel-art animations, audio feedback via a PWM-driven passive buzzer with unique melodies per state, and accepts input via three physical buttons (Feed, Play, Sleep). The pet's stats (hunger, happiness, fatigue) decay over time, driving state transitions and triggering warning sounds.
14
14
15
15
## Motivation
16
16
@@ -22,7 +22,7 @@ I chose this project because it combines several embedded systems concepts (asyn
22
22
23
23
The main components of the system are:
24
24
-**STM32 NUCLEO-U545RE-Q** — main microcontroller with internal RTC running Embassy/Rust
25
-
-**SSD1306 OLED screen** — displays the pet's current state via I2C
25
+
-**SH1106 OLED screen** — displays the pet's current state via I2C
26
26
-**3 push buttons** — user input (Feed, Play, Sleep) via EXTI interrupts
27
27
-**Passive buzzer + transistor** — audio feedback via hardware PWM
28
28
@@ -40,12 +40,19 @@ Set up the development environment and started experimenting with Embassy on the
40
40
### Week 10 - 11
41
41
Developed the KiCad schematic and assembled the prototype for the project.
42
42
43
+
### Week 12
44
+
Implemented the pet FSM, display rendering, button input, and PWM audio.
45
+
46
+
### Week 13
47
+
Debugged async task interactions. Tuned gameplay parameters and finalized the hardware assembly.
48
+
43
49
## Hardware
44
50
45
-
The project uses the STM32 NUCLEO-U545RE-Q as the main microcontroller. An SSD1306 OLED screen is connected via I2C. Three push buttons handle user input and a passive buzzer driven by a transistor provides audio feedback. Time tracking is handled by the microcontroller's built-in RTC.
51
+
The project uses the STM32 NUCLEO-U545RE-Q as the main microcontroller. An SH1106 OLED screen is connected via I2C. Three push buttons handle user input and a passive buzzer driven by a transistor provides audio feedback.
46
52
47
53

48
54
55
+

49
56
## Schematics
50
57
51
58

@@ -55,7 +62,7 @@ The project uses the STM32 NUCLEO-U545RE-Q as the main microcontroller. An SSD13
55
62
| Device | Usage | Price |
56
63
|--------|-------|-------|
57
64
| STM32 NUCLEO-U545RE-Q | Main microcontroller | — |
58
-
|SSD1306 OLED screen | Graphical interface | 20 RON |
65
+
|SH1106 OLED screen | Graphical interface | 20 RON |
59
66
| 3x Push buttons | User input (Feed/Play/Sleep) | 5 RON |
0 commit comments