Resource handling inside ISRs

Forum related to ERIKA Enterprise and RT-Druid version 2

Moderator: paolo.gai

Locked
dvd86

Resource handling inside ISRs

Post by dvd86 »

Hello,

I need to acquire a resource from within an ISR2. I saw in the reference manual that it's possible to call GetResource()/ReleaseResource() inside these routines but I don't know how/where to declare that the ISR2 is using that resource. For the tasks, I just declare the used resources in the OIL file, but for the ISR2s I didn't find any information.

Thanks a lot!
e.guidieri

Re: Resource handling inside ISRs

Post by e.guidieri »

Resource handling at ISR2 level it's only implemented in PowerPC and Cortex Architecture, are you using one of them?
dvd86

Re: Resource handling inside ISRs

Post by dvd86 »

No, I'm not using any of them. I'm running on a Microchip dsPIC.
So, the only way I have is to activate a task from within the ISR2 that will cope with the critical section, right?
Since the ISR is called every 1ms, is there any rough estimate about the task activation time on dsPICs (running at 40MHz)?

Thanks
e.guidieri

Re: Resource handling inside ISRs

Post by e.guidieri »

Exactly that is the right approach.

You can find some benchmarck information about Erika on Cortex and PowerPC here:

http://erika.tuxfamily.org/wiki/index.p ... _Cortex_M4
http://download.tuxfamily.org/erika/web ... rk_ppc.pdf

Rough extimation of task activation time inside on dsPICs at 40 MHz: 8 - 9 us (microseconds)
Locked