Skip to content

A simple pcb with two audio drivers, a sd card reader and a microcontroller with fancy WebUI and MQTT to play sounds.

Notifications You must be signed in to change notification settings

foorschtbar/SoundBoard

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SoundBoard

A simple PCB with two audio drivers, a SD card reader and a ESP32 microcontroller to play sounds via MQTT.

Features

  • On factory settings or no known WiFi SSID is found, device starts in AP mode
    • To stay in AP mode, leave the SSID and password empty
  • The LED show the status of the device
    • Orange: Booting
    • Blue: Connecting to WiFi
    • Green: Connected to existing WiFi
    • Violet: Started WiFi AP
    • Red: No connection to WiFi
    • White: Web or MQTT activity
  • The device can be controlled via MQTT:
    • Subscripte to <prefix>/status to get the status of the device
    • Publish to <prefix>/cmd to play a sound
      • {"play": "filename.mp3", "volume": 50, "balance": 0} (volume and balance are optional)
      • {"tts": "Hello World", "lang": "de"}

Getting Started

  • Default WiFi SSID: SoundBoard
  • Default WiFi Password: 12345678x!

Hardware

Case

PCB

  • The PCB was designed with KiCad and could be found in the pcb directory.

Development

Frontend development

  • Start the frontend development server with python .\webserver.py in the html directory.
  • Open the browser at http://localhost:8000/ to see the frontend.
  • Set manual a cookie with overwrite-host to the hostname or ip of the device and reload the page.

ToDos/Improvement Ideas

  • Add a priority flag to the MQTT messages. Stop the current playback only if the priority is higher than the current one.
  • Sync volume and balance fader across all clients
  • Enable/Disable Playback/Stop buttons based on the current state
  • Add addidtional MQTT topics with hostname for status und command
  • Refactor Code in more separat files
  • Maybe: Option to queue playbacks
  • Send file list in multiple messages
  • If we had valid settings, but in fallback AP mode, try to connect to the last known wifi periodically
  • Download audiofiles from the webinterface
  • Replace play/delete/download with icons?
  • Add tailing slash to the topic prefix
  • Save authentication in cookie/webstore
  • Add credentials to post requests
  • Improve MQTT reconnection and resubscription
  • Improve MQTT reconnection after boot when no connection is available
  • Make MQTT status topic more "chatty"

Links

About

A simple pcb with two audio drivers, a sd card reader and a microcontroller with fancy WebUI and MQTT to play sounds.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published