diff options
author | danicampora <danicampora@gmail.com> | 2015-03-04 13:52:39 +0100 |
---|---|---|
committer | danicampora <danicampora@gmail.com> | 2015-03-11 17:00:33 +0100 |
commit | 9e44383e3f4092940a1e1b49a278978df99f7b08 (patch) | |
tree | 606ad67566b41bb037bd02e678891dfb69db6c70 /cc3200/misc/mperror.c | |
parent | 73aee8da54f847341d0fd9718d05ca964654a6dd (diff) |
cc3200: Add power management framework. Add mpcallback class.
Supports suspend and hibernate modes. Waking is possible throug GPIO
and WLAN.
The mpcallback class is generic and can be reused by other classes.
Diffstat (limited to 'cc3200/misc/mperror.c')
-rw-r--r-- | cc3200/misc/mperror.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cc3200/misc/mperror.c b/cc3200/misc/mperror.c index 522e76396..32e04ba00 100644 --- a/cc3200/misc/mperror.c +++ b/cc3200/misc/mperror.c @@ -51,8 +51,8 @@ /****************************************************************************** DEFINE CONSTANTS ******************************************************************************/ -#define MPERROR_TOOGLE_MS (200) -#define MPERROR_SIGNAL_ERROR_MS (2000) +#define MPERROR_TOOGLE_MS (40) +#define MPERROR_SIGNAL_ERROR_MS (1000) #define MPERROR_HEARTBEAT_ON_MS (80) #define MPERROR_HEARTBEAT_OFF_MS (2920) @@ -113,7 +113,7 @@ void mperror_deinit_sfe_pin (void) { void mperror_signal_error (void) { uint32_t count = 0; - while ((MPERROR_TOOGLE_MS * count++) > MPERROR_SIGNAL_ERROR_MS) { + while ((MPERROR_TOOGLE_MS * count++) < MPERROR_SIGNAL_ERROR_MS) { // toogle the led MAP_GPIOPinWrite(MICROPY_SYS_LED_PORT, MICROPY_SYS_LED_PORT_PIN, ~MAP_GPIOPinRead(MICROPY_SYS_LED_PORT, MICROPY_SYS_LED_PORT_PIN)); UtilsDelay(UTILS_DELAY_US_TO_COUNT(MPERROR_TOOGLE_MS * 1000)); |