Conversation
Eliobot is an educational robot built around an ESP32-S3 (4MB flash, 2MB PSRAM) with a DRV8833 motor driver, LED matrix eyes, IR obstacle sensors, line sensors and a buzzer. USB VID/PID 0x303A:0x8384 is allocated to Eliobot-S3 CircuitPython in espressif/usb-pids.
tannewt
left a comment
There was a problem hiding this comment.
A couple questions about the board_init.
| // Delete code.py, use main.py | ||
| mp_import_stat_t stat_c = mp_import_stat("code.py"); | ||
| if (stat_c == MP_IMPORT_STAT_FILE) { | ||
| f_unlink(fatfs, "/code.py"); | ||
| } | ||
| // Create main.py file | ||
| const byte buffer2[] = "print(\"Hello World!\")\n"; | ||
| f_open(fatfs, &fs, "/main.py", FA_WRITE | FA_CREATE_ALWAYS); | ||
| f_write(&fs, buffer2, sizeof(buffer2) - 1, &char_written); | ||
| f_close(&fs); |
There was a problem hiding this comment.
Please don't do this. code.py is the standard CircuitPython way.
There was a problem hiding this comment.
Agreed. Our editor (Elioblocs) now writes code.py and removes the old main.py on the first upload, and board_init() no longer touches code.py or main.py (2e74a70).
| const byte buffer[] = "import board\nimport storage\n\n# Write options : True = Mass Storage, False = REPL\nstorage.remount(\"/\", False)\n"; | ||
| // Create or modify existing boot.py file | ||
| f_open(fatfs, &fs, "/boot.py", FA_WRITE | FA_CREATE_ALWAYS); | ||
| f_write(&fs, buffer, sizeof(buffer) - 1, &char_written); | ||
| f_close(&fs); |
There was a problem hiding this comment.
Are you doing this because USB isn't available?
There was a problem hiding this comment.
No, USB is available. This boot.py is a default safety for kids: it keeps the drive read-only over USB, so children can't mess up the robot's files from the drive, while our web editor (Elioblocs) writes files through the serial REPL, over Web Serial or over BLE. Makers who know what they're doing learn from our docs how to unlock the drive, and the generated boot.py now says how (2e74a70). board_init() only writes it when boot.py is missing, like mixgo_ce_serial. If you'd prefer another way to ship this default, I'm happy to change it.
- board_init() no longer deletes code.py or creates main.py: the Elioblocs editor now writes code.py. - The default boot.py explains why the drive is read-only and how to change it. - GPIO15-16 are free pins (no 32 kHz crystal), and the NeoPixel count anticipates the next board revision.
Adds the Eliobot S3, an educational robot from ELIO (France) used to teach children programming, from blocks to Python.
This PR only adds
ports/espressif/boards/elio_eliobot_s3/, following the feedback on #10935 (one small, focused PR for the board).Hardware
Notes
0x303A:0x8384is allocated to "Eliobot-S3 - CircuitPython" in espressif/usb-pids.board_init()writes a defaultboot.py(storage.remount("/", False)) andmain.pywhenboot.pyis missing, the same approach asmixgo_ce_serial: the robot is programmed from our web editor over the serial REPL or BLE rather than through the drive.Testing
pre-commitandtools/ci_check_duplicate_usb_vid_pid.pypass.CIRCUITPYdrive labelledELIOBOT,boot.pyandmain.pycreated at first boot, code and library upload over USB serial and over the BLE workflow.