Differences

This shows you the differences between two versions of the page.

Link to this comparison view

iothings:proiecte:2025sric:cv_example [2025/05/29 09:02]
veaceslav.cazanov
iothings:proiecte:2025sric:cv_example [2025/05/29 09:24] (current)
veaceslav.cazanov
Line 308: Line 308:
 {{:​iothings:​proiecte:​2025sric:​veaceslav-cazanov-captive.png?​500|}} {{:​iothings:​proiecte:​2025sric:​veaceslav-cazanov-captive.png?​500|}}
  
 +===== Python TCP server -- statistics receiver =====
 +There is a Python server in the Internet ''​iot.echipa3.xyz:​50993''​ (domain and hosting inherited from other project) which listens for already described information in //Bluetooth music streaming// section. It stores the information in local volume managed by Docker, as a directory tree: ''​artist/​[album]/​title/​plays.txt,​time.txt,​art.jpg''​.
 +
 +===== Nginx webserver -- neat statistics presentation =====
 +There is a simple frontend server by nginx on ''​https://​iot.echipa3.xyz''​ which shares the data volume with the Python statistics server and presents it in a neat form to the user. The information on it is update dynamically.
 +
 +{{:​iothings:​proiecte:​2025sric:​veaceslav-cazanov-front.png?​500|}}
 +
 +====== Challenges ======
 +  - The whole custom cover art gather implementation
 +  - Captive portal
 +  - Arduino IDE taking an eternity to compile an image
 +  - The cover art will just not transfer. The music must be paused for some time. New transfer attempt is made each 5 seconds.
 +  - YouTube Music triggering 2-5 track change events for a single track change.
 +  - ''​E (13054) task_wdt: esp_task_wdt_reset(705):​ task not found''​ spam on boot until reaches ~20000.
 +
 +====== Conclusions ======
 +Implemented a working solution which forwards Bluetooth sound to mini-jack. An adequate user interface is provided, Wi-Fi credentials provisioning,​ status LED and pushbutton. The solution may still crash randomly, though it was used without issues while writing this documentation (earphones connected to jack and music streaming from an iPhone). As the code was mainly tested with an iPhone, there may be issues with other source devices, for example, Windows 11 laptop with web version of YouTube Music, doesn'​t report the album, neither it's cover art. The Python server may also refuse to receive statistics sometimes. This all means that the code requires polishing on all levels.
  
  
Line 316: Line 334:
  
 [[https://​en.wikipedia.org/​wiki/​SBC_(codec)|Wikipedia -- SBC (codec)]] [[https://​en.wikipedia.org/​wiki/​SBC_(codec)|Wikipedia -- SBC (codec)]]
 +
 +[https://​medium.com/​@atacanymc/​creating-a-captive-portal-with-esp32-a-step-by-step-guide-9e9f78ab87b8|Creating a Captive Portal with ESP32: A Step-by-Step Guide]] //highly modified in my implementation//​
 +
 +[[https://​github.com/​pschatzmann/​ESP32-A2DP)|pschatzmann/​ESP32-A2DP]]
 +
 +[[https://​github.com/​pschatzmann/​arduino-audio-tools|pschatzmann/​arduino-audio-tools]] ​
 +
  
  
iothings/proiecte/2025sric/cv_example.1748498536.txt.gz · Last modified: 2025/05/29 09:02 by veaceslav.cazanov
CC Attribution-Share Alike 3.0 Unported
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0