cc3200: Reduce soft reset time. WLAN is not reinit, just reenabled.
This commit is contained in:
parent
77791b5633
commit
59f6831336
@ -33,7 +33,7 @@
|
||||
#define SIMPLELINK_SPAWN_TASK_PRIORITY 3
|
||||
#define SIMPLELINK_TASK_STACK_SIZE 2048
|
||||
#define SL_STOP_TIMEOUT 35
|
||||
#define SL_STOP_TIMEOUT_LONG 255
|
||||
#define SL_STOP_TIMEOUT_LONG 205
|
||||
|
||||
/******************************************************************************
|
||||
DEFINE TYPES
|
||||
|
@ -226,6 +226,10 @@ void pybsleep_configure_timer_wakeup (uint pwrmode) {
|
||||
pybsleep_wake_cb.timer_wake_pwrmode = pwrmode;
|
||||
}
|
||||
|
||||
pybsleep_reset_cause_t pybsleep_get_reset_cause (void) {
|
||||
return pybsleep_reset_cause;
|
||||
}
|
||||
|
||||
/******************************************************************************
|
||||
DEFINE PRIVATE FUNCTIONS
|
||||
******************************************************************************/
|
||||
|
@ -72,5 +72,6 @@ void pybsleep_set_wlan_lpds_callback (mp_obj_t cb_obj);
|
||||
void pybsleep_set_gpio_lpds_callback (mp_obj_t cb_obj);
|
||||
void pybsleep_set_timer_lpds_callback (mp_obj_t cb_obj);
|
||||
void pybsleep_configure_timer_wakeup (uint pwrmode);
|
||||
pybsleep_reset_cause_t pybsleep_get_reset_cause (void);
|
||||
|
||||
#endif /* PYBSLEEP_H_ */
|
||||
|
@ -144,15 +144,13 @@ soft_reset:
|
||||
|
||||
mperror_enable_heartbeat();
|
||||
|
||||
if (MAP_PRCMSysResetCauseGet() != PRCM_HIB_EXIT) {
|
||||
// only if not comming out of hibernate
|
||||
if (pybsleep_get_reset_cause() < PYB_SLP_HIB_RESET) {
|
||||
// only if not comming out of hibernate or a soft reset
|
||||
mptask_enter_ap_mode();
|
||||
// don't check for safeboot when comming out of hibernate
|
||||
#ifndef DEBUG
|
||||
safeboot = PRCMIsSafeBootRequested();
|
||||
#endif
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
// when waking up from hibernate we just want
|
||||
// to enable simplelink and leave it as is
|
||||
wlan_first_start();
|
||||
@ -218,7 +216,7 @@ soft_reset:
|
||||
|
||||
// Main script is finished, so now go into REPL mode.
|
||||
// The REPL mode can change, or it can request a soft reset.
|
||||
for (;;) {
|
||||
for ( ; ; ) {
|
||||
if (pyexec_mode_kind == PYEXEC_MODE_RAW_REPL) {
|
||||
if (pyexec_raw_repl() != 0) {
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user