pub unsafe extern "C" fn esp_vfs_fat_spiflash_format_cfg_rw_wl(
    base_path: *const c_char,
    partition_label: *const c_char,
    cfg: *mut esp_vfs_fat_mount_config_t,
) -> esp_err_t
Expand description

@brief Format FAT filesystem with given configuration

@note This API can be called when the FAT is mounted / not mounted. If this API is called when the FAT isn’t mounted (by calling esp_vfs_fat_spiflash_mount_rw_wl), this API will first mount the FAT then format it, then restore back to the original state.

@param base_path Path where partition should be registered (e.g. “/spiflash”) @param partition_label Label of the partition which should be used @param cfg Pointer to structure with extra parameters for formatting FATFS (only relevant fields are used). If NULL and mounted the previous configuration will be used. If NULL and unmounted the default configuration will be used.

@return - ESP_OK - ESP_ERR_NO_MEM: if memory can not be allocated - Other errors from esp_vfs_fat_spiflash_mount_rw_wl