This pull request contains a few fixes and improvements to the HWCDC implementation.
- Rework `HWCDC::write()` to accept unlimited data
- Add Semaphore to guard the TX Ring Buffer
- Add events support
- Remove unnecessary 1200bps touch for flashing over HWCDC
- Fix `HardwareSerial::setDebugOutput()` not resetting `putc` if the port is already selected, causing debug output to also show on HWCDC even when not selected.
## Summary
Adds support for the new ATMegaZero ESP32-S2 board. Adds the relevant section to `boards.txt` and adds the folder for the `atmegazero-esp32s2` with the proper `pins_arduino.h` to the `variants` folder.
## Impact
Allows users to compile code properly for the ATMegaZero ESP32-S2 without having to use a similar board and manually entering pin numbers.
## Links
[ATMegaZero ESP32-S2](https://atmegazero.com/#/atmegazero_esp32s2_overview)
Thanks!
* The board.txt has been updated. Added variant folder.
Necessary additions for deneyapMiniKart were made in board.txt. Added pins_arduino to variant folder. deneyapMiniKart information has been added.
* Added variant files and added text in board.txt
Co-authored-by: Me No Dev <me-no-dev@users.noreply.github.com>
* Add initial support for USB MSC
* Add Firmware Upload/Download With MSC
Current running firmware is available as file inside the MSC Disk. To update the firmware on the ESP, just copy a regular firmware bin into the drive
* Support overwriting of the firmware file
Overwriting a file is done totally differently on MacOS, Windows and Linux. This change supports it on all of them.
* Allow CDC, FirmwareMSC and DFU to be enabled on boot
* Add example ESP32-S2 USB-ONLY board
* Various device code optimizations
Added `end()` methods to MSC classes
Made begin() methods safe to be called multiple times
Optimized CDC class
* Fix CDC Connect/Disconnect detection in Arduino IDE on Windows
* Rework cdc_write
* Update ESP32-S2 board configs
* Fix compile archive arguments for the new toolchain
* Add menu to S2 for picking through which port to upload
Internal USB CDC requires to reset and wait for the new port (because persistence is not yet stable)
* USB CDC should also be started in main
* Fix URL and USB version for WebUSB
* Update vendor callback API
* Update CDC::write to use TX_DONE semaphore
* Update USB_Serial example
Add support for the Trueverit Universal IoT Driver MK II (https://www.trueverit.com)
The board will be released on market using electronic distributors soon, as the other one board added via #5219
This new board (referred as MK II) has onboard Texas Instruments DP83848 Eth PHY chip.
* Removed ProS2 and added TinyS2 to boards.txt
* Fixed incorrect NUM_OUTPUT_PINS - should be 47 not 45
This is why my APA doesn't work on my FeatherS2 as it usess IO45 and the check is for < not <=
* TinyS2 from boards.txt got stomped with old proS2 stuff (no idea why), so adding it back in.