Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[possible bug] PlayRTTTLToI2SDAC example in ESP32 does not clear last note #327

Closed
Martin-Laclaustra opened this issue Nov 2, 2020 · 3 comments

Comments

@Martin-Laclaustra
Copy link
Contributor

The last note keeps playing forever. The only change to the example was to enable internal DAC.
out = new AudioOutputI2S(0,1);
This does not happen in ESP8266.

@earlephilhower
Copy link
Owner

Interesting observation. I see that the code does call out->stop() which should fill the I2S buffer with 0s and also stop the I2S engine. Unfortunately, I'm not really knowledgeable about the internal DAC. If there is something else required to stop samples going to it, that may be missing.

@fkoteam
Copy link

fkoteam commented Dec 12, 2020

after stop a wav, I start to hear noise. It can be this bug? any workaround?
(with esp32 and internal dac, also)

thank you!

@schmurtzm
Copy link

Hi, I can confirm that the problem concerns the ESP32 only (tested on ESP8266, Wemos esp32 and devkit v4) : I take the example "PlayRTTTLToI2SDAC.ino" included in the library, I flash my ESP32 and it works but the last note is repeated for ever.

It's not due to the internal DAC because the same problem appear with no DAC or with an external DAC.

Some observations from my issue #471 which is the same problem (sorry the search engine of github doesn't find this issue if you type "RTTTL", you have to type "PlayRTTTLToI2SDAC" 😄 ) :

  • The ESP32 is not crashed.
  • If you call rtttl->stop(); before the end of the RTTTL sound then it stops correctly.
  • If you call rtttl->stop(); after the end of the RTTTL sound then it doesn't stop the repeat of the last note.

I've recorded the result sound from my ESP32 here.

Hope this helps 😉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants