Closed Akta3d closed 3 years ago
The ADC inside ESP SoC is used also for WiFi stuff IMHO. Just don't read the ADC in every loop - try to read it every say 30 - 50 ms...
@Pablo2048 Perfect, really thanks
The ADC inside ESP SoC is used also for WiFi stuff IMHO. Just don't read the ADC in every loop - try to read it every say 30 - 50 ms...
I was also wondering why my web server will not work suddenly when I try to read the analog pin. Thanks for this.
On a project I want to control LED and a MP3 player with a Wemos D1 mini, buttons, potentiometer and a html page. All work fine, without the volume potentiometer.
The wemos is the websocket server, and the HTML page the client. I can control LED and MP3 with button and/or html page.
But when I put analogRead(A0) in the source code, my websocket client fails to connect to the web socket server.
For this issue I have remove all uneeded code to just have the websocket server and the potentiometer.
Ardiuno Code:
The html page:
The script:
Complete code here : https://github.com/Akta3d/Akta3d_MP3_And_Led
If I comment the analogRead line, the html page can connect to the server, all work fine without volume potentiometer
Do you have an idea of this conflict ?