Manufacturing Page#
Provides manufacturing store interface and implementation to store the manufacturing page into the EFR32 flash.
Modules#
Functions#
Prepare the manufacturing store for use.
Deinitialize previously initialized mfg region.
Erase the manufacturing store.
Check if the manufacturing store is empty.
Write to mfg store.
Read from mfg store.
Get length of a tag ID.
Check if the manufacturing store supports TLV based storage.
Get version of values stored in mfg store.
Get the device ID from the mfg store.
Get the device serial number from the mfg store.
Get the APID.
Get the Application public key.
Function Documentation#
sid_pal_mfg_store_init#
void sid_pal_mfg_store_init (sid_pal_mfg_store_region_t mfg_store_region)
Prepare the manufacturing store for use.
Type | Direction | Argument Name | Description |
---|---|---|---|
sid_pal_mfg_store_region_t | [in] | mfg_store_region | Structure containing start and end addresses of the manufacturing store. |
Must be called before any of the other sid_pal_mfg_store functions.
sid_pal_mfg_store_deinit#
void sid_pal_mfg_store_deinit (void )
Deinitialize previously initialized mfg region.
Type | Direction | Argument Name | Description |
---|---|---|---|
void | N/A |
sid_pal_mfg_store_erase#
int32_t sid_pal_mfg_store_erase (void )
Erase the manufacturing store.
Type | Direction | Argument Name | Description |
---|---|---|---|
void | N/A |
Because the manufacturing store is backed by flash memory, and flash memory can only be erased in large chunks (pages), this interface only supports erasing the entire manufacturing store.
Note
This function is only supported for diagnostic builds.
Returns
0 on success, negative value on failure.
sid_pal_mfg_store_is_empty#
bool sid_pal_mfg_store_is_empty (void )
Check if the manufacturing store is empty.
Type | Direction | Argument Name | Description |
---|---|---|---|
void | N/A |
Note
This function is only supported for diagnostic builds.
sid_pal_mfg_store_write#
int32_t sid_pal_mfg_store_write (uint16_t value, const uint8_t * buffer, uint16_t length)
Write to mfg store.
Type | Direction | Argument Name | Description |
---|---|---|---|
uint16_t | [in] | value | Enum constant for the desired value. Use values from sid_pal_mfg_store_value_t or application defined values here. |
const uint8_t * | [in] | buffer | Buffer containing the value to be stored. |
uint16_t | [in] | length | Length of the value in bytes. Use values from sid_pal_mfg_store_value_size_t here. |
sid_pal_mfg_store_read#
void sid_pal_mfg_store_read (uint16_t value, uint8_t * buffer, uint16_t length)
Read from mfg store.
Type | Direction | Argument Name | Description |
---|---|---|---|
uint16_t | [in] | value | Enum constant for the desired value. Use values from sid_pal_mfg_store_value_t or application defined values here. |
uint8_t * | [out] | buffer | Buffer to which the value will be copied. |
uint16_t | [in] | length | Length of the value in bytes. Use values from sid_pal_mfg_store_value_size_t here. |
sid_pal_mfg_store_get_length_for_value#
uint16_t sid_pal_mfg_store_get_length_for_value (uint16_t value)
Get length of a tag ID.
Type | Direction | Argument Name | Description |
---|---|---|---|
uint16_t | [in] | value | Enum constant for the desired value. Use values from sid_pal_mfg_store_value_t or application defined values here. |
sid_pal_mfg_store_is_tlv_support#
bool sid_pal_mfg_store_is_tlv_support (void )
Check if the manufacturing store supports TLV based storage.
Type | Direction | Argument Name | Description |
---|---|---|---|
void | N/A |
Note
This function only indicates that the platform supports TLV, but the device may have storage with fixed offsets that was flashed during production.
sid_pal_mfg_store_get_version#
uint32_t sid_pal_mfg_store_get_version (void )
Get version of values stored in mfg store.
Type | Direction | Argument Name | Description |
---|---|---|---|
void | N/A |
Note
Functions specific to Sidewalk with special handling The version of the mfg values is stored along with all the values in mfg store. This API retrieves the value by reading the address at which the version is stored.
sid_pal_mfg_store_dev_id_get#
bool sid_pal_mfg_store_dev_id_get (uint8_t dev_id)
Get the device ID from the mfg store.
Type | Direction | Argument Name | Description |
---|---|---|---|
uint8_t | [out] | dev_id | The device ID |
sid_pal_mfg_store_serial_num_get#
bool sid_pal_mfg_store_serial_num_get (uint8_t serial_num)
Get the device serial number from the mfg store.
Type | Direction | Argument Name | Description |
---|---|---|---|
uint8_t | [out] | serial_num | The device serial number |
sid_pal_mfg_store_apid_get#
void sid_pal_mfg_store_apid_get (uint8_t apid)
Get the APID.
Type | Direction | Argument Name | Description |
---|---|---|---|
uint8_t | [out] | apid | The apid |
Applicable only for products with short form certificate chain.
sid_pal_mfg_store_app_pub_key_get#
void sid_pal_mfg_store_app_pub_key_get (uint8_t app_pub)
Get the Application public key.
Type | Direction | Argument Name | Description |
---|---|---|---|
uint8_t | [out] | app_pub | The Application public key |
Applicable only for products with short form certificate chain.