Page 1 of 1

Micropython on the ESP32-S3-DevKitC-1 (esp32s3)

Posted: Sat Jan 22, 2022 12:48 pm
by automate1717
I am sharing because of the extreme pain I went through and the fact that I now have success. It was my own fault for initially not following the instructions 100% as I have now learned that the smallest step could be the most critical when dealing with microcontrollers. Micropython and the board are awesome and I am now so happy to have them together.

I want to give full credit to this gentlemen who posted the YouTube vid at this link
https://www.youtube.com/watch?v=BC5uj4dqDG8

I struggled for weeks and I believe it was either because only the beta version of 4.4 works (not liekly) or the fact that I did not physically remove the sdkconfig.usb file from the boards folder (I did remove the reference of the file in the mpconfigboard.cmake file but that is most likely not enough). If you follow Damien's instruction below and see the video, this works!!! and most likely works on all esp32s3s. Note that the instructions below came directly from the youtube video page. I just copied and pasted for reference

Installation commands

***
Files that need to be changes can be found at

sdkconfig.usb
~/esp/mpy/micropython/ports/esp32/boards

mpconfigboard.cmake can be found at
~/esp/mpy/micropython/ports/esp32/boards/GENERIC_S3
***

mkdir -p ~/esp
cd esp
git clone -b v4.4-beta1 --recursive https://github.com/espressif/esp-idf.git esp-idf-v4.4-beta1
mv ~/esp/esp-idf-v4.4-beta1/ ~/esp/esp-idf
cd ~/esp/esp-idf
PATH=$PATH:/Applications/CMake.app/Contents/bin/
./install.sh all
. $HOME/esp/esp-idf/export.sh
mkdir -p ~/esp/mpy
cd ~/esp/mpy
git clone git://github.com/micropython/micropython --depth=1
cd micropython/
cd ports/esp32
make submodules
. $HOME/esp/esp-idf/export.sh
ls /dev/tty.*
make BOARD=GENERIC_S3 PORT=/dev/tty.usbserial-1410
/Users/damianwilliams/.espressif/python_env/idf4.4_py3.9_env/bin/python ../../../../esp-idf/components/esptool_py/esptool/esptool.py -p /dev/tty.usbserial-1410 -b 460800 --before default_reset --after no_reset --chip esp32s3 write_flash --flash_mode dio --flash_size detect --flash_freq 80m 0x0 build-GENERIC_S3/bootloader/bootloader.bin 0x8000 build-GENERIC_S3/partition_table/partition-table.bin 0x10000 build-GENERIC_S3/micropython.bin
screen /dev/tty.usbserial-1410 115200
from machine import Pin
led=Pin(47,Pin.OUT)
led.value(1)
led.value(1)

*******************
Files that need to be changes can be found at

sdkconfig.usb
~/esp/mpy/micropython/ports/esp32/boards

mpconfigboard.cmake can be found at
~/esp/mpy/micropython/ports/esp32/boards/GENERIC_S3
********************

Re: Micropython on the ESP32-S3-DevKitC-1 (esp32s3)

Posted: Thu Jan 27, 2022 8:36 pm
by seonr
Or you can just flash the pre-built binaries? :)
https://micropython.org/download/GENERIC_S3_SPIRAM/

Re: Micropython on the ESP32-S3-DevKitC-1 (esp32s3)

Posted: Fri Jan 28, 2022 9:26 pm
by automate1717
I don't believe the pre-builts will work and the spiram is a different model than what I have. Note the step where I needed to change the config file and remove a file. That steps appears to be critical and the pre-builts do not have that.

Re: Micropython on the ESP32-S3-DevKitC-1 (esp32s3)

Posted: Sat Apr 30, 2022 3:09 am
by alhussuna
Thanks for the clear steps and info.
i was able to build and run test app, but that app ran in c. not sure how to run py app using the board ? i don't even know how to send files to the board and then run them ? any advice, document or anything can help me with that ?