Newbie questions (sorry)
I totally new with M5Stack products and I will receive my Core 2 for a project I have.
I am already programming ESP32s/ESP8266s with Visual Studio Code and the PlatformIO plugin.
I did not really understand if I need to install a specific firmware or the default one would work?
Other question: sometimes I am also using MicroPython and I was wondering if with this module you can only use MicroPython with UIFlow or it can also be used with another IDE like pyCharm or VSCode?
Thanks for your answers!
erich last edited by erich
The time my post was validated I received the core 2 and could try investigating my questions.
MacOs Big Sur
in PIO, the Core 2 is configured as the following board: m5stack-core-esp32
with Arduino framework and I have imported the M5Core2.h lib
I could compile a code example to display something on the screen (the example of the LCD api page at the bottom).
I could successfully compile it (after changing the drawLine function as it takes 5 parameters and not 3 as in the example).
I can therefore confirm the Core 2 is working with VSCode/PIO.
Now my problem is that I cannot upload, I have an error message.
Btw I have the same message when I try to burn the fw from M5Burner so I guess this is not an issue with VSCode/PIO (see my other post).
Failed to write to target RAM (result was 01070000)
I tried at all different speeds with 2 different usb cables.
Any help very much appreciated.
@erich Hello, it does't seem to be issue with our devices but more issue with Mac OSX Big Sur, we had a serious issue that no code was able to compile at all due to esptool having unsupported version of pyserial, we updated a fix but we find some issues like you describe still keep coming.
Could you please try on some other machine preferably windows or non-BigSur OS one and see if the issue still keeps coming?
First of all thank you for this quick answer.
I also doubt this is coming from your device.
FYI I also had much trouble with VSCode/PIO/ESP32 when I upgraded to Big Sur.
I followed some GitHub tickets where eventually I could make my ESP32 (devkit v1) working by modifying the esptool.py file.
Took me half a day to figure it out as there are several versions of esptool.py when you have arduino IDE, VSCode, PIO etc..on the same machine.
Not mentioning that default Python version on Big Sur is still the old 2.7....but I needed to compile with version 3.x
Therefore now this is working fine with my ESP32/VSCode/PIO but I agree / suspect this is now the same issue with the Core 2.
I will just install the CP21xx drivers and M5Burner on my Windows 10 and let you know how it goes.
Just to confirm the problem is related to Big Sur.
I could install the CP21xx drivers and M5Burner on my Win10 PC and flash the Core 2 without any issue.
Now I'm really stuck as I have all my dev environment on my Mac and only coding for there.
Would you please consider having a look at how this can be fixed on your side or if any temporary workaround would be available?
JackH last edited by
@erich re: your other question
For MicroPython I use Thonny, it's bare bone but does the trick. Have a look at this to get started.
@jackh sorry my question was not that clear :)
in fact I just wanted to know if it is possible to use MicroPython with the Core 2 with another IDE than UIFlow?
I am asking because, as far as I have understood, there's a dedicated UIFlow firmware for the core 2 to be used with UIFlow. Therefore I don't really understand whether this firmware is exclusively to be used with UIFlow or you can use any MicroPython IDE like PyCharm, Thonny etc...and you get access to the same controls (touch screen, accelerometer etc...)
Thanks for the clarification!
ajb2k3 last edited by
UIFlow is built on a version of MP 1.12 as so micropython can be accessed directly over the USB.
However because it is based on MP1.12 so of the modules not required by UIFlow may have been removed.
Any IDE that can access MP over USB can be used to program M5Stack cores and sticks.
@ajb2k3 ok this is clear thanks but which firmware do I need to use if I want to use MP not with UIFlow but with Pycharm or Thonny for instance?
Should I use the UIFlow fw provided by M5Stack or the default ESP32 MP fw from MicroPython.org ?
Just in case someone is interested I found an answer to my question here:
ajb2k3 last edited by
Sorry for the delay.
All devices can be accessed by ide's like thonny as long as a working usb driver is installed.
@ajb2k3 thanks for your answer but as you can see just above I already got the answer from another post on the forum.
In fact this is not that simple.
Yes you can flash the device with the binaries found on the MicroPython website but then you only get the basic lib to get access to the ESP32.
If you want to take advantage of all 'surrounding' features like touch screen, accelerometer etc...then, unlike with UIFlow where the libs do encapsulate all those surrounding features, you have to dig yourself and find the correct libs as M5Stack is not providing one.