VS1053 audio player with lcd and rotary encoder
Dependencies: LibMenu PinDetect SDFileSystem TextLCD VS1053lib mRotaryEncoder mbed
Diff: main.cpp
- Revision:
- 3:b6bf1e6d9cde
- Parent:
- 2:1c751f044ecd
--- a/main.cpp Wed Jun 19 10:56:07 2013 +0000 +++ b/main.cpp Thu Dec 26 09:15:01 2013 +0000 @@ -190,8 +190,6 @@ state = PLAYING; while(!feof(song)) { if (state == IDLE) { - // empty the buffer on the VS1053 then break out of the loop - // TODO add cancel play methos to vs1053 lib break; } else if (state == PLAYING) { fread(&buff, 1, BUFFER_SIZE, song); @@ -213,6 +211,7 @@ } } fclose(song); + vs1053.cancelplayback(); vs1053.resetplaytime(); state = IDLE; root.enter();