Skip to content

Commit

Permalink
Merge pull request ARMmbed#103 from linlingao/fix_nwp_reset
Browse files Browse the repository at this point in the history
Fix nwp warm reset
  • Loading branch information
linlingao authored Jun 10, 2019
2 parents cf04234 + 456339b commit 8faa800
Showing 1 changed file with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@
extern "C" {
#endif

#include <stdint.h>
#include <stdio.h>
#include "ti/drivers/net/wifi/wlan.h"

extern uint32_t SystemCoreClock; /*!< System Clock Frequency (Core Clock) */

Expand All @@ -57,6 +58,13 @@ extern void PRCMMCUReset(unsigned char bIncludeSubsystem);
*/
__STATIC_INLINE void __CC3200_SystemReset(void)
{
/* Stop the NWP */
_i16 retcode = sl_Stop(0);
if (retcode != 0 && retcode != SL_RET_CODE_DEV_NOT_STARTED)
{
printf("sl_stop failed with 0x%x\n", retcode);
}

PRCMMCUReset(0);
}
#ifdef NVIC_SystemReset
Expand Down

0 comments on commit 8faa800

Please sign in to comment.