X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=simavr%2Fsim%2Favr_uart.h;h=8db33a074c48a4a1b1d1fdbc83696013849b97b7;hb=b8993c5f0de4c62c7ed9718612f028ad27fd31d9;hp=933af1154f95be64acebdcc03e9922da402ff24d;hpb=1b14bdb55e8dd1bdbcc410f16a500802c741741c;p=simavr diff --git a/simavr/sim/avr_uart.h b/simavr/sim/avr_uart.h index 933af11..8db33a0 100644 --- a/simavr/sim/avr_uart.h +++ b/simavr/sim/avr_uart.h @@ -19,8 +19,12 @@ along with simavr. If not, see . */ -#ifndef AVR_UART_H_ -#define AVR_UART_H_ +#ifndef __AVR_UART_H__ +#define __AVR_UART_H__ + +#ifdef __cplusplus +extern "C" { +#endif #include "sim_avr.h" @@ -30,7 +34,7 @@ DECLARE_FIFO(uint8_t, uart_fifo, 64); /* * The method of "connecting" the the UART from external code is to use 4 IRQS. - * The easy one is UART->YOU, where you will be called with the byte everytime + * The easy one is UART->YOU, where you will be called with the byte every time * the AVR firmware sends one. Do whatever you like with it. * * The slightly more tricky one is the INPUT part. Since the AVR is quite a bit @@ -117,4 +121,8 @@ typedef struct avr_uart_t { void avr_uart_init(avr_t * avr, avr_uart_t * port); -#endif /* AVR_UART_H_ */ +#ifdef __cplusplus +}; +#endif + +#endif /*__AVR_UART_H__*/