Question: 4 . The following code is executed in a PIC 2 4 H processor with Fosc = 2 5 MHz: void _ ISRFAST _ T

4. The following code is executed in a PIC24H processor with Fosc=25MHz:
void _ISRFAST _T2Interrupt (void){
update_state();
_T2IF =0; }
int main (void){
T2CON=0x0020; /
PR2=1562;
TMR2=0;
_T2IF =0;
_T2IP =1;
_T2IE =1;
T2CONbits.TON =1;
while (1){
//.... other code in the program
}
}
King Saud University Semester I, 1446 H
College of Computer and Information Sciences CEN318: Design of Embedded Systems
Computer Engineering Department Homework 3
Compute the percentage of CPU time taken by the ISR. Assume the function call update_state()
consumes 50 instruction cycles and all other statements consume one instruction cycle.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!