Ch 8 Flashcards

(5 cards)

1
Q

What is the main purpose of an Interrupt Service Routine(ISR)?

A

To execute a specialized function immediately when a interrupt flag is set, pausing the main program flow

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What command must be executed to enable all configured interrupts globally?

A

sei()-set enable interrupt

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Which type of external interrupt is reserved for only 2 pins but offers more versatile triggering options?

A

The dedicated external interrupts(INT0 and INT1)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Which type of external interrupt allows you to treat nearly every I/O pin as an interrupt source, although only detecting a change of state?

A

Pin-Change Interrupts(PCINT)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Why must a variable shared between the ISR and main() be replaced as volatile?

A

To tell the compiler that the variables value can change unexpectedly(outside of the normal program flow), preventing incorrect operation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly