Getting linking error, multiple def of __vector_6

Started by [email protected], October 11, 2024, 12:29:21 PM

[email protected]

Hi, I'm using ver 2.2 of the LowPower_LowPowerLab library and am getting a linking error with my code, but not with the the TxRxBlinky.ino example from LowPowerLabs that uses the same library.  I've removed and reinstalled it...no change.  The error message below is probably very clear....but I don't understand what to do....I've limited experience with c/c++ .  My code is attached....it is just the initial plumbing for a project but is too long to insert.  I'm also attaching the verbose compile that results in the error.  Any help would be much appreciated! Thanks.....jim

LowPower.cpp.o (symbol from plugin)*: In function LowPowerClass::idle(period_t, adc_t, timer2_t, timer1_t, timer0_t, spi_t, usart0_t, twi_t)

Error linking for board Moteino(-USB)(Moteino_moteino_avr_Moteino)
Debug build failed for project 'FOB_transmitter'
(.text+0x0)*: multiple definition of __vector_6
FOB_transmitter.cpp.o (symbol from plugin)*: (.text+0x0): first defined here

collect2.exe*: error: ld returned 1 exit status


Felix

Does this happen with vanilla library and unmodified library example?
What IDE version?

[email protected]

Felix, thanks for the reply.  It is not happening with the unmodified library example.  I compiled IdleWakerPeriodic ok, then added the libraries that are in my code (below)....still compiled ok.  The IDE I'm using is  is 1.8.19.  I get the error if I compile through the Arduino IDE and with through visual studio 2022 ver 17.0.  Thx for your input....jim

#include <LowPower.h>
#include <PinChangeInterrupt.h>
#include <PinChangeInterruptBoards.h>
#include <PinChangeInterruptPins.h>
#include <PinChangeInterruptSettings.h>
#include <RFM69registers.h>
#include <RFM69.h>
#include <avr/interrupt.h>
#include <SPI.h>

Felix

Looks like a duplicate declaration of an interrupt or something like that.
"__vector_6" I think is what this points at, somewhere in all those interrupts libraries. You will have to dig that down depending on the libraries you want to inject.