I am part of a group trying to do a summer camp for kids in which they will use the ESP32S3 board. In the final day, they will assemble the Sesame robot but prior to that, I'd like for them to use the board to communicate with some sensors via the serial port.
The problem is, the serial monitor in the Arduino cloud enviroment does not work for the ESP32S3. I can get it to work in the desktop ide (there is a setting to enable USB CDC on build) but for the life of me, I cannot figure out a setting or include file or anything at the beginning of the code that will get it to work in the Arduino cloud enviroment. It will program and run, just not communicate.
Is there any way to do it in web environment?
Can you be more clear?
I don't understand how you can use 1 serial port to communicate with multiple sensors. Sensors generally communicate with MCUs via I2C, SPI, and UART buses. When you say serial do you really mean UART?
In a non-cloud environment your PC is connected to the board via a USB cable. In order to use that connection for Serial in and out you code a Serial.begin(baud rate); in your code. I don't think that is possible in a cloud environment.
If you can provide more details of WHAT you want to do and less about HOW someone may be able to help.
As a general rule, the board has sensors conected to it and the board communicates with the cloud via wifi. The sketch in the cloud then generally displays the sensor result on a dashboard and what I have done is display the results on my phone using the IoT remote app.
Here is a screen shot of the example iPhone cloud sketch showing some of my phone's sensors on the screen.
Welcome!
You need to specify which ESP32 we are talking about, several things are different on the boards such as Flash sizes, PSRAM sizes, USB interfaces, GPIOs brought out, antennas, voltage regulators, pin assignments etc.. This means code that works on one board may need changes on another.
So which one do you have?
Well, the board selection which works on the Arduino cloud is the ESP32S3 Dev Module .
Other ESP32s (like the Adafruit ESP32 Feather) both download from teh serial port and communicate with serial communications withint the program. This particular board will not communicate with serial within the Arduino.cc website.
The sensors and stuff don't really matter to this problem. If I just loop
Serial.println("Hello"), it will work on the Arduino IDE if I set USB CDC enable, but will not work on the Arduino cloud environment. If I don't set USB CDC enable on the Arduino desktop IDE, it won't work there either.
The picture shows the option on the desktop IDE. As far as I can tell, I don't have the option on the Arduino.cc website.
I wonder if there is some way to do it, either with code, or some header file, or something. Most of the sensors we want to use communicate with serial.
I think you will benefit from reading this entire thread.
Hi @north_north_west.
Very cool!
You do. When using Arduino Cloud Editor, "custom board options" are accessed by clicking the "Configure Flavour" icon to the right of the board selector on the Cloud Editor toolbar:
Oh heck! There it is.
Thank you very much!
You are welcome. I'm glad if I was able to be of assistance.
Regards, Per