Fix interupt -> interrupt typo, including in some function names.
authorSami Liedes <sliedes@cc.hut.fi>
Mon, 28 Feb 2011 21:37:59 +0000 (23:37 +0200)
committerMichel Pollet <buserror@gmail.com>
Wed, 9 Mar 2011 07:59:50 +0000 (07:59 +0000)
Signed-off-by: Sami Liedes <sliedes@cc.hut.fi>
examples/board_timer_64led/timer_64led.c
simavr/sim/avr_extint.h
simavr/sim/avr_timer.c
simavr/sim/avr_twi.c
simavr/sim/avr_uart.c
simavr/sim/sim_interrupts.c
simavr/sim/sim_interrupts.h

index fe838f9..0495a19 100644 (file)
@@ -279,10 +279,10 @@ int main(int argc, char *argv[])
        avr_vcd_init(avr, "gtkwave_output.vcd", &vcd_file, 10000 /* usec */);
 
        avr_vcd_add_signal(&vcd_file, 
-               avr_get_interupt_irq(avr, 7), 1 /* bit */ ,
+               avr_get_interrupt_irq(avr, 7), 1 /* bit */ ,
                "TIMER2_COMPA" );
        avr_vcd_add_signal(&vcd_file, 
-               avr_get_interupt_irq(avr, 17), 1 /* bit */ ,
+               avr_get_interrupt_irq(avr, 17), 1 /* bit */ ,
                "SPI_INT" );
        avr_vcd_add_signal(&vcd_file, 
                i_mosi, 8 /* bits */ ,
index 480e505..fce4fa4 100644 (file)
@@ -1,7 +1,7 @@
 /*
        avr_extint.h
 
-       External Interupt Handling (for INT0-3)
+       External Interrupt Handling (for INT0-3)
 
        Copyright 2008, 2009 Michel Pollet <buserror@gmail.com>
 
index 2cf9344..8bdb7cf 100644 (file)
@@ -332,11 +332,11 @@ static void avr_timer_write_pending(struct avr_t * avr, avr_io_addr_t addr, uint
        avr_core_watch_write(avr, addr, v);
 
        // clear any interrupts & flags
-       avr_clear_interupt_if(avr, &p->overflow, ov);
-       avr_clear_interupt_if(avr, &p->icr, ic);
+       avr_clear_interrupt_if(avr, &p->overflow, ov);
+       avr_clear_interrupt_if(avr, &p->icr, ic);
 
        for (int compi = 0; compi < AVR_TIMER_COMP_COUNT; compi++)
-               avr_clear_interupt_if(avr, &p->comp[compi].interrupt, cp[compi]);
+               avr_clear_interrupt_if(avr, &p->comp[compi].interrupt, cp[compi]);
 }
 
 static void avr_timer_irq_icp(struct avr_irq_t * irq, uint32_t value, void * param)
index c605011..a8c15d8 100644 (file)
@@ -145,7 +145,7 @@ avr_twi_write(
        if (!twen)
                return;
 
-       int cleared = avr_clear_interupt_if(avr, &p->twi, twint);
+       int cleared = avr_clear_interrupt_if(avr, &p->twi, twint);
 
        // clear the interrupt if this bit is now written to 1
        if (cleared) {
index 4e6f0e5..f6000e6 100644 (file)
@@ -34,7 +34,7 @@ static avr_cycle_count_t avr_uart_txc_raise(struct avr_t * avr, avr_cycle_count_
 {
        avr_uart_t * p = (avr_uart_t *)param;
        if (avr_regbit_get(avr, p->txen)) {
-               // if the interrupts are not used, still raised the UDRE and TXC flag
+               // if the interrupts are not used, still raise the UDRE and TXC flag
                avr_raise_interrupt(avr, &p->udrc);
                avr_raise_interrupt(avr, &p->txc);
        }
@@ -143,14 +143,14 @@ static void avr_uart_write(struct avr_t * avr, avr_io_addr_t addr, uint8_t v, vo
        }
        if (addr == p->udrc.enable.reg) {
                /*
-                * If enabling the UDRC interupt, raise it immediately if FIFO is empty
+                * If enabling the UDRC interrupt, raise it immediately if FIFO is empty
                 */
                uint8_t udrce = avr_regbit_get(avr, p->udrc.enable);
                avr_core_watch_write(avr, addr, v);
                uint8_t nudrce = avr_regbit_get(avr, p->udrc.enable);
                if (!udrce && nudrce) {
-                       // if the FIDO is not empty (clear timer is flying) we dont
-                       // need to raise the interupt, it will happend when the timer
+                       // if the FIDO is not empty (clear timer is flying) we don't
+                       // need to raise the interrupt, it will happen when the timer
                        // is fired.
                        if (avr_cycle_timer_status(avr, avr_uart_txc_raise, p) == 0)
                                avr_raise_interrupt(avr, &p->udrc);
@@ -162,11 +162,11 @@ static void avr_uart_write(struct avr_t * avr, avr_io_addr_t addr, uint8_t v, vo
                uint8_t txc = avr_regbit_get(avr, p->txc.raised);
 
                // no need to write this value in here, only the
-               // interupt flags needs clearing!
+               // interrupt flags need clearing!
                // avr_core_watch_write(avr, addr, v);
 
-               //avr_clear_interupt_if(avr, &p->udrc, udre);
-               avr_clear_interupt_if(avr, &p->txc, txc);
+               //avr_clear_interrupt_if(avr, &p->udrc, udre);
+               avr_clear_interrupt_if(avr, &p->txc, txc);
        }
 }
 
index a52ea48..d1d2dca 100644 (file)
@@ -98,7 +98,7 @@ void avr_clear_interrupt(avr_t * avr, int v)
                avr_regbit_clear(avr, vector->raised);
 }
 
