My Final Project
🎵 Motion and Music Player 🎵
For my final project, I will make a movement-based music player. This interactive gadget will function as a device that plays music and responds to shaking, tapping, and sudden motions to shuffle, play/pause, advance to next track, or go back to last track playing. The track title will display on an LCD screen with an OLED displaying user interface feedback. With rechargeable batteries and an integrated hookup for recharging, this gadget is suitable for off-grid use.
The device will:
-
act as a motion-sensing MP3 player allowing for backward, play/pause, forward, and shuffle based on motion
-
displays song track title playing on Grove LCD screen
-
displays interface feedback on OLED screen to verify motion detected
-
audio amplification circuit for boosting audio for speakers
-
include a Neopixel light display with responsivenes to music
-
include a couple of buttons for play/pause and forward track
-
enclose a rechargeable battery system
Spiral Development + Work Plan
Spiral Development
Phase 1: Breadboard Prototype - demonstrate most basic electronics + code works
Phase 2: Custom PCB + Cardboard enclosure prototype - get a sense of integration and needs for tweaking physical design
Phase 3: Include Charging Device Prototype - complete set-up for charging circuit within cardboard prototype
Phase 4: System Integration with final materials
Systems Integration
For more on systems integration see Week 16
Work Plan
| Date | Focus | Tasks to Complete |
|---|---|---|
| April 30th | Final Project Planning | Finalize idea + sketch, plan out tasks, create systems diagram, order needed components, complete midterm review |
| May 6 | Breadboard Prototyping + CAD | Figure out electronics circuit; create design on Inkscape or Fusion 360, design and document systems integration |
| May 13th | Device Prototyping | Laser cut (or 3D print) draft design + (device holder if ahead) - incorporate with Wildcard week (meshtastic device??), design and 3D print enclosure for wiring |
| May 20th | Electronics Design + Production | Design custom PCB, mill, solder, and test |
| May 27th | Systems Integration and Testing | 3D print buttons, mounts, etc.; wire management; |
| June 3rd | Final Presentation | Finalize documentation, slide deck, and video; embellish / make pretty / make the playlist of my dreams |
Weekly Task Breakdown / Checklist
April 30th
Finalize idea + sketch
Create workplan
Sketch systems diagram
Place Digikey order for needed components
Complete Midterm Review - tasks completed
May 6th
Update electronics schematic
Complete initial electronics circuit testing
Document and design systems integration
Create initial design on Fusion 360 and export to Inkscape for lasercutting cardboard prototype
Test audio circuitry
May 13th
Finish next draft of 3D design on Fusion (esp the 3D printed internal layer)
3D print prototype and laser cut cardboard prototype of actual size of front and back panels
design enclosures for batteries and circuit boards >> rethinking design
design PCBs for project on KiCad
develop most basic code that demonstrates all components working on breadboard
May 20th
Mill PCBs
solder and stuff PCBs with components
initial wire management placement (using crimped cables, etc)
test and debug most basic code on current circuit
May 27th
Mill next iteration of PCBs
solder and stuff updated PCBs with components (have one more new iteration of the board)
develop more advanced working code for updated project
3D print accessory pieces (button faces)
laser cut and engrave final panels on plywood
3D print final inner panel
mount, fixure, and secure all components inside >> pass shake/drop test
add decorative touches
June 3rd
Create final project slide deck
Create final project video
Finalize final project webpage
Progress Log
2D and 3D Design
Initial Sketches
Here's an initial sketch for the music player and charger:

Music player and charger sketch
Updated Sketches The project is evolving...you will notice more emphasis on the digital compass function. I will hold off on the charging device until I make it to that rung of the spiral.

Updated sketch of my final project design with some of the components placed
Computer Aided Design

Here is an iteration of my prototype. After laser cutting and 3D printing, I have made tweaks to the design to fit with the components.

Another view of this prototype iteration of just the front and back panels. For the back panel, I am thinking to CNC mill this to take advantage of the 2.5D capabilities that can ensure a better fit.
Additive Manufacturing
I will use 3D printing for the inner wall of the final project, for encasing for wiring/electronic components, and for button pads.

To the right, I have printed the inner wall of the device. This took two separate print jobs because the size of the inner wall is bigger than the bed of our printer. Designed holes and extrusions that would allow for press-fit piecing together

