This shows you the differences between two versions of the page.
pm:prj2025:avaduva:sorin.popescu2306 [2025/05/25 22:54] sorin.popescu2306 [Software Design] |
pm:prj2025:avaduva:sorin.popescu2306 [2025/05/26 00:06] (current) sorin.popescu2306 [Rezultate Obţinute] |
||
---|---|---|---|
Line 192: | Line 192: | ||
| Timing / Delays || Lab 2 / Lab 3 || Managing time-based interactions | | Timing / Delays || Lab 2 / Lab 3 || Managing time-based interactions | ||
|} | |} | ||
+ | |||
+ | ==== Project Structure and Feature Interaction ==== | ||
+ | |||
+ | === OLED Display (Adafruit SSD1306 128x64) === | ||
+ | Shows the main menu, game instructions, user prompts, and results. | ||
+ | Provides all visual feedback to the user during setup and gameplay. | ||
+ | |||
+ | === HX711 Weight Sensor + Load Cell === | ||
+ | Accurately measures the weight of objects placed on the device. | ||
+ | Used in both games to set or check the weight value. | ||
+ | |||
+ | === 4x3 Keypad === | ||
+ | Lets the user navigate menus, select game modes, and enter numerical guesses or commands (such as start, confirm, or return to menu). | ||
+ | |||
+ | === Buzzer === | ||
+ | Outputs audio signals for feedback. | ||
+ | Plays different tones to indicate success or to help the user get closer to the target weight in the matching game. | ||
+ | |||
+ | === Arduino Board === | ||
+ | Central controller that runs the main program. | ||
+ | Reads inputs from the keypad and weight sensor, updates the display, and controls the buzzer. | ||
+ | |||
+ | ==== Functionalities Validation ==== | ||
+ | To test the weight sensor, I weighed an object with a kitchen scale and checked if the values matched. | ||
+ | |||
+ | ==== Sensor Calibration ==== | ||
+ | For the weight sensor, I used an object with a known weight (75 grams) and observed the sensor reading (approximately 148,500). Based on this, I calculated the calibration factor as (sensor_value / actual_weight). | ||
+ | |||
+ | ==== Optimization ==== | ||
+ | |||
+ | Used modular functions for clarity and easier maintenance. | ||
+ | |||
+ | Limited display updates to only when changes occur, reducing flicker. | ||
+ | |||
+ | Grouped hardware initialization in setup for faster start. | ||
+ | |||
+ | Provided immediate feedback with the buzzer for better user experience. | ||
+ | | ||
+ | Used keypad library debouncing for reliable input. | ||
+ | |||
+ | Calibrated the weight sensor once for consistent measurements. | ||
+ | |||
===== Rezultate Obţinute ===== | ===== Rezultate Obţinute ===== | ||
- | <note tip> | ||
- | Care au fost rezultatele obţinute în urma realizării proiectului vostru. | ||
- | </note> | ||
+ | **Demo** | ||
+ | |||
+ | <html><iframe width="560" height="315" src="https://youtube.com/embed/iKKtlptE3Co" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe></html> | ||
===== Concluzii ===== | ===== Concluzii ===== | ||
===== Download ===== | ===== Download ===== | ||
- | <note warning> | + | {{:pm:prj2025:avaduva:guesstheweight.zip}} |
- | O arhivă (sau mai multe dacă este cazul) cu fişierele obţinute în urma realizării proiectului: surse, scheme, etc. Un fişier README, un ChangeLog, un script de compilare şi copiere automată pe uC crează întotdeauna o impresie bună ;-). | + | |
- | + | ||
- | Fişierele se încarcă pe wiki folosind facilitatea **Add Images or other files**. Namespace-ul în care se încarcă fişierele este de tipul **:pm:prj20??:c?** sau **:pm:prj20??:c?:nume_student** (dacă este cazul). **Exemplu:** Dumitru Alin, 331CC -> **:pm:prj2009:cc:dumitru_alin**. | + | |
- | </note> | + | |
===== Jurnal ===== | ===== Jurnal ===== |