adafruit / Adafruit_BMP085_Unified

Unified sensor driver for Adafruit's BMP085 & BMP180 breakouts
93 stars 60 forks source link

Error when compiling #10

Open kropochev opened 9 years ago

kropochev commented 9 years ago

In Arduino 1.5.3 for intel Galileo gen 2 with installed library Adafruit_Sensor and Adafruit_BMP085 an error:

BMP085/Adafruit_BMP085_U.cpp.o:(.rodata._ZTI23Adafruit_BMP085_Unified[_ZTI23Adafruit_BMP085_Unified]+0x8): undefined reference to `typeinfo for Adafruit_Sensor'
collect2: error: ld returned 1 exit status
speedkiller99 commented 9 years ago

im facing the same issue

ladyada commented 9 years ago

Make sure you downloaded the latest version of Adafruit_Sensor, we just made some changes!

ronistiawan commented 9 years ago

i got this error Arduino: 1.6.1 (Windows 8.1), Board: "Arduino Mega or Mega 2560, ATmega2560 (Mega 2560)" sensorapi.pde:2:29: fatal error: Adafruit_Sensor.h: No such file or directory

compilation terminated.

Error compiling.

This report would have more information with "Show verbose output during compilation" enabled in File > Preferences.

smoyerman commented 9 years ago

On the newest github release of Adafruit Sensor, I had to change the constructor to the following to get it to work with my Intel Edison.

class Adafruit_Sensor { public: // Constructor(s) void constructor();

// These must be defined by the subclass virtual void enableAutoRange(bool enabled) {}; //virtual bool getEvent(sensors_eventt); virtual bool getEvent(sensors_eventt)=0; //virtual void getSensor(sensort); virtual void getSensor(sensort)=0;

private: bool _autoRange; };

Udhay71 commented 1 year ago

error: redefinition of 'Adafruit_BMP085_Unified bmp' 40 | Adafruit_BMP085_Unified bmp; // I2C