Home Forums Sparkfun MP3 Shield Library Support Forum control if mp3 is playing?

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #1707
    Anonymous
    Inactive

    hi i’ve read the example but i’m not understand how to check if mp3 is playing.

    i’m writing a mp3 player app same as SparkFun example but using your libary.

    i would like to check/set if mp3 is playing , if i press again the button the mp3 stop.

    example:

    IF i press trigger 1 , mp3 1 start. then if i press again mp3 stop,

    if mp3 1 is running and i play trigger 2 , mp3 1 stop, if i press again trigger 2 , mp3 2 start …. and this for any trigger (4 trigger total)

    best regards…  i’m not able to found a manual that explain mp3 library … exist?

    #1708

    The manual is documented in the github page HERE

    Please take note of the Troubleshooting & Non-Blocking Limitations section

    • "Error code: 1 when trying to play track"
      • See the above Limitations. about Non-Blocking.
      • Remember to check your audio cables and volume.

    The limitation describes why and how to poll for playing.

    example:
    if(!MP3player.isPlaying()) {
      Serial.println(F("Currently playing."));
    }
    
    
    
Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.