To use ADS1115, I wrote this code at the beginning.
Of course, I did this after I got the Adafruit library.
However, the following error message is displayed every time.
<code name>:13:26: error: no matching function for call to 'Adafruit_ADS1115::Adafruit_ADS1115(int)'
I've just changed the code to
and run it.
Is there any problem with this?
That error means that there is no version of the constructor that accepts an argument of that data type.
There is no need to include the device address. That (0x48) is hard coded in the .h file.
Look at the examples that come with the library. Do they specify an address?
Thank you for replying! I checked the library, and yes, the sample code did not specify the address. I think I was referring to the code written in another version.
This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.