I solved the issue by always sleeping for xExpectedIdleTime -1 ( replicating the logic in the native implementation) and would advise everyone to do the same when writing their own vPortSuppressTicksAndSleep. Anyway, thank you Richard for taking the time and for your support.
I a using the low power timer exclusively for the following purpose: keep count of the elaspsed time in deep sleep and wake the system up after the configured amount of time ( kind of alarm). The systick timer is used otherwise as the normal Tick counter. Before going to sleep all interrupts except the LowPowerTimerInterrupt are disabled. After coming from deep sleep, the low power timer interrupt executs and then the code resumes in vPortSuppressTicksAndSleep. After injecting the elapsed ticks in...
I a using the low power timer exclusively for the following purpose: keep count of the elaspsed time in deep sleep and wake it up after the configured amount of time ( kind of alarm). The systick timer is used otherwise as the normal Tick counter. Before going to sleep all interrupts except the LowPowerTimerInterrupt are disabled. After coming from deep sleep, the low power timer interrupt executs and then the code resumes in vPortSuppressTicksAndSleep. After injecting the elapsed ticks in deep sleep...
I failed to mention that I was using a low power timer to wake the system from sleep based on the template provided here. My tick rate is 1kHz and no other interrupts are taking place other than the TickInterruptTimer and the LowPowerTimer. The behavior I observed was different ( since I am using my own implementation of vPortSuppressTicksAndSleep). Mainly xTaskIncrementTick is only called when the TickInterruptTimer is restarted ( no pending ticks ) The other difference in my system is that when...
System crashes in in xTaskIncrementTick after TicklessIdle sleep