Skip to content

Add flash read/write API #758

@yonsch

Description

@yonsch

Currently the flash can be accessed using the two ROM functions flash_range_program and flash_range_erase. However, there is no proper way to read from the flash, and to write individual bytes. Having these two features would allow users to use parts of the flash as non volatile memory.

Considered alternatives
Reading can be implemented using flash_do_cmd, though it requires allocating a large tx array to satisfy the API. Writing to arbitrary byte ranges can be implemented using flash_range_program with 0xff padding for unaffected bytes. Both can be implemented by writing directly to the SSI. But it would be better to have this done in the SDK and not application code.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions