ESP32-S2 USB-CDC Flashing (Arduino)

ozgbostan
Posts: 19
Joined: Sat Oct 31, 2020 7:19 am

Re: ESP32-S2 USB-CDC Flashing (Arduino)

Postby ozgbostan » Sat Feb 27, 2021 5:47 pm

chegewara wrote:
Thu Feb 25, 2021 11:34 pm
I fixed one more thing in my library and now you can also use it as a standard Serial library

Code: Select all

#define NO_GLOBAL_SERIAL   // this will prevent  to create instance of HardwareSerial Serial
#include "cdcusb.h"

CDCusb Serial;

void setup()
{
    Serial.begin();
    while(!Serial); // wait until USB cable is connected and stack is ready
    Serial.println("Serial is ready");
}

void loop()
{
  delay(1000);
  Serial.println(millis());
}
I am trying to use your library, however I am not be able to succeed in working with that due to the conflict with core libraries of ESP32 Arduino. As the other included libraries integrated within each other, I am gonna try deeply to solve the issues. Or else, if you have any recommendation as a simple solution, I can try that one?

chegewara
Posts: 2238
Joined: Wed Jun 14, 2017 9:00 pm

Re: ESP32-S2 USB-CDC Flashing (Arduino)

Postby chegewara » Sun Feb 28, 2021 2:17 am

Do not use option "Serial connected to: USB".

ozgbostan
Posts: 19
Joined: Sat Oct 31, 2020 7:19 am

Re: ESP32-S2 USB-CDC Flashing (Arduino)

Postby ozgbostan » Tue Mar 02, 2021 6:42 am

chegewara wrote:
Sun Feb 28, 2021 2:17 am
Do not use option "Serial connected to: USB".
Ok, thanks. It's working as you said. However, the CDC flashing is still not working, right?

I could not be able to flash the ESP32-S2 with your TinyUSB library, even with double upload button clicking on IDE.

chegewara
Posts: 2238
Joined: Wed Jun 14, 2017 9:00 pm

Re: ESP32-S2 USB-CDC Flashing (Arduino)

Postby chegewara » Tue Mar 02, 2021 9:15 am

ozgbostan wrote:
chegewara wrote:
Sun Feb 28, 2021 2:17 am
Do not use option "Serial connected to: USB".
Ok, thanks. It's working as you said. However, the CDC flashing is still not working, right?

I could not be able to flash the ESP32-S2 with your TinyUSB library, even with double upload button clicking on IDE.
Thats very odd, with most recent changes i can update S2 if CDC is included and running in app and board is connected with USB.
I am using ubuntu 20.04 for testing and it works. Now i tested with windows 10 VM and there is some problem with it, IDE is sending DTR and RTS signals with different pattern. I will investigate it when i have some time.
Thanks for testing and reporting.

ozgbostan
Posts: 19
Joined: Sat Oct 31, 2020 7:19 am

Re: ESP32-S2 USB-CDC Flashing (Arduino)

Postby ozgbostan » Thu Mar 04, 2021 8:20 am

chegewara wrote:
Tue Mar 02, 2021 9:15 am
Thats very odd, with most recent changes i can update S2 if CDC is included and running in app and board is connected with USB.
I am using ubuntu 20.04 for testing and it works. Now i tested with windows 10 VM and there is some problem with it, IDE is sending DTR and RTS signals with different pattern. I will investigate it when i have some time.
Thanks for testing and reporting.
Thanks to chegewara, the discussion and solution alternatives are going on in the following issue page.

https://github.com/chegewara/EspTinyUSB/issues/29

Who is online

Users browsing this forum: Baidu [Spider] and 51 guests