Skip to content

Commit b59784d

Browse files
committed
Fix deprecated ISR names for ATmega8.
See #881
1 parent f88c984 commit b59784d

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

hardware/arduino/cores/arduino/HardwareSerial.cpp

+4-1
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,8 @@ inline void store_char(unsigned char c, ring_buffer *buffer)
104104
#if !defined(USART0_RX_vect) && defined(USART1_RX_vect)
105105
// do nothing - on the 32u4 the first USART is USART1
106106
#else
107-
#if !defined(USART_RX_vect) && !defined(USART0_RX_vect)
107+
#if !defined(USART_RX_vect) && !defined(USART0_RX_vect) && \
108+
!defined(USART_RXC_vect)
108109
#error "Don't know what the Data Received vector is called for the first UART"
109110
#else
110111
void serialEvent() __attribute__((weak));
@@ -114,6 +115,8 @@ inline void store_char(unsigned char c, ring_buffer *buffer)
114115
ISR(USART_RX_vect)
115116
#elif defined(USART0_RX_vect)
116117
ISR(USART0_RX_vect)
118+
#elif defined(USART_RXC_vect)
119+
ISR(USART_RXC_vect) // ATmega8
117120
#endif
118121
{
119122
#if defined(UDR0)

0 commit comments

Comments
 (0)