Here is the prototype all pieced together
Subtractive Manufacturing
I will use laser cutting for the front panel of my final project. I will use CNC milling for the back panel.

To the left, I have laser cut three parts: the front panel and the inner and outer pieces of the back panel.
Embedded Programming
...
Electronics Design and Production
Initial sketch:

Sketch of schematic for the music player's electronic circuit
Updated sketch with systems integration in mind:

After some initial breadboard prototyping, I've updated the schematic for my project
Prototyping

First prototype of compass device

Here I am testing how the Neopixel lighting looks through the 3D printed material.
Notes
Research + Resources
Here I'll take note of sources I'm using to learn more of what I'll need to complete the project.
DFPlayer Mini
- Datasheet
- Github page
- This recently published guide >> the example code for this one was working for me
- Blog on using DFPlayer Mini with ESP32
- Tutorial on using the DFPlayer Mini with an audio amplifier
Takeaways: uses UART communication with microcontroller (this uses TX (transmit) and RX (receive) lines of communication connected to corresponding lines on ESP32); special naming convention for MP3/WAV files; can wire to an audio amplifier board and the microcontroller board
Voltage Meter using ATTiny85
- ATtiny Datasheet
- Attiny85 Single Chip Voltmeter Youtube explainer
- ATTiny85 blog and github page for simple voltage monitor
- Arduino Forum post on implementing battery level indicator
Takeaways: voltage range for ATTiny85 is 2.7V-55V (or 1.8V to 5.5V for 85V); blinking LED to indicate charge level could save battery power; can calculate voltage level using 1.1V internal reference of the Attiny85
Li-Ion Battery Charger Circuits
- Page on Homemade Circuit Projects breaks down four options using LM317, NE55, and LM324
Takeaways: Li-Ion cells can charge quickly and efficiently but you need to prevent high voltage/current/over-charging; for safety, circuit should have a way for charger to cut off automatically when batter is charged; temperature management highly reccomended and can be implemented with a thermoristor; add in current control by using BJTs (Bipolar Junction Transistors); for charging multiple batteries together in parallel from a single voltage source this can be done at 1C rate with controlled temperature
LED Indicater Battery Circuits
- Another Homemade Circuit Projects page which shows some example circuits for an LED switching on or off at full battery
NeoPixel RGB LED Strip
- Tutorial
- Adafruit's NeoPixel Guide
- Blog on using NeoPixel LED with ESP32
Takeaways: make sure to connect ground FIRST + use 300-500 Ohm resistor between GPIO pin and data input pin to protect NeoPixel from damage; connects to GND, 5V, and GPIO pin; can operate at 3.3V at lower brightness; use a capacitor across + and - terminals for power reservoir to prevent glitching
SOLAR
- This beginner's video on how to connect a solar panel to a battery. Can't just hook up solar panel directly into battery b/c it could overload it. Equipment that makes everything work safely: the charge controller which regulates voltages for battery. Always connect batter first to charge contorller BEFORE connecting to solar. Add fuse as a safety device between battery and controller.
- This video on solar cells and panels with Arduino. Solar cells made up of layers of semiconductive materials with + and - charge. Connecting solar cells in series increases overall output voltage. Connecting in parallel has lower voltage but higher current. Can be used with rechargeable batteries - the combined voltage of the combined solar power circuit must be greater than or equal to voltage capacity of battery in order to charge it and a circuit with higher current charges the batter quicker
- Solar Power Manager Series. Arduino's link
- Adafruit's USB / DC / Solar Lithium Ion/Polymer charger. We have this version in the lab and they also have an updated versioned linked on the page
Notes on Old Project Idea
During Week 1, I came up with my project idea and initial sketches.
For Week 2, I further developed the idea and used Computer-Aided Design software to begin to visualize what the board and user blocks could look like. I created a slightly more streamlined sketch before I got started:

An early sketch of the board

An early sketch of the user blocks. Simplifying the design a bit here.

Here's a clip of my timeline for early stages of my design on Fusion:
Here are the direct files for my designs in Inkscape, Fusion, FreeCAD, and OnShape as of Week 2.
Quick Week 3 update: my first item I cut on the laser cutter was a simple cardboard prototype for my final project's sensor board:
In Week 5, I updated my project idea and created the sketch for spiral development.
