External interrupt (INT0, INT1...) on a single pin, one and 2 bit configuration. More...
#include <externalirq.h>


Public Member Functions | |
| ExternalIRQSingle (IOSpecialReg *ctrl, int ctrlOffset, int ctrlBits, Pin *pin, bool _8515mode=false) | |
| void | ChangeMode (unsigned char m) |
| Handle change of control register. | |
| bool | fireAgain (void) |
| does the interrupt source fire again? (for interrupt on level) | |
| bool | mustSetFlagOnFire (void) |
| does fire interrupt set the interrupt flag? (level interrupt does this not!) | |
| void | PinStateHasChanged (Pin *pin) |
Protected Types | |
| enum | { MODE_LEVEL_LOW = 0, MODE_EDGE_ALL = 1, MODE_EDGE_FALL = 2, MODE_EDGE_RISE = 3 } |
Protected Attributes | |
| bool | state |
| saved state from pin | |
| bool | twoBitMode |
| IRQ is controlled by 2 mode bits. | |
| bool | mode8515 |
| at90s8515 don't support MODE_EDGE_ALL | |
External interrupt (INT0, INT1...) on a single pin, one and 2 bit configuration.
Definition at line 110 of file externalirq.h.
anonymous enum [protected] |
| MODE_LEVEL_LOW |
Fire interrupt on low level. |
| MODE_EDGE_ALL |
Fire interrupt on any logical change. |
| MODE_EDGE_FALL |
Fire interrupt on falling edge. |
| MODE_EDGE_RISE |
Fire interrupt on rising edge. |
Definition at line 117 of file externalirq.h.
| ExternalIRQSingle::ExternalIRQSingle | ( | IOSpecialReg * | ctrl, | |
| int | ctrlOffset, | |||
| int | ctrlBits, | |||
| Pin * | pin, | |||
| bool | _8515mode = false | |||
| ) |
Definition at line 159 of file externalirq.cpp.
References mode8515, Pin::RegisterCallback(), ExternalIRQ::ResetMode(), state, and twoBitMode.

| void ExternalIRQSingle::ChangeMode | ( | unsigned char | m | ) | [virtual] |
Handle change of control register.
Reimplemented from ExternalIRQ.
Definition at line 203 of file externalirq.cpp.
References avr_warning, ExternalIRQ::mode, mode8515, MODE_EDGE_ALL, MODE_EDGE_FALL, and twoBitMode.
| bool ExternalIRQSingle::fireAgain | ( | void | ) | [virtual] |
does the interrupt source fire again? (for interrupt on level)
Reimplemented from ExternalIRQ.
Definition at line 212 of file externalirq.cpp.
References ExternalIRQ::mode, MODE_LEVEL_LOW, and state.
| bool ExternalIRQSingle::mustSetFlagOnFire | ( | void | ) | [virtual] |
does fire interrupt set the interrupt flag? (level interrupt does this not!)
Reimplemented from ExternalIRQ.
Definition at line 216 of file externalirq.cpp.
References ExternalIRQ::mode, and MODE_LEVEL_LOW.
| void ExternalIRQSingle::PinStateHasChanged | ( | Pin * | pin | ) | [virtual] |
Implements HasPinNotifyFunction.
Definition at line 169 of file externalirq.cpp.
References ExternalIRQ::fireInterrupt(), ExternalIRQ::mode, mode8515, MODE_EDGE_ALL, MODE_EDGE_FALL, MODE_EDGE_RISE, MODE_LEVEL_LOW, and state.

bool ExternalIRQSingle::mode8515 [protected] |
at90s8515 don't support MODE_EDGE_ALL
Definition at line 115 of file externalirq.h.
Referenced by ChangeMode(), ExternalIRQSingle(), and PinStateHasChanged().
bool ExternalIRQSingle::state [protected] |
saved state from pin
Definition at line 113 of file externalirq.h.
Referenced by ExternalIRQSingle(), fireAgain(), and PinStateHasChanged().
bool ExternalIRQSingle::twoBitMode [protected] |
IRQ is controlled by 2 mode bits.
Definition at line 114 of file externalirq.h.
Referenced by ChangeMode(), and ExternalIRQSingle().
1.6.3