mirror of
https://github.com/meshtastic/firmware.git
synced 2025-12-21 02:02:23 +00:00
new threading finished- saves about 10mA for the high activity states
This commit is contained in:
@@ -20,12 +20,12 @@ InterruptableDelay::~InterruptableDelay()
|
||||
bool InterruptableDelay::delay(uint32_t msec)
|
||||
{
|
||||
if (msec) {
|
||||
DEBUG_MSG("delay %u ", msec);
|
||||
// DEBUG_MSG("delay %u ", msec);
|
||||
|
||||
// sem take will return false if we timed out (i.e. were not interrupted)
|
||||
bool r = xSemaphoreTake(semaphore, pdMS_TO_TICKS(msec));
|
||||
|
||||
DEBUG_MSG("interrupt=%d\n", r);
|
||||
// DEBUG_MSG("interrupt=%d\n", r);
|
||||
return !r;
|
||||
} else {
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user