I got a problem with the deepsleepmode of my htcc-abo2. I use the deepsleepmode, but the board still need’s about 4mA. The display is off and i got no circuit only a LoRa connection to TTN. I use a official example code.
I included the following functions and With “lowPowerSleep(15000);” I activate the deepsleep mode
//Some utilities for going into low power mode
TimerEvent_t sleepTimer;
//Records whether our sleep/low power timer expired
bool sleepTimerExpired;
static void wakeUp()
{
sleepTimerExpired=true;
}
static void lowPowerSleep(uint32_t sleeptime)
{
sleepTimerExpired=false;
TimerInit( &sleepTimer, &wakeUp );
TimerSetValue( &sleepTimer, sleeptime );
TimerStart( &sleepTimer );
//Low power handler also gets interrupted by other timers
//So wait until our timer had expired
while (!sleepTimerExpired) lowPowerHandler();
TimerStop( &sleepTimer );
}