-
-
Notifications
You must be signed in to change notification settings - Fork 240
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
Is AnalogAudioStream supported on ESP32-S3? #1039
Comments
The Arduino IDE version is not relevant here. To use the ADC functionality of the S3 you need to have the new ADC API available from Espressif. This is not the case in the ESP32 core version you are using: you can find the version in the Board Manager. It is only available starting from ESP32 3.0: Fortunately there is a pre-release available. So I suggest to upgrade 3.0.0 alpha2 The other option is to add a USE_ANALOG_ARDUINO in the AudioConfig.h and you might get away with this if you keep the sampling rates very low. |
Thanks very much for your support. I tried with alpha2. Using base-adc-serial unfortunately I get I guess its almost working. P.S. When I used the new AnalogReadContinous example in 3.x I can measure with ESP32-S3 at about 20Khz but regularly it drops one reading. At 10kHz its about once a second. I am looking forward trying your AudioStream instead. |
Yes, this error was introduced with one of the last changes to make the dac pin selectable for the S2 and ESP32. |
Thank you very much! |
I added the missing variants to the AudioConfig.h |
Cool.
I get regardless of sample_rate
When I use the stock base-adc-serial example (default config) I get
Almost there. |
Well 100 does not make any sense. |
Yes I started with 44100 and went down with the values. So no value between 100 and 44100 are accepted. The default values of the defaultConfig are also not accepted. |
You should be ablee to determine the available range for your processor by printing the following values
The values above are for the ESP32, so I expect it to be different for your board |
Phil Or in short: At this time your base-adc_serial compiles but fails to set sampling rate with ESP32 Core Version 3.0.0 alpha2. |
Strange, I used the example from Espressif as starting point for my implementation. |
Oops, there were some pretty ugly bugs: e.g. I did not set the sampling rate! I committed a correction and a test case. But there is still something wrong: I am measuring a sampling rate which is much higher in mono and much lower in stereo then requested. But at least it seems that we are getting some data now... I did not check if the data makes any sense... |
I committed some more corrections: I removed the shadowed channels and bits_per_sample and all conversions so that we can better understand the provided data. |
see #1049 |
Hi, I have an issue with esp32-s3, more specifically the board I am using is lilygo t-display s3. I installed ESP version 3.0 alpha 2 and this solved the compile issue. however, After uploading the code, I get no sound! (I am using Analog DAC) I have checked all the pins on the board but there is no sound... |
I am not really sure what functionality you are talking about, but I have the impression that you try to use the non existing DAC of the ESP32-S3! If you want to output sound you need to use I2S or PWM on this processor... |
Thank you for your answer. I will try them. |
Problem Description
When I open basic-adc-serial and I attempt to compile it I get:
error: 'AnalogAudioStream' does not name a type
My goals is to read with the internal A/D converter.
Device Description
Hardware: Adafruit Feather ESP32-S3 2MB PSRAM
Board Manager: esp32 by Espressif Systems version 2.0.14
Selected Board: ESP32S3 Dev Module (not the Adafruit defined board)
Sketch
Other Steps to Reproduce
Not applicable.
What is your development environment
Arduino IDE 2.2.1
Selected Board: ESP32S3 Dev Module (not the Adafruit defined board)
I have checked existing issues, discussions and online documentation
The text was updated successfully, but these errors were encountered: