- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
who can introduce sdk how to bootup,such as press power key ->bootloader->app.
- Labels:
-
SDK 3.x
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Are you looking for detecting a GPIO state change that triggers the reboot?
Here is the sample code:
/*
* Copyright 2016, Broadcom Corporation
* All Rights Reserved.
*
* This is UNPUBLISHED PROPRIETARY SOURCE CODE of Broadcom Corporation;
* the contents of this file may not be disclosed to third parties, copied
* or duplicated in any form, in whole or in part, without the prior
* written permission of Broadcom Corporation.
*/
#include "wiced.h"
#include "wiced_framework.h"
void application_start( )
{
/* Initialize the WICED device */
wiced_init();
WPRINT_APP_INFO( ( "Press WICED_BUTTON1 to reboot.\n" ) );
while ( 1 )
{
if ( wiced_gpio_input_get( WICED_BUTTON1 ) == WICED_FALSE )
{
printf( "Rebooting...\n" );
wiced_rtos_delay_milliseconds( 1000 );
wiced_framework_reboot();
}
if ( wiced_gpio_input_get( WICED_BUTTON2 ) == WICED_FALSE )
{
WPRINT_APP_INFO( ( "WICED_BUTTON2 pressed.\n" ) );
}
wiced_rtos_delay_milliseconds( 250 );
}
}
BR,
Seyhan