You need just one Serial;
Serial.begin(10000000);
//connect to proper TX<>RX pins of M5Stack
For proper debug you can connect sensor with any USB<>UART board and try to run it with any terminal software (I use TeraTerm)
If you want to debug derictly with M5Stack you will need Serial2 as your example shows, but keep in mind that if its a software serial, such high speed wont work properly most likely
Hi @steinoxyd ,
I had the same issue which I got help with on the m5stack github before seeing this. I may as well direct you straight to it than repeating it fully here; https://github.com/m5stack/M5Stack/issues/194
The issue is the 'IMU.calibrateMPU9250(IMU.gyroBias, IMU.accelBias);' which if commented out, the code will run.
From the comment from @lukasmaximus I have not realised the probable reason for the issue.
sorry for resurrecting this post from the dead but where exactly do you run the esptool --port <YOUR PORT> write_flash_status --non-volatile 0 command?
You run this in a terminal or command line program.
Replace YOUR PORT with the name of the port that appears in arduino. On windows this may be COM followed by a number on OSX this is often somelike USBslab.
I know I'm late to the game but I just bought one of these. Did you ever manage to connect it to your m5stack @dfabro ? if not I'm gonna try, and if I'm successful will post my findings here
@wikistik I have tried that, but the Windows system seems to be trying to insert a random outdated driver for the USB cable instead of the one you suggested. You're right, though, because on a different Windows 7 computer, I installed the drivers and it started working automatically.