-int avr_clear_interupt_if(avr_t * avr, avr_int_vector_t * vector, uint8_t old)
+int avr_clear_interrupt_if(avr_t * avr, avr_int_vector_t * vector, uint8_t old)
 {
        if (avr_regbit_get(avr, vector->raised)) {
                avr_clear_interrupt(avr, vector->vector);
@@ -109,7 +109,7 @@ int avr_clear_interupt_if(avr_t * avr, avr_int_vector_t * vector, uint8_t old)
        return 0;
 }
 
-avr_irq_t * avr_get_interupt_irq(avr_t * avr, uint8_t v)
+avr_irq_t * avr_get_interrupt_irq(avr_t * avr, uint8_t v)
 {
        avr_int_vector_t * vector = avr->vector[v];
        return vector ? &vector->irq : NULL;
@@ -135,7 +135,7 @@ void avr_service_interrupts(avr_t * avr)
                                                        int bit = ffs(map)-1;
                                                        int v = (bi * 32) + bit;        // vector
                                                        avr_int_vector_t * vector = avr->vector[v];
-                                                       // if that single interupt is masked, ignore it and continue
+                                                       // if that single interrupt is masked, ignore it and continue
                                                        if (vector && !avr_regbit_get(avr, vector->enable)) {
                                                                map &= ~(1 << bit);
                                                                continue;
index 659a497..92d9c8c 100644 (file)
@@ -19,8 +19,8 @@
        along with simavr.  If not, see <http://www.gnu.org/licenses/>.
  */
 
-#ifndef __SIM_INTERUPTS_H__
-#define __SIM_INTERUPTS_H__
+#ifndef __SIM_INTERRUPTS_H__
+#define __SIM_INTERRUPTS_H__
 
 #include "sim_avr.h"
 #include "sim_irq.h"
@@ -58,14 +58,14 @@ void avr_clear_interrupt(avr_t * avr, int v);
 void avr_service_interrupts(avr_t * avr);
 
 // clear the interrupt (inc pending) if "raised" flag is 1
-int avr_clear_interupt_if(avr_t * avr, avr_int_vector_t * vector, uint8_t old);
+int avr_clear_interrupt_if(avr_t * avr, avr_int_vector_t * vector, uint8_t old);
 
 // return the IRQ that is raised when the vector is enabled and called/cleared
-// this allows tracing of pending interupts
-avr_irq_t * avr_get_interupt_irq(avr_t * avr, uint8_t v);
+// this allows tracing of pending interrupts
+avr_irq_t * avr_get_interrupt_irq(avr_t * avr, uint8_t v);
 
 #ifdef __cplusplus
 };
 #endif
 
-#endif /* __SIM_INTERUPTS_H__ */
+#endif /* __SIM_INTERRUPTS_H__ */