Hi everyone,
I have a project in which I need to use SoftwareSerial on pins 11-14 and pin change interrupts on pins A8-A13. The codes I wrote work separately, but when I put them together, I got a compiler error stating that __vector_11 had multiple definitions. After some research, I found on this page SDI-12 and SoftwareSerial Compatibility Issues · Issue #8 · EnviroDIY/Arduino-SDI-12 · GitHub that SoftwareSerial tries to create an ISR for all possible pin change interrupts, but I need it only for pins 11-14.
the solution they gave there was to modify the code of SoftwareSerial to comment out the lines for the wanted vector, but I cannot seem to find the SoftwareSerial files in my libraries, so I would like to know if there is a way to solve this problem. Thanks in advance!
Here is the relevant portion of code in the provided link:
#if defined(PCINT0_vect)
ISR(PCINT0_vect)
{
SoftwareSerial::handle_interrupt();
}
#endif
#if defined(PCINT1_vect)
ISR(PCINT1_vect)
{
SoftwareSerial::handle_interrupt();
}
#endif
#if defined(PCINT2_vect)
ISR(PCINT2_vect)
{
SoftwareSerial::handle_interrupt();
}
#endif
#if defined(PCINT3_vect)
ISR(PCINT3_vect)
{
SoftwareSerial::handle_interrupt();
}
#endif