Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion ports/zephyr/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,10 @@ static void vfs_init(void) {
mount_point_str = "/sd";
path_lib_qstr = MP_QSTR__slash_sd_slash_lib;
#elif defined(CONFIG_FLASH_MAP) && FIXED_PARTITION_EXISTS(storage_partition)
mp_obj_t args[] = { MP_OBJ_NEW_SMALL_INT(FIXED_PARTITION_ID(storage_partition)), MP_OBJ_NEW_SMALL_INT(4096) };
#define STORAGE_DEVICE DT_GPARENT(DT_NODELABEL(storage_partition))
#define ERASE_BLOCK_SIZE COND_CODE_1(DT_NODE_HAS_PROP(STORAGE_DEVICE, erase_block_size), (DT_PROP(STORAGE_DEVICE, erase_block_size)), (4096))
int block_size = ERASE_BLOCK_SIZE;
mp_obj_t args[] = { MP_OBJ_NEW_SMALL_INT(FIXED_PARTITION_ID(storage_partition)), MP_OBJ_NEW_SMALL_INT(block_size) };
bdev = MP_OBJ_TYPE_GET_SLOT(&zephyr_flash_area_type, make_new)(&zephyr_flash_area_type, ARRAY_SIZE(args), 0, args);
mount_point_str = "/flash";
path_lib_qstr = MP_QSTR__slash_flash_slash_lib;
Expand Down
Loading