Project Home
Project Home
Trackers
Trackers
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - Could I use only variables flag when interrupt handling sequence.: (1 Item)
   
Could I use only variables flag when interrupt handling sequence.  
Could I use only variables flag when interrupt handling sequence.

 

Now I planning the following style of interrupt handling,

Is it possible ?, or Not.

 

It is challenging style of Interrupt handling.

Usually use event or signal for notify when interrupts happen.

But it exist little bit overhead that processing notification.

 

And  I try to cut out the time of notification.

Is it able to realize?

 

Regards,

Kengo Kinoshita

 

Main()  <= main thread

 

ThreadCtl( _NTO_TCTL_IO, 0 );

 

interruptID1 = InterruptAttach     (

                        irq_TIM0,

                        isr_handler1,

                        NULL,

                        0,

                        0);

while(1){

 InterruptWait(NULL, NULL);

              switch( event_.sigev_code ){

                        case cPulseCodeTM0:

                                          // interrupt handling procedure

                        event_.sigev_code=0;

                    }

 }

}

 

const struct sigevent *isr_handler1( void *arg, int id)

{

          InterruptMask(      irq_TIM0  , id);

 event_.sigev_code             = cPulseCodeTM0;

 

 return( 0 );

// procmgr_event_notify()

 

}