Skip to content

Building for the M5AtomS3

K7MDL edited this page Jan 15, 2025 · 5 revisions

If you want to compile and run his on the M5AtomsS3 these are the steps required

Enable AtomS3 in the code

Uncomment #define ATOMS3 located in the main header file. This will activate appropriate M5 library and display code.

{42879A7E-8410-4A12-A249-689B31911433}

Set your com port

Hold the AtomS3 reset button for 3-4 seconds and let go. Watching device manager Serial ports list, you should see your CPU show up. Here it appears as COM14

{E87E6233-ED9F-42B1-AA3E-B14153509ACE}

Select the comm port control in the tool bar

{996CB350-00AB-4AB5-8B37-40C1C04B1021}

You will see USB serial port devices listed. The ESP32 devices will have extra information. Select the COM14 device.

{16DD53E3-529A-44B0-AB6A-F3673ABEC009}

Success

{6A51EF00-81A7-4EC4-A460-DF5DC34610B6}

UART Flash Method

Select UART flash method icon in the tool bar

{13D993C4-33EE-4BEC-9F1F-4CD7CE406CEF}

3 options will appear, choose UART

{B3767933-2E92-4DD4-B3A1-2D85B43346EF}

Success

{D24EDB31-EA1E-4F47-A214-6D2117791BA8}

Set your CPU model to ESP32S3

Select the esp32s3 target in the tool bar.

{13FA16A9-A1BF-48C1-BC57-483516A23A2B}

Select esp32s3 from the list

{C6D89330-0FF4-40FB-8C27-A31C1A7B0D66}

You will get a list of 3 model options: Pick the first, (via built-in debug via JTAG ...)

{D6B6ACD2-AA14-4569-9CB0-5F20152A359A}

The IDE should run some update notifications successfully.

Cntl-E and press D to build and flash. Or click on the wrench icon in the toolbar to just compile.

{06F62A67-21AE-409C-B397-F355F7E182E6}

Hopefully no more errors if you are lucky. I seem to get a lot of them, especially after starting up the Visual Studio editor and opening the project folder.

One of the remedies that can help at times is to re-run Configure Extension. Some time it makes things worse. but usually not.

{1C10BD44-B80D-4CC1-AE46-2C1F2DD3256D}

{8746E3E9-4BA1-4BB7-9DAE-E50F438012AC}

{9E47A590-A53A-4A6A-9536-DA77ED479313}

{018E4013-898B-4D0E-9FD4-83A1F9BAF272}

I always choose the same button hoping to avoid messing things up. Here I choose the middle option with idf-git\2.39.2 because that seems to work and choosing something else breaks things.

{545A4DEC-9181-44E3-8C45-EAB9AB2EB515}

Choose set device target

{AC36F9B9-9101-4CC3-B30D-A8C59C18021E}

Maybe it will work. If not, I then delete the build folder.

{32BDE59C-1565-479D-B5F0-4243AE5E68EC}

Sometimes I exit VS Code and start again. I often see a notification pop up in the lower right corner asking if you want to Generate json. Ignore this, it can only be done after setting the correct esp target. Set the esp32s3 and this usually works, it rebuilds the CMake files and compiles. You can alo run 'idf.py --reconfigure' on the command line.

When it compiles you will see a lot of warnings. These can be ignored. Most all are deprecated graphics library arguments for color. Will figure out how to fix them someday.