tonuino/TonUINO-TNG

Support DF Player MP3-TF-16P V3.0 with the chip MH2024K-24SS

boerge1 opened this issue · 3 comments

With the DF Player MP3-TF-16P V3.0 with the cip MH2024K-24SS (bought in October from AZ-Delivery) on some folder the request getFolderTrackCount() takes more than 900ms:

call getFolderTrackCount()
IN  7e ff 06 3d 00 00 12 fe ac ef
OUT  7e ff 06 4e 00 00 02 fe ab ef
OUT  7e ff 06 4e 00 00 02 fe ab ef (retry after 900ms)
IN  7e ff 06 4e 00 00 0f fe 9e ef (reply for the first getFolderTrackCount request)
end getFolderTrackCount()
call playFolderTrack()
OUT  7e ff 06 0f 01 02 0b fe de ef
IN  7e ff 06 41 00 00 00 fe ba ef
IN  7e ff 06 4e 00 00 0f fe 9e ef (reply for the second getFolderTrackCount request)
OUT  7e ff 06 0d 01 00 00 fe ed ef
IN  7e ff 06 41 00 00 00 fe ba ef
here it plays not the track that is requested but the very first mp3 track on sd card.

If the timeout is increased the to 1500ms there are no retries anymore.

Solution:

  1. In the library Makuna/DFMiniMp3 the timeout should be configurable
  2. increase the (configurable) timeout

In the version 1.2.3 of the DF Player Lib it is now possible to configure an own timeout. Set this timeout to 1500 for all configurations.

pull request #140 created

pull request #140 merged