Greetings to you
Need help again.
Similar to https://randomnerdtutorials.com/esp32-web-server-spiffs-spi-flash-file-system/, I am thinking to use Select option (in HTML file) to select volume level for the I2C audio card connected to ESP-32. HTML will be located in SPIFFS and user can select desired output level from dropdown list. My challenges are how to pass the selected value in HTML file to the sketch and to serial monitor. And Vise versa. Please help and guide me. Thank you
Hi.
I think this tutorial is a good starting point: https://randomnerdtutorials.com/esp32-esp8266-input-data-html-form/
You just need to change the type of input field. In this case, we’re using text, in your scenario, you’ll use a drop-down menu.
You may also take a look at some slider web servers that might also be useful for your project: https://randomnerdtutorials.com/esp32-web-server-slider-pwm/
I hope this helps.
Regards,
Sara
Many many thanks Sara for your prompt response. I will go through these suggestions.
Thank you very much. After following these two projects, now I can get data from client to serial monitor. Now, please help me on how I can display data in client webpage from serial monitor. I like to use websocket. Thank you again
Hi.
First, learn how to read the data from serial monitor. For example: https://www.arduino.cc/reference/en/language/functions/communication/serial/read/
Then, you can take a look at this WebSocket web server example: https://randomnerdtutorials.com/esp32-websocket-server-arduino/
There is a section in the code that shows how to send data to the client. Take a look at the notifyClients() function.
Regards,
Sara