LPC55S06: Determine Lifecycle property In-App

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LPC55S06: Determine Lifecycle property In-App

Jump to solution
323 Views
sjrzcis
Contributor I

Hi there,

I am currently experimenting with secure boot on a LPC55S06 controller and wanted to know: is there is an equivalent API accessible from user application (non-bootloader context) to determine the Lifecycle state (property 17, described below), without entering the bootloader?

For instance, I saw this status return code: kStatus_FLASH_SealedFfrRegion (137) in status_t But I think there should be a better way to determine the lifecycle state than trying to do a flash operation on the sealed ffr region and evaluating that the return code == kStatus_FLASH_SealedFfrRegion (137). Also I see no API in the SDK for this (using SDK 26.03).

 

According to UM11126 Chapter 8, Table 420:

LifeCycleState:

Tag: 17 (11h)

Indicates whether Flash security is enabled:

0x5aa55aa5 - Device is in development lifecyle
0xc33cc33c - Device is in deployment lifecycle

Currently getting the value through blhost:

blhost -p <PORT>,<Baudrate>-- get-property 17

 

Thanks!

Labels (1)
0 Kudos
Reply
1 Solution
304 Views
carlos_o
NXP TechSupport
NXP TechSupport

Hi @sjrzcis 

Thanks for your post!

The Lifecycle value can only be read through the bootloader. There is no API available to access this parameter from the user application.

We apologize for any inconvenience this may cause.

As a workaround, I recommend adding a custom parameter to your image to indicate the device’s lifecycle state.

View solution in original post

2 Replies
305 Views
carlos_o
NXP TechSupport
NXP TechSupport

Hi @sjrzcis 

Thanks for your post!

The Lifecycle value can only be read through the bootloader. There is no API available to access this parameter from the user application.

We apologize for any inconvenience this may cause.

As a workaround, I recommend adding a custom parameter to your image to indicate the device’s lifecycle state.

286 Views
sjrzcis
Contributor I
Hello Carlos,
coolest profile pic!
Thanks for the quick answer, this workaround works for me.
%3CLINGO-SUB%20id%3D%22lingo-sub-2350198%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3ELPC55S06%3A%20Determine%20Lifecycle%20property%20In-App%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2350198%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EHi%20there%2C%3C%2FP%3E%3CP%3EI%20am%20currently%20experimenting%20with%20secure%20boot%20on%20a%20LPC55S06%20controller%20and%20wanted%20to%20know%3A%20%3CSTRONG%3Eis%20there%20is%20an%20equivalent%20API%20accessible%20from%20user%20application%20(non-bootloader%20context)%20to%20determine%20the%20Lifecycle%20state%20(property%2017%2C%20described%20below)%2C%20without%20entering%20the%20bootloader%3F%3C%2FSTRONG%3E%3C%2FP%3E%3CP%3EFor%20instance%2C%20I%20saw%20this%20status%20return%20code%3A%20kStatus_FLASH_SealedFfrRegion%20(137)%20in%20status_t%20But%20I%20think%20there%20should%20be%20a%20better%20way%20to%20determine%20the%20lifecycle%20state%20than%26nbsp%3Btrying%20to%20do%20a%20flash%20operation%20on%20the%20sealed%20ffr%20region%20and%20evaluating%20that%20the%20return%20code%20%3D%3D%26nbsp%3BkStatus_FLASH_SealedFfrRegion%20(137).%20Also%20I%20see%20no%20API%20in%20the%20SDK%20for%20this%20(using%20%3CEM%3E%3CSTRONG%3ESDK%2026.03%3C%2FSTRONG%3E%3C%2FEM%3E).%3C%2FP%3E%3CBR%20%2F%3E%3CP%3EAccording%20to%20%3CA%20href%3D%22https%3A%2F%2Fwww.mouser.com%2FpdfDocs%2FNXP_LPC55S6x_UM.pdf%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3EUM11126%3C%2FA%3E%26nbsp%3BChapter%208%2C%20Table%20420%3A%3C%2FP%3E%3CP%3E%3CU%3E%3CEM%3ELifeCycleState%3C%2FEM%3E%3C%2FU%3E%3A%3C%2FP%3E%3CP%3ETag%3A%2017%20(11h)%3C%2FP%3E%3CP%3EIndicates%20whether%20Flash%20security%20is%20enabled%3A%3C%2FP%3E%3CP%3E0x5aa55aa5%20-%20Device%20is%20in%20development%20lifecyle%3CBR%20%2F%3E0xc33cc33c%20-%20Device%20is%20in%20deployment%20lifecycle%3C%2FP%3E%3CP%3ECurrently%20getting%20the%20value%20through%20blhost%3A%3C%2FP%3E%3CP%3E%3CEM%3E%3CSTRONG%3Eblhost%20-p%20%3CPORT%3E%2C%3CBAUDRATE%3E--%20get-property%2017%3C%2FBAUDRATE%3E%3C%2FPORT%3E%3C%2FSTRONG%3E%3C%2FEM%3E%3C%2FP%3E%3CBR%20%2F%3E%3CP%3EThanks!%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2350198%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CLINGO-LABEL%3ELPC55xx%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2350524%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%20translate%3D%22no%22%3ERe%3A%20LPC55S06%3A%20Determine%20Lifecycle%20property%20In-App%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2350524%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3EHello%20Carlos%2C%3CBR%20%2F%3Ecoolest%20profile%20pic!%3CBR%20%2F%3EThanks%20for%20the%20quick%20answer%2C%20this%20workaround%20works%20for%20me.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2350279%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%20translate%3D%22no%22%3ERe%3A%20LPC55S06%3A%20Determine%20Lifecycle%20property%20In-App%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2350279%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EHi%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fcommunity.nxp.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F261634%22%20target%3D%22_blank%22%3E%40sjrzcis%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThanks%20for%20your%20post!%3C%2FP%3E%0A%3CP%3EThe%20Lifecycle%20value%20can%20only%20be%20read%20through%20the%20bootloader.%20There%20is%20no%20API%20available%20to%20access%20this%20parameter%20from%20the%20user%20application.%3C%2FP%3E%0A%3CP%3EWe%20apologize%20for%20any%20inconvenience%20this%20may%20cause.%3C%2FP%3E%0A%3CP%3EAs%20a%20workaround%2C%20I%20recommend%20adding%20a%20custom%20parameter%20to%20your%20image%20to%20indicate%20the%20device%E2%80%99s%20lifecycle%20state.%3C%2FP%3E%3C%2FLINGO-BODY%3E