-
Notifications
You must be signed in to change notification settings - Fork 706
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to get current time of music being played ? (AUD-5748) #1288
Comments
The API to get current play time is |
As shown in the code snippet, esp_audio_time_get is used, unfortunately it doesn't work on esp32s3 |
Is it possible to share your code, so we can check or reproduce it? For |
Please see the attached source code, I changed the suffix to png, actually it is a C file. This project sets up a web server, tries to decode music files which are stored in spiff, and send the decoded PCM stream through websocket to web client. This file is mainly copied from cli folder. High level API ESP AUDIO is used to play the music. And a raw stream servers as the last audio element in pipeline. The pipeline looks like: spiffs->mp3 decoder -> ReSample filter -> raw stream. A dedicated task mp3_player_task is used to sink PCM data from the ending raw stream, and send it through web socket protocol. Regularly function music_info is called to print the current time info. |
This topic has become inactive, so I'm going to close the issue. Please reopen this if you have any questions or need any further assistance. |
Environment
current_time_position.txt
Problem Description
esp_audio_time_get doesn't return the correct current time, while I was hearing music.
esp_audio_info_get(player, &info); can not return the correct time ethier.
Expected Behavior
Actual Behavior
Steps to Reproduce
// If possible, attach a picture of your setup/wiring here.
Code to Reproduce This Issue
// If your code is longer than 30 lines, GIST is preferred.
Debug Logs
current_time_position.txt
The text was updated successfully, but these errors were encountered: