115 do not "notify" if "value" is the same as previous raise
Definition: sim_irq.h:63
void * param
Definition: sim_irq.c:34
uint8_t flags
IRQ_* flags.
Definition: sim_irq.h:82
void avr_free_irq(avr_irq_t *irq, uint32_t count)
Free allocated IRQs.
Definition: sim_irq.c:101
change polarity of the IRQ
Definition: sim_irq.h:62
IRQ Pool structure.
Definition: sim_irq.h:69
void avr_irq_unregister_notify(avr_irq_t *irq, avr_irq_notify_t notify, void *param)
Unregister a callback for an irq.
Definition: sim_irq.c:149
struct avr_irq_pool_t * pool
Definition: sim_irq.h:78
uint32_t value
current value
Definition: sim_irq.h:81
struct avr_irq_t ** irq
irqs belonging in this pool
Definition: sim_irq.h:72
struct avr_irq_t avr_irq_t
Public IRQ structure.
void avr_connect_irq(avr_irq_t *src, avr_irq_t *dst)
Connect a source IRQ to a destination IRQ.
Definition: sim_irq.c:210
struct avr_irq_hook_t * hook
list of hooks to be notified
Definition: sim_irq.h:83
struct avr_irq_pool_t avr_irq_pool_t
IRQ Pool structure.
void avr_init_irq(avr_irq_pool_t *pool, avr_irq_t *irq, uint32_t base, uint32_t count, const char **names)
Init 'count' IRQs, initializes their "irq" starting from 'base' and increment.
Definition: sim_irq.c:59
this irq structure was malloced via avr_alloc_irq
Definition: sim_irq.h:64
const char * name
Definition: sim_irq.h:79
void avr_raise_irq(avr_irq_t *irq, uint32_t value)
Raise an IRQ. I.e. call their 'hooks', and raise any chained IRQs, and set the new 'value'...
Definition: sim_irq.c:174
uint32_t irq
any value the user needs
Definition: sim_irq.h:80
void avr_irq_register_notify(avr_irq_t *irq, avr_irq_notify_t notify, void *param)
Register a notification hook (callback) for an irq.
Definition: sim_irq.c:129
this irq hasn't been used yet
Definition: sim_irq.h:65
avr_irq_notify_t notify
Definition: sim_irq.c:33
void avr_unconnect_irq(avr_irq_t *src, avr_irq_t *dst)
Disconnect a source IRQ to a destination IRQ.
Definition: sim_irq.c:232
int count
number of irqs living in the pool
Definition: sim_irq.h:71
Public IRQ structure.
Definition: sim_irq.h:76
avr_irq_t * avr_alloc_irq(avr_irq_pool_t *pool, uint32_t base, uint32_t count, const char **names)
Allocates 'count' IRQs, initializes their "irq" starting from 'base' and increment.
Definition: sim_irq.c:79
void(* avr_irq_notify_t)(struct avr_irq_t *irq, uint32_t value, void *param)
Callback Prototype.
Definition: sim_irq.h:58