Idle Hook example

samarte wrote on Sunday, February 01, 2009:

Hi,

I am searching for a student work a code (real example) for an idle hook, that is used for power saving modes like to put the procsessor into a low-power mode.

Thanks a lot :slight_smile:

Bye Samarte

edwards3 wrote on Sunday, February 01, 2009:

void vApplicationIdleHook( void )
{
    sleep();
}

That is it. The implementation of sleep() is dependent on the processor but will normally be a single asm instruction.

samarte wrote on Sunday, February 01, 2009:

Wow that is easy.

Thanks a lot … :slight_smile:

Bye Samarte