Changing player.volume question

Designing hardware and software for systems that use the VS1010 MP3 Audio DSP Microcontroller.
Post Reply
Haden98
User
Posts: 6
Joined: Mon 2022-01-24 20:44

Changing player.volume question

Post by Haden98 »

Hello,

I would like to have an mp3 file constantly loop after it is started, this has worked well whenever I use PlayNamedFile.
Whenever I change the value of player.volume while I have the mp3 file playing it finishes but then does not start again. Is there a way to loop an mp3 file, and be able to change the volume at will during playback?
Hannu
VLSI Staff
Posts: 532
Joined: Mon 2016-05-30 11:54
Location: Finland
Contact:

Re: Changing player.volume question

Post by Hannu »

A lot of things are possible with the player.

If you are playing MP3, there will be some silent part because how MP3 just works.

I assume, you are still using ROM PayerCallback(). If you give + or - through UART, it adjusts the volume.

Have a look at:
viewtopic.php?t=3055 I use that every time I write a player application to remind myself how the player works.

The document goes through a simple player. The trick is player.skip=-1; player.cancel = 1; to repeat the song. And if that jumps previous song, use playTimeSeconds and goTo members when the file is close to end.
Post Reply