Merge pull request #7 from mali/working
[simavr] / simavr / sim / sim_io.h
index aa29a29..f0d44e6 100644 (file)
@@ -44,6 +44,8 @@ typedef struct avr_io_t {
        avr_t *                         avr;            // avr we are attached to
        const char *            kind;           // pretty name, for debug
 
+       const char ** irq_names;                // IRQ names
+
        uint32_t                        irq_ioctl_get;  // used to get irqs from this module
        int                                     irq_count;      // number of (optional) irqs
        struct avr_irq_t *      irq;            // optional external IRQs
@@ -62,7 +64,7 @@ typedef struct avr_io_t {
 
 // registers an IO module, so it's run(), reset() etc are called
 // this is called by the AVR core init functions, you /could/ register an external
-// one after instanciation, for whatever purpose...
+// one after instantiation, for whatever purpose...
 void
 avr_register_io(
                avr_t *avr,
@@ -74,7 +76,7 @@ avr_io_setirqs(
                avr_io_t * io,
                uint32_t ctl,
                int count,
-               avr_irq_t * irqs);
+               avr_irq_t * irqs );
 
 // register a callback for when IO register "addr" is read
 void
@@ -102,7 +104,7 @@ struct avr_irq_t * avr_io_getirq(avr_t * avr, uint32_t ctl, int index);
 // get the IRQ for an absolute IO address
 // this allows any code to hook an IRQ in any io address, for example
 // tracing changes of values into a register
-// Note that the values do not "magicaly" change, they change only
+// Note that the values do not "magically" change, they change only
 // when the AVR code attempt to read and write at that address
 // 
 // the "index" is a bit number, or ALL bits if index == 8