Serial monitor works fine with my ESP32-DEV-KIT-1 MCUs.
But I cannot get it to work with my ESP32-CAM. I decided to modify the pre-loaded sketch to include an option to toggle the build in (rather bright) LED so I could get good images in dark places.
My ESP32-CAM came with the ESP32-CAM-MB board which I use to interface to the Arduino IDE.
I can download sketches OK but if I try to use serial monitor no prints are shown and the sketch does not appear to start. If I close the serial monitor the sketch runs - I see the flashes of the LED that I programmed. Attached image of what I see.
Hi @DickyOZ. You mention Arduino IDE 2.0.0-rc2 specifically. Have you tried it with other versions of the Arduino IDE (e.g., 1.8.x)? If so, did you get different results?
If you upload this simple Serial test sketch to your ESP32-CAM, do you get the expected result of "hello" being printed to Serial Monitor at 1 Hz?
Unfortunately, although I do have a standard ESP32 board, I don't own an ESP32-CAM and don't have any experience with them. Maybe one of the other forum members with an ESP32-CAM will comment here with their findings.
I am especially interested in regressions in Arduino IDE 2.x, so it would be very helpful if you would give it a try with the latest release of the classic Arduino IDE (1.8.16 at the moment) and let me know whether the same issue occurs with that IDE's Serial Monitor.
All I have to do now is understand what it is actually saying. But it looks like I will be able to debug the new sketch I'm writing for the ESP32-CAM. All the CAM examples in Arduino want to connect to the home network whereas I want to start an access point that my phone can connect to. That is what the CAM did out of the box. But the out of the box sketch had no way of turning on the LED which I will need when I dangle the cam down the back of my car engine to try to find a slight oil leak.
Dicky.
This is expected. The behavior of Tools > Get Board Info has been changed.
In the classic Arduino IDE, it provides information about the port you have selected from the Tools > Port menu. The values shown in the VID and PID fields come from the USB device that generated that port.
In Arduino IDE 2.x, it provides information about the board you have selected from the Tools > Board menu. The values shown in the VID and PID fields come from the platform boards definition. For example, here is the board definition for the Uno: https://github.com/arduino/ArduinoCore-avr/blob/1.8.4/boards.txt#L61-L102
If you select Tools > Board > Arduino AVR Boards > Arduino Uno in Arduino IDE 2.x, Tools > Get Board Info will show VID of 0x2341 and PID of 0x0043 regardless of whether you have a physical board with that VID/PID pair connected to your computer. Kind of questionable whether that is at all valuable, especially when considering that some boards, such as the Uno, have been manufactured with multiple VID/PID pairs.
In the case of the ESP32-CAM, no VID/PID pairs are specified in its definition. The reason is that the ESP32-CAM uses the VID/PID pair supplied the manufacturer of its general purpose USB to serial chip (probably either WCH CH340 or Silicon Labs CP210x), so there is no way to know whether the chip supplying that VID/PID is on an ESP32-CAM or one of the many other products that use the same USB chip. So this is why you see the blank VID and PID fields in the Arduino IDE 2.x's Tools > Get Board Info dialog when you have the ESP32-CAM selected from the Tools > Board menu. This is also why the IDE doesn't identify the port with the board name in the Tools > Port menu or in the dropdown board selector.
Thank you for the update. That is valuable information. Unfortunately, I have not been able to reproduce it with my standard ESP32 board. If anyone else has encountered this problem with the Arduino IDE 2.x Serial Monitor, please let me know.
I now think it has to do with the ESP32-CAM-MB which is needed because ESP32-CAM doesn't have a USB connection interface to Arduino. All my other boards have USB connectors and serial monitor works fine with them.
My Access Point is now up and cooking with gas
Dicky.
I think I may have spotted the cause of the original problem.
In the Arduino IDE 2.0.0-rc2 screenshot you have COM1 selected from the Tools > Port menu. In your working Serial Monitor screenshot from Arduino IDE 1.8.16 you have COM4 selected.
Alas that was not the problem, sorry about the confusion - I was a bit hasty taking screen shots before selecting the COM port.
Things have taken a change for the worse since downloading 1.8.16
I don't know whether libraries have changed or what. But the LED doesn't now flash at all regardless whether I use 1.8.16 or 2.0.0. I wonder if the GPIO pin mapping for the LED has changed?
Serial monitor still doesn't work on 2.0.0 When the monitor is open the hard resetting of the RTS pin doesn't take effect until I close serial monitor; the sketch then runs.
Attached a couple of screen prints of 1.8.16
Hello,
Today I got an obviously similar board with an ESP32-CAM-MB.
[Amazon](YUPVM WiFi Board ESP32-CAM-MB -USB zu Seriellem Port CH340G mit OV2640 Kamera Modul Modus, mit 2,4G Antenne https://www.amazon.de/dp/B09KMWKM75/ref=cm_sw_r_apan_glt_i_MDVR13QM4Y2SVYFSRX17?_encoding=UTF8&psc=1)
After trying several hours, I was lucky to find this post, and indeed, it works with older IDE.
The board obviously resets, if one tries to open a serial connection. It also happens, if i try it with Putty.
Before, I tried to solve the issue with setting rts/dtr in platformio.ini, to 0 as suggested in some threads, but without success.
Now, I'm indeed wondering, that it works even with the old IDE.
Is there a solution, how to get it run in IDE 2.0.0-rc3?
Hi srting42,
I deleted the IDE 2.0.0-rc and went back to 1.8.19 and all is well. My ESP32-CAM and ESP32-Dev-kit 1 can now be programmed and serial monitor works fine again for debugging.
I will wait for a later release of 2.0.0 before trying it again. All part of the fun
I had a similar problem with serial data being shown as squares despite the baud rate matching. Switching to 1.8.19 showed the correct output in the Serial Monitor while still using a sketch I uploaded with Arduino IDE 2.0.0-rc3. I'm using a "DORHEA ESP32 Cam WiFi Bluetooth Development Board with OV2640 Camera Module" that looks similar to what string42 posted. Happy it's working now
Hi @oxin. Did this problem occur with any output, or only under specific conditions?
There is a known bug where there is this sort of output immediately after any upload when using certain boards, but I have not observed it with the subsequent output:
Hi all,
I have the same issue with Serial Monitor and my ESP32-CAM:
I am also using ESP32-CAM-MB to communicate with it.
IDE 1.8.19 works ok, as expected.
IDE 2.0.0-rc6 allows me to upload the sketch to the camera, but it does not provide any feedback later on.
I have tried several times. Most of the times the IDE can connect, but does not get any data. Twice it was not even able to recognize the camera. When I rebooted the IDE, then it could connect to it.
I had downloaded the Windows 10 version (which is Arduino IDE 1.6.6) and the Serial Monitor was also very unpredictable with the ESP32-CAM, only got it working in 1 session.
After seeing cimanes post I downloaded the .zip (1.8.9) and now the Serial Monitor is working nicely.
Thanks cimanes
Thanks for the update @DickyOZ. I'm glad it is working now.
If anyone else is having this type of problem where the Arduino IDE 2.x Serial monitor is not showing output, even though the Arduino IDE 1.x Serial Monitor does, there is some continuing discussion and investigation in this newer forum topic:
I realize this is slightly off-topic, but this thread popped up high on Google results while trying to figure out why my ESP32-CAM wouldn't work and would not talk to me via the serial port unless I was using the -MB carrier module. I'm hoping to save others some grief by piggybacking here.
It turns out that Pin 1 on header P1 is drawn in the schematic as ground on the widely-distributed schematic for the module, and pinout images found on product listings for the ESP32-CAM kits label the pin as GND. But if you look closely at the board, you'll see that the kits that come with the -MB carrier will have that pin labeled as GND/R. That /R is the reset pin. And it needs to be pulled high (3.3V) in order for the ESP32 to run (just strap the GND/R pin to the 3V3 pin with a wire, or to be safe, a 1K or greater resistor).
Just to be clear, this is needed on ESP32-CAM boards where the pin has been repurposed as a reset pin. The earlier ESP32-CAM boards with the pin wired to ground must not have the pin directly connected to 3v3!