SimAVR
AVR Simulator
|
Data Structures | |
struct | avr_int_vector_t |
interrupt vector for the IO modules More... | |
struct | avr_int_table_t |
Interrupt vectors, and their enable/clear registers. More... | |
Typedefs | |
typedef struct avr_int_vector_t | avr_int_vector_t |
interrupt vector for the IO modules More... | |
typedef struct avr_int_table_t | avr_int_table_t |
Interrupt vectors, and their enable/clear registers. More... | |
typedef struct avr_int_table_t * | avr_int_table_p |
Functions | |
void | avr_register_vector (struct avr_t *avr, avr_int_vector_t *vector) |
Register an interrupt vector. It's only needed if you want to use the "r_raised" flags. More... | |
int | avr_raise_interrupt (struct avr_t *avr, avr_int_vector_t *vector) |
Raise an interrupt (if enabled). More... | |
int | avr_has_pending_interrupts (struct avr_t *avr) |
Return non-zero if the AVR core has any pending interrupts. More... | |
int | avr_is_interrupt_pending (struct avr_t *avr, avr_int_vector_t *vector) |
Return nonzero if a specific interrupt vector is pending. More... | |
void | avr_clear_interrupt (struct avr_t *avr, avr_int_vector_t *vector) |
Clear the "pending" status of an interrupt. More... | |
void | avr_service_interrupts (struct avr_t *avr) |
Called by the core at each cycle to check whether an interrupt is pending. More... | |
int | avr_clear_interrupt_if (struct avr_t *avr, avr_int_vector_t *vector, uint8_t old) |
Clear the interrupt (inc pending) if "raised" flag is 1. More... | |
avr_irq_t * | avr_get_interrupt_irq (struct avr_t *avr, uint8_t v) |
Return the IRQ that is raised when the vector is enabled and called/cleared this allows tracing of pending interrupts. More... | |
void | avr_interrupt_init (struct avr_t *avr) |
Initializes the interrupt table. More... | |
void | avr_interrupt_reset (struct avr_t *avr) |
Reset the interrupt table and the fifo. More... | |
typedef struct avr_int_table_t * avr_int_table_p |
typedef struct avr_int_table_t avr_int_table_t |
Interrupt vectors, and their enable/clear registers.
typedef struct avr_int_vector_t avr_int_vector_t |
interrupt vector for the IO modules
void avr_clear_interrupt | ( | struct avr_t * | avr, |
avr_int_vector_t * | vector | ||
) |
Clear the "pending" status of an interrupt.
int avr_clear_interrupt_if | ( | struct avr_t * | avr, |
avr_int_vector_t * | vector, | ||
uint8_t | old | ||
) |
Clear the interrupt (inc pending) if "raised" flag is 1.
Return the IRQ that is raised when the vector is enabled and called/cleared this allows tracing of pending interrupts.
int avr_has_pending_interrupts | ( | struct avr_t * | avr | ) |
Return non-zero if the AVR core has any pending interrupts.
void avr_interrupt_init | ( | struct avr_t * | avr | ) |
Initializes the interrupt table.
void avr_interrupt_reset | ( | struct avr_t * | avr | ) |
Reset the interrupt table and the fifo.
int avr_is_interrupt_pending | ( | struct avr_t * | avr, |
avr_int_vector_t * | vector | ||
) |
Return nonzero if a specific interrupt vector is pending.
int avr_raise_interrupt | ( | struct avr_t * | avr, |
avr_int_vector_t * | vector | ||
) |
Raise an interrupt (if enabled).
The interrupt is latched and will be called later return non-zero if the interrupt was raised and is now pending
void avr_register_vector | ( | struct avr_t * | avr, |
avr_int_vector_t * | vector | ||
) |
Register an interrupt vector. It's only needed if you want to use the "r_raised" flags.
void avr_service_interrupts | ( | struct avr_t * | avr | ) |
Called by the core at each cycle to check whether an interrupt is pending.