Using the new NVS multi-page BLOBs
Posted: Wed Jan 23, 2019 5:11 pm
I just saw that 3.1.1 introduced a new feature called "multi-page BLOBs" (CONFIG_MP_BLOB_SUPPORT). I need such a feature (at the moment, I split a certificate file into multiple BLOBs at application level to get around the 1984 bytes limit), so I enabled the option.
Unfortunately, a simple test program that would just write 2k bytes to a BLOB, commit and then try to read it back fails with ESP_ERR_NVS_VALUE_TOO_LONG during nvs_set_blob(). Saving and reading 1900 bytes works just fine. The constant CONFIG_MP_BLOB_SUPPORT is defined with value "1", so it would seem that the option is enabled.
Is there some secret ingredient that needs to be changed to make multi-page BLOBs work? Is there an example snippet outlining its use?
Thanks a lot in advance!
Unfortunately, a simple test program that would just write 2k bytes to a BLOB, commit and then try to read it back fails with ESP_ERR_NVS_VALUE_TOO_LONG during nvs_set_blob(). Saving and reading 1900 bytes works just fine. The constant CONFIG_MP_BLOB_SUPPORT is defined with value "1", so it would seem that the option is enabled.
Is there some secret ingredient that needs to be changed to make multi-page BLOBs work? Is there an example snippet outlining its use?
Thanks a lot in advance!