If you are familiar with the Petoi coding blocks and Python language, you can change to the Code mode in Mind+ as follows:
The Code mode is a Python3 development environment. You can write any Python script in it and call all the API interfaces of the PetoiRobot library imported by Mind+.
You can find the PetoiRobot library in the following directory, there are all the definitions of API interfaces in the PetoiRobot.py
Windows C:\Users\{username}\AppData\Local\DFScratch\extensions\petoi-robot-thirdex\python\libraries\PetoiRobot.py
MacOS /Users/{username}/Library/DFScratch/extensions/petoi-robot-thirdex/python/libraries/PetoiRobot.py
Below are the supported functions in the library. You may refer to the auto-generated Python code in the Blocks mode to learn its formats.
Here is a sample code :
You can also copy the code in the Auto Generate area in the Blocks mode and then paste it into the code file in the Code mode. Then you can edit and run the code.