Skip to content

[EV3 - help wanted]: Implement SPI flash block device driver #2247

@laurensvalk

Description

@laurensvalk

We'll need to implement an SPI flash driver for EV3 so we can load programs on boot and save them during shutdown.

This is very similar to the existing implementation for SPIKE Prime., just with a different set of SPI commands.

We also already have SPI1 working with DMA for the display. Flash uses SPI0 with CS0. SPI0 is also used with CS3 for the ADC, for which we already have code as well. But since we only use flash on boot and during shutdown, we don't need to switch between them at runtime. This makes it relatively easy since it is consistent with existing Pybricks hubs, but the original EV3 firmware did this too.

The necessary Flash SPI commands and parameters can be found in the original firmware and u-boot or just from the data sheet, so everything is out there in principle.

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedExtra attention is neededplatform: EV3Issues related to LEGO MINDSTORMS EV3software: pybricks-micropythonIssues with Pybricks MicroPython firmware (or EV3 runtime)

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions