Fix TI demo project main.c to perform device initialization before provisioning
@@ -136,6 +136,12 @@ void vApplicationDaemonTaskStartupHook( void )
// Emit some serial port debugging
vTaskDelay( mainLOGGING_WIFI_STATUS_DELAY );
+
+
+
+ /* Initialize the AWS Libraries system. */
+ if( SYSTEM_Init() == pdPASS )
+ {
/* A simple example to demonstrate key and certificate provisioning in
* flash using PKCS#11 interface. This should be replaced
* by production ready key provisioning mechanism. This function must be called after
@@ -144,9 +150,6 @@ void vApplicationDaemonTaskStartupHook( void )
vDevModeKeyProvisioning();
prvProvisionRootCA();
- /* Initialize the AWS Libraries system. */
- if( SYSTEM_Init() == pdPASS )
- {
/* Show the possible security alerts that will affect re-flashing the device.
* When the number of security alerts reaches the threshold, the device file system is locked and
* the device cannot be automatically flashed, but must be reprogrammed with uniflash. This routine is placed
