mahfuz195 / BMP280-arduino-library

This BMP280 sensor library uses I2C communication with Arduino/ESP8266 and read the Temperature( degC) , Pressure (mBar) and Altitude (m).
46 stars 18 forks source link

Can't execute example #2

Open N0ury opened 8 years ago

N0ury commented 8 years ago

At compile time, I have the following errors:

Arduino : 1.6.10 (Mac OS X), Carte : "Arduino Duemilanove or Diecimila, ATmega328"

/Users/nb/Dropbox/arduino/libraries/BMP280-Arduino-Library/BMP280.cpp: In member function 'char BMP280::begin(int, int)': /Users/nb/Dropbox/arduino/libraries/BMP280-Arduino-Library/BMP280.cpp:33:26: error: no matching function for call to 'TwoWire::begin(int&, int&)' Wire.begin(sdaPin,sclPin); ^ /Users/nb/Dropbox/arduino/libraries/BMP280-Arduino-Library/BMP280.cpp:33:26: note: candidates are: In file included from /Users/nb/Dropbox/arduino/libraries/BMP280-Arduino-Library/BMP280.cpp:19:0: /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/Wire.h:52:10: note: void TwoWire::begin() void begin(); ^ /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/Wire.h:52:10: note: candidate expects 0 arguments, 2 provided /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/Wire.h:53:10: note: void TwoWire::begin(uint8_t) void begin(uint8_t); ^ /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/Wire.h:53:10: note: candidate expects 1 argument, 2 provided /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/Wire.h:54:10: note: void TwoWire::begin(int) void begin(int); ^ /Applications/Arduino.app/Contents/Java/hardware/arduino/avr/libraries/Wire/src/Wire.h:54:10: note: candidate expects 1 argument, 2 provided exit status 1 Erreur de compilation pour la carte Arduino Duemilanove or Diecimila

Ce rapport pourrait être plus détaillé avec l'option "Afficher les résultats détaillés de la compilation" activée dans Fichier -> Préférences.

Can you please help me

mahfuz195 commented 8 years ago

Don't sure which Wire.h library you are using. Try removing the arguments in Wire.begin() to match the parameters.

maopiccoto commented 7 years ago

I have same issue

Atominick commented 2 years ago

7