Page 1 of 1

min systick period & GPIO high frequency switching

Posted: Sat Jan 09, 2016 8:47 pm
by m.daddi
Hello everyone,
From what I've understood in ERIKA I can create periodic tasks that has only periods that are multiple of the systick period, isn't it?

The call to EE_systick_set_period(value) set how many CPU clock cycles a systick has to last.

But is there a lower bound (different from 1) for this value?

In my application I need a task with a period of 0.5 microseconds, and given my CPU (STM32F4, Discovery board) goes at 168MHz I've tried to call EE_systick_set_period(84) but my application fail to start with a so small systick period value (lower bound for let the system work seem at 250-300).

The problem is that I need to toggle a GPIO pin every 0.5 microseconds and before to toggle the pin I have to read another GPIO line... Is this all feasible?

Thanks!

Re: min systick period & GPIO high frequency switching

Posted: Mon Jan 11, 2016 9:57 am
by paolo.gai
...no... it is not. A minimal interrupt handler probably takes more than 0.5 usec on that machine!

Ciao,

PJ

Re: min systick period & GPIO high frequency switching

Posted: Mon Jan 11, 2016 10:45 am
by m.daddi
Ok, Thank you for the info (sorry but I've no idea even of the order of magnitude of the required execution time to manage interrupts)! ...I will try to use some other mechanism!

Thank you again, bye!