Go Down

Topic: VMusic3 Library (USB / MP3 / WMA module) (Read 1 time) previous topic - next topic


Oct 27, 2013, 02:01 pm Last Edit: Oct 27, 2013, 10:29 pm by andrewzuku Reason: 1
Hey everyone,

I've created a library to use the VMusic3 USB/MP3/WMA module:

Main Features

  • Play / Pause / Stop

  • Fast-forward / Rewind

  • Next / Prev track

  • Next / Prev folder (walks directory tree, stopping on folders with MP3/WMA files)

  • Set volume

  • "Keep Playing" mode automatically goes to the next track (or folder)

  • "Random" mode chooses a random track in the current folder

  • When playing, returns track position in seconds

  • When a USB is detected, can find first track on USB or load a specific file

  • Can tell you the current path and filename

See the included examples or vmusic.h file for all the public attributes and functions.

VMusic3 vs VMusic2
If anyone has a VMusic2 they can test this on, I'd love to hear how you go. The library was written for firmware version "V2MSC1.0.0".

The library uses SPI instead of the default UART, so don't forget to change the jumper pin :)

NPN Transistor
Also, the VMusic3 5V power should be switched using an NPN Transistor (Eg: BC548). This is only necessary if you don't want to disconnect then reconnect power to the Arduino every time you reset/reupload a sketch.
Collector: Arduino 5V
Base:         Arduino Digital IO used to switch the VMusic on.
Emitter:    VMusic 5V

Have a read of the vmusic.h and vmusic.cpp files. There's lots of comments explaining everything in there.
I've also included 2 examples in the library to get you started.

Arduino Car Stereo
If you want to see how the library can be used in a more advanced way, here's a link to my Arduino Car Stereo project:




thank you verry mutch for your work.

I tried to use your library but i do not get it work.

I build a test setup and flashed the serial example.

If i try to play a file, it is freezing util i remove the usb drive.

Can you help me?


Jan 12, 2014, 01:02 am Last Edit: Jan 12, 2014, 01:06 am by andrewzuku Reason: 1
Sorry, I haven't tested the library thoroughly.

Perhaps you could try a different USB drive, or a lower MP3 bitrate?

What File Format is the USB formatted in? What brand/Size is the USB?

I've replied to your email. Can you please email me the file you're trying to play?



Thanks for your response. I get it to work. It was a problem with the usb drive.
It runs verry well  thanks for your work!



That's so cool!

I'd love to see if you put your player in a nice enclosure.

Go Up

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

via Egeo 16
Torino, 10131