coding problem

Hello and thanks for the opportunity.

I am a severe newbie!

I am using Arduino UNO and added Adafruit A/D converter ADS1015 for battery charger monitor, with LCD to show amps and volts.

I have followed tutorials but still have some problems.

In this case the error in IDE reads, “expected unqualified-id before ‘{’ token” on line 154.

Why is that, and how do I fix it?

Thanks so much for your help in advance.

===========================================

/*!

#if ARDUINO >= 100

#include “Arduino.h”

#else

#include “WProgram.h”

#endif

#include <Wire.h>

/* I2C ADDRESS/BITS */

#define ADS1015_ADDRESS (0x48) // 1001 000 (ADDR = GND)

/* CONVERSION DELAY (in mS) */

#define ADS1015_CONVERSIONDELAY (1)

/* POINTER REGISTER */

#define ADS1015_REG_POINTER_MASK (0x03)

#define ADS1015_REG_POINTER_CONVERT (0x00)

#define ADS1015_REG_POINTER_CONFIG (0x01)

#define ADS1015_REG_POINTER_LOWTHRESH (0x02)

#define ADS1015_REG_POINTER_HITHRESH (0x03)

/* CONFIG REGISTER */

#define ADS1015_REG_CONFIG_OS_MASK (0x8000)

#define ADS1015_REG_CONFIG_OS_SINGLE (0x8000) // Write: Set to start a single-conversion

#define ADS1015_REG_CONFIG_OS_BUSY (0x0000) // Read: Bit = 0 when conversion is in progress

#define ADS1015_REG_CONFIG_OS_NOTBUSY (0x8000) // Read: Bit = 1 when device is not performing a conversion

#define ADS1015_REG_CONFIG_MUX_MASK (0x7000)

#define ADS1015_REG_CONFIG_MUX_SINGLE_0 (0x4000) // Single-ended AIN0

#define ADS1015_REG_CONFIG_MUX_SINGLE_1 (0x5000) // Single-ended AIN1

#define ADS1015_REG_CONFIG_MUX_SINGLE_2 (0x6000) // Single-ended AIN2

#define ADS1015_REG_CONFIG_MUX_SINGLE_3 (0x7000) // Single-ended AIN3

#define ADS1015_REG_CONFIG_PGA_MASK (0x0E00)

#define ADS1015_REG_CONFIG_PGA_6_144V (0x0000) // +/-6.144V range = Gain 2/3

#define ADS1015_REG_CONFIG_PGA_4_096V (0x0200) // +/-4.096V range = Gain 1

#define ADS1015_REG_CONFIG_PGA_2_048V (0x0400) // +/-2.048V range = Gain 2 (default)

#define ADS1015_REG_CONFIG_PGA_1_024V (0x0600) // +/-1.024V range = Gain 4

#define ADS1015_REG_CONFIG_PGA_0_512V (0x0800) // +/-0.512V range = Gain 8

#define ADS1015_REG_CONFIG_PGA_0_256V (0x0A00) // +/-0.256V range = Gain 16

#define ADS1015_REG_CONFIG_MODE_MASK (0x0100)

#define ADS1015_REG_CONFIG_MODE_CONTIN (0x0000) // Continuous conversion mode

#define ADS1015_REG_CONFIG_MODE_SINGLE (0x0100) // Power-down single-shot mode (default)

#define ADS1015_REG_CONFIG_DR_MASK (0x00E0)

#define ADS1015_REG_CONFIG_DR_128SPS (0x0000) // 128 samples per second

#define ADS1015_REG_CONFIG_DR_250SPS (0x0020) // 250 samples per second

#define ADS1015_REG_CONFIG_DR_490SPS (0x0040) // 490 samples per second

#define ADS1015_REG_CONFIG_DR_920SPS (0x0060) // 920 samples per second

#define ADS1015_REG_CONFIG_DR_1600SPS (0x0080) // 1600 samples per second (default)

#define ADS1015_REG_CONFIG_DR_2400SPS (0x00A0) // 2400 samples per second

#define ADS1015_REG_CONFIG_DR_3300SPS (0x00C0) // 3300 samples per second

#define ADS1015_REG_CONFIG_CMODE_MASK (0x0010)

#define ADS1015_REG_CONFIG_CMODE_TRAD (0x0000) // Traditional comparator with hysteresis (default)

#define ADS1015_REG_CONFIG_CMODE_WINDOW (0x0010) // Window comparator

#define ADS1015_REG_CONFIG_CPOL_MASK (0x0008)

#define ADS1015_REG_CONFIG_CPOL_ACTVLOW (0x0000) // ALERT/RDY pin is low when active (default)

#define ADS1015_REG_CONFIG_CPOL_ACTVHI (0x0008) // ALERT/RDY pin is high when active

#define ADS1015_REG_CONFIG_CLAT_MASK (0x0004) // Determines if ALERT/RDY pin latches once asserted

#define ADS1015_REG_CONFIG_CLAT_NONLAT (0x0000) // Non-latching comparator (default)

#define ADS1015_REG_CONFIG_CLAT_LATCH (0x0004) // Latching comparator

#define ADS1015_REG_CONFIG_CQUE_MASK (0x0003)

#define ADS1015_REG_CONFIG_CQUE_1CONV (0x0000) // Assert ALERT/RDY after one conversions

#define ADS1015_REG_CONFIG_CQUE_2CONV (0x0001) // Assert ALERT/RDY after two conversions

#define ADS1015_REG_CONFIG_CQUE_4CONV (0x0002) // Assert ALERT/RDY after four conversions

#define ADS1015_REG_CONFIG_CQUE_NONE (0x0003) // Disable the comparator and put ALERT/RDY in high state (default)

#include <LiquidCrystal.h>

typedef enum

{

GAIN_TWOTHIRDS = ADS1015_REG_CONFIG_PGA_6_144V,

GAIN_ONE = ADS1015_REG_CONFIG_PGA_4_096V,

GAIN_TWO = ADS1015_REG_CONFIG_PGA_2_048V,

GAIN_FOUR = ADS1015_REG_CONFIG_PGA_1_024V,

GAIN_EIGHT = ADS1015_REG_CONFIG_PGA_0_512V,

GAIN_SIXTEEN = ADS1015_REG_CONFIG_PGA_0_256V

} adsGain_t;

class Adafruit_ADS1015

{

protected:

// Instance-specific properties

uint8_t m_i2cAddress;

uint8_t m_conversionDelay;

uint8_t m_bitShift;

adsGain_t m_gain;

public:

Adafruit_ADS1015(uint8_t i2cAddress = ADS1015_ADDRESS);

void begin(void);

uint16_t readADC_SingleEnded(uint8_t channel);

int16_t readADC_Differential_0_1(void);

int16_t readADC_Differential_2_3(void);

void startComparator_SingleEnded(uint8_t channel, int16_t threshold);

int16_t getLastConversionResults();

void setGain(adsGain_t gain);

adsGain_t getGain(void);

private:

};

// Derive from ADS1105 & override construction to set properties

class Adafruit_ADS1115 : public Adafruit_ADS1015

{

};

// from Adafruit-4-channel-adc-breakouts/programming

Adafruit_ADS1015 ads1015;

void setup(void)

{

Serial.begin(9600);

ads1015.begin();

}

void loop(void)

{

int16_t adc0, adc1, adc2, adc3;

adc0 = ads1015.readADC_SingleEnded(0);

adc1 = ads1015.readADC_SingleEnded(1);

adc2 = ads1015.readADC_SingleEnded(2);

adc3 = ads1015.readADC_SingleEnded(3);

Serial.print("AIN0: "); Serial.println(adc0);

Serial.print("AIN1: "); Serial.println(adc1);

Serial.print("AIN2: "); Serial.println(adc2);

Serial.print("AIN3: "); Serial.println(adc3);

Serial.println(" ");

delay(1000);

}

//end of ADS1015

LiquidCrystal lcd (12, 11, 5, 4, 3, 2);

const int numReadings = 100;

int readings[numReadings];

int index = 0;

int total = 0;

int average = 0;

int inputPin = 0;

{ lcd.begin(16, 2);

Serial.begin(9600);

for (int thisReading = 0; thisReading < numReadings; thisReading ++)

readings[thisReading] = 0;

total = total - readings [index];

readings [index] = analogRead (chgaPin);

total = total + readings[index];

index = index + 1;if (index >= numReadings) index = 0;

average = total / numReadings ;

Serial.println (average);

delay(1);

int chgaReading = analogRead(adc0);

float chgaVolts = chgaReading * 1.0 / 27.0 ;

lcd.setCursor(0, 0);

lcd.print (“+ A”);

lcd.setCursor (1, 0);

lcd.print(chgaVolts);

int bavoltReading = analogRead(adc2);

float bavoltVolts = bavoltReading * 1.0 / 56.0 ;

lcd.setCursor (9, 0);

lcd.print (" V");

lcd.setCursor (10, 0);

lcd.print (bavoltVolts);

}

“expected unqualified-id before ‘{’ token” on line 154.

You ended the loop with a } after the delay(1000); on line 140. So the compiler next sees a code-block opening {-bracket at line 154 without a function-header and doesn’t know what to do with this.

Tip: Please edit your post in the full editor and press the code button. This generates [ code ] [/ code] tags in the window. Please place that long list of code in between the inner ] and [ brackets. That makes the post easier to read, and make the page alot shorter.

Please go back and read these …

http://arduino.cc/en/Tutorial/Foundations#.Ux3HxIWmWVI

http://arduino.cc/en/Tutorial/Sketch#.Ux3H74WmWVI

http://arduino.cc/en/Tutorial/BareMinimum#.Ux3BwoWmWVI

http://arduino.cc/en/Reference/Setup#.Ux3GAIWmWVI

http://arduino.cc/en/Reference/Loop#.Ux3GLIWmWVI

http://arduino.cc/en/Reference/Function … x3IKIWmWVI

http://arduino.cc/en/Reference/LiquidCr … x3GXYWmWVI

Your code is a mess of cut’n’paste. For example this block resides outside of the setup() and loop() functions and yet is not a function itself. Parts of it are supposed to reside in both of the aforementioned.

{ lcd.begin(16, 2);

Serial.begin(9600);
for (int thisReading = 0; thisReading < numReadings; thisReading ++)
readings[thisReading] = 0;


total = total - readings [index];
readings [index] = analogRead (chgaPin);
total = total + readings[index];
index = index + 1;if (index >= numReadings) index = 0;
average = total / numReadings ;
Serial.println (average);
delay(1);

int chgaReading = analogRead(adc0);
float chgaVolts = chgaReading * 1.0 / 27.0 ;

lcd.setCursor(0, 0);
lcd.print ("+ A");
lcd.setCursor (1, 0);
lcd.print(chgaVolts);

int bavoltReading = analogRead(adc2);
float bavoltVolts = bavoltReading * 1.0 / 56.0 ;

lcd.setCursor (9, 0);
lcd.print (" V");
lcd.setCursor (10, 0);
lcd.print (bavoltVolts);
}

(click to open/enlarge)

Thanks very much for the detailed replies.

I will investigate EVERYTHING that’s been said to check my problems/errors and try to remedy all I’ve done incorrectly before I reply again.

My sincere thanks, and especially for the DETAILS of my errors. As a newbie at programming and microprocessors this is invaluable information to get me going to fix my errors.

I would advise you to break your project into pieces. Get the code for just the LCD working first. See if you can display some hard coded messages. Then add the A/D code and get that working.

Is there some “burning” reason to use the external 12bit ADC vs the Uno’s internal 10 bit ADC ? The latter would be a lot simpler.

Good morning, and thanks for yours.

I had the whole code working with UNO and LCD using internal A/D but found that the display wobbled around too much, viz. input to display (say) 20.00V would bounce between 20.30 to 19.40 and everything in between. I put this down to the D/A sampling and tried to average but eventually decided that the 12-bit D/A should solve that, i.e. discarding the LSB (or 2). So I bought the board and added the program to my sketch. Clearly I mismatched the code, winding up with my messy ‘total’ sketch.

With hindsight, I should have made this clearer to begin with.

I will go back to the tutorials to find the mistakes. I just jumped in at the deep end because I was/am eager to get the project to fly.

Thank you for your help and advice.

I will reply later after learning up some more.

While going to a less noisy ADC might help, I doubt noise at the ADC end was your problem. Even with a 4:1 voltage divider, a UNO lsb would only be ~20 mV. And I typically see only 1-2 lsb’s of noise. So your 500+ mV must be coming from somewhere else.

Yes, you are right.

Typo my side : I should have written 20.03 to 19.04 changes.

It still causes doubt into the system, e.g. another could say, “Why does the voltage jump around without anything happening?”

Hence my choice to switch to the 12bit ADC (and discard the LSB).

(Example : standard 3 + 1/2 digit DMM may jump 1 LSB = 20mV on 20V scale, so LSB could be ignored…)

I have since last tried to tie up my first sketch (which worked, giving me the wobbly readings) to new sketch including the ADS1015 but still get the errors with programming which is my fault. Despite much re-learning from tutorials (on-going) and advice, I can’t solve.

Also, I have not properly identified the inputs and coordinated (range, gain…) and having problems doing that.

In each case I have reduced the max. input range voltages to 0…+4.90V (irrespective of the real input voltage) to avoid damage to the APS.

My first challenge is to get the sketch working as it is after fixing what I can, so that I can find the errors and correct them in reality.

/*!

#if ARDUINO >= 100
#include "Arduino.h"
#else
#include "WProgram.h"
#endif
#include <Wire.h>
#include <LiquidCrystal.h>
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);

/*    I2C ADDRESS/BITS    */
#define ADS1015_ADDRESS (0x48) // 1001 000 (ADDR = GND)

/*       CONVERSION DELAY (in mS)       */
#define ADS1015_CONVERSIONDELAY (1)

/*       POINTER REGISTER               */
#define ADS1015_REG_POINTER_MASK (0x03)
#define ADS1015_REG_POINTER_CONVERT (0x00)
#define ADS1015_REG_POINTER_CONFIG (0x01)
#define ADS1015_REG_POINTER_LOWTHRESH (0x02)
#define ADS1015_REG_POINTER_HITHRESH (0x03)

/*       CONFIG REGISTER                  */
#define ADS1015_REG_CONFIG_OS_MASK (0x8000)
#define ADS1015_REG_CONFIG_OS_SINGLE (0x8000) // Write: Set to start a single-conversion
#define ADS1015_REG_CONFIG_OS_BUSY (0x0000) // Read: Bit = 0 when conversion is in progress
#define ADS1015_REG_CONFIG_OS_NOTBUSY (0x8000) // Read: Bit = 1 when device is not performing a conversion

#define ADS1015_REG_CONFIG_MUX_MASK (0x7000)

#define ADS1015_REG_CONFIG_MUX_SINGLE_0 (0x4000) // Single-ended AIN0
#define ADS1015_REG_CONFIG_MUX_SINGLE_1 (0x5000) // Single-ended AIN1
#define ADS1015_REG_CONFIG_MUX_SINGLE_2 (0x6000) // Single-ended AIN2
#define ADS1015_REG_CONFIG_MUX_SINGLE_3 (0x7000) // Single-ended AIN3

#define ADS1015_REG_CONFIG_PGA_MASK (0x0E00)
#define ADS1015_REG_CONFIG_PGA_6_144V (0x0000) // +/-6.144V range = Gain 2/3
#define ADS1015_REG_CONFIG_PGA_4_096V (0x0200) // +/-4.096V range = Gain 1
#define ADS1015_REG_CONFIG_PGA_2_048V (0x0400) // +/-2.048V range = Gain 2 (default)
#define ADS1015_REG_CONFIG_PGA_1_024V (0x0600) // +/-1.024V range = Gain 4
#define ADS1015_REG_CONFIG_PGA_0_512V (0x0800) // +/-0.512V range = Gain 8
#define ADS1015_REG_CONFIG_PGA_0_256V (0x0A00) // +/-0.256V range = Gain 16

#define ADS1015_REG_CONFIG_MODE_MASK (0x0100)
#define ADS1015_REG_CONFIG_MODE_CONTIN (0x0000) // Continuous conversion mode
#define ADS1015_REG_CONFIG_MODE_SINGLE (0x0100) // Power-down single-shot mode (default)

#define ADS1015_REG_CONFIG_DR_MASK (0x00E0)
#define ADS1015_REG_CONFIG_DR_128SPS (0x0000) // 128 samples per second
#define ADS1015_REG_CONFIG_DR_250SPS (0x0020) // 250 samples per second
#define ADS1015_REG_CONFIG_DR_490SPS (0x0040) // 490 samples per second
#define ADS1015_REG_CONFIG_DR_920SPS (0x0060) // 920 samples per second
#define ADS1015_REG_CONFIG_DR_1600SPS (0x0080) // 1600 samples per second (default)
#define ADS1015_REG_CONFIG_DR_2400SPS (0x00A0) // 2400 samples per second
#define ADS1015_REG_CONFIG_DR_3300SPS (0x00C0) // 3300 samples per second

#define ADS1015_REG_CONFIG_CMODE_MASK (0x0010)
#define ADS1015_REG_CONFIG_CMODE_TRAD (0x0000) // Traditional comparator with hysteresis (default)
#define ADS1015_REG_CONFIG_CMODE_WINDOW (0x0010) // Window comparator

#define ADS1015_REG_CONFIG_CPOL_MASK (0x0008)
#define ADS1015_REG_CONFIG_CPOL_ACTVLOW (0x0000) // ALERT/RDY pin is low when active (default)
#define ADS1015_REG_CONFIG_CPOL_ACTVHI (0x0008) // ALERT/RDY pin is high when active

#define ADS1015_REG_CONFIG_CLAT_MASK (0x0004) // Determines if ALERT/RDY pin latches once asserted
#define ADS1015_REG_CONFIG_CLAT_NONLAT (0x0000) // Non-latching comparator (default)
#define ADS1015_REG_CONFIG_CLAT_LATCH (0x0004) // Latching comparator

#define ADS1015_REG_CONFIG_CQUE_MASK (0x0003)
#define ADS1015_REG_CONFIG_CQUE_1CONV (0x0000) // Assert ALERT/RDY after one conversions
#define ADS1015_REG_CONFIG_CQUE_2CONV (0x0001) // Assert ALERT/RDY after two conversions
#define ADS1015_REG_CONFIG_CQUE_4CONV (0x0002) // Assert ALERT/RDY after four conversions
#define ADS1015_REG_CONFIG_CQUE_NONE (0x0003) // Disable the comparator and put ALERT/RDY in high state (default)

#include <LiquidCrystal.h>

typedef enum
{
  GAIN_TWOTHIRDS = ADS1015_REG_CONFIG_PGA_6_144V,
  GAIN_ONE = ADS1015_REG_CONFIG_PGA_4_096V,
  GAIN_TWO = ADS1015_REG_CONFIG_PGA_2_048V,
  GAIN_FOUR = ADS1015_REG_CONFIG_PGA_1_024V,
  GAIN_EIGHT = ADS1015_REG_CONFIG_PGA_0_512V,
  GAIN_SIXTEEN = ADS1015_REG_CONFIG_PGA_0_256V
} adsGain_t;

class Adafruit_ADS1015
{
protected:
   // Instance-specific properties
   uint8_t m_i2cAddress;
   uint8_t m_conversionDelay;
   uint8_t m_bitShift;
   adsGain_t m_gain;

 public:
  Adafruit_ADS1015(uint8_t i2cAddress = ADS1015_ADDRESS);
  void begin(void);
  uint16_t readADC_SingleEnded(uint8_t channel);
  int16_t readADC_Differential_0_1(void);
  int16_t readADC_Differential_2_3(void);
  void startComparator_SingleEnded(uint8_t channel, int16_t threshold);
  int16_t getLastConversionResults();
  void setGain(adsGain_t gain);
  adsGain_t getGain(void);

 private:
};

// Derive from ADS1105 & override construction to set properties
class Adafruit_ADS1115 : public Adafruit_ADS1015 
{   };
// from Adafruit-4-channel-adc-breakouts/programming

Adafruit_ADS1015 ads1015;
 
void setup()

  
Serial.begin(9600);
{
ads1015.begin();
//}
 
void loop(void)
{
int16_t adc0, adc1, adc2, adc3;
 
adc0 = ads1015.readADC_SingleEnded(0);
adc1 = ads1015.readADC_SingleEnded(1);
adc2 = ads1015.readADC_SingleEnded(2);
adc3 = ads1015.readADC_SingleEnded(3);
Serial.print("AIN0: "); Serial.println(adc0);
Serial.print("AIN1: "); Serial.println(adc1);
Serial.print("AIN2: "); Serial.println(adc2);
Serial.print("AIN3: "); Serial.println(adc3);
Serial.println(" ");
delay(1000);
}
//end of ADS1015
{
Serial.begin(9600);
  
  int chgaReading = analogRead(adc0);
  float chgaVolts = chgaReading * 1.0 / 27.0 ;
    
  lcd.setCursor(0, 0);
  lcd.print ("+     A");
  lcd.setCursor (1, 0);
  lcd.print(chgaVolts);
    
  int bavoltReading = analogRead(adc2);
  float bavoltVolts = bavoltReading * 1.0 / 56.0 ;
  
  lcd.setCursor (9, 0);
  lcd.print ("      V");
  lcd.setCursor (10, 0);
  lcd.print (bavoltVolts);
 }

which gives me errors :

bm04a:122: error: expected initializer before ‘Serial’

bm04a:123: error: expected unqualified-id before ‘{’ token

I need some help.

Thanks in advance.

Again a lot of spaghetti tossed at the wall to see what’ll stick.

ie - what’s this for. I did a quick look at the Adafruit tutorial code and don’t remember seeing it there. Looks to be part of some (background) library code, which should already be accounted for by some #include

class Adafruit_ADS1015
{
protected:
   // Instance-specific properties
   uint8_t m_i2cAddress;
   uint8_t m_conversionDelay;
   uint8_t m_bitShift;
   adsGain_t m_gain;

 public:
  Adafruit_ADS1015(uint8_t i2cAddress = ADS1015_ADDRESS);
  void begin(void);
  uint16_t readADC_SingleEnded(uint8_t channel);
  int16_t readADC_Differential_0_1(void);
  int16_t readADC_Differential_2_3(void);
  void startComparator_SingleEnded(uint8_t channel, int16_t threshold);
  int16_t getLastConversionResults();
  void setGain(adsGain_t gain);
  adsGain_t getGain(void);

 private:
};

// Derive from ADS1105 & override construction to set properties
class Adafruit_ADS1115 : public Adafruit_ADS1015
{   };

Also why do you have this twice ?

Serial.begin(9600);

What does it do and where does it belong ?

Lastly (for now) … do you really need all those defines ? It might not hurt but it sure makes it harder to read your code, which shouldn’t be much more than what’s in the tutorial.

Simple is better than complicated.

ps - noise is present in every circuit. Average and/or filter to reduce. Your assumption is that it’s all due to the ADC and that increased bit depth = less noise. This isn’t always true.

Newbie10:

which gives me errors :

bm04a:122: error: expected initializer before ‘Serial’

bm04a:123: error: expected unqualified-id before ‘{’ token

I need some help.

Thanks in advance.

Similar reason as my first message in this thread. Function call to Serial.begin found being outside of { } block. Actually, there isn’t even a full { } block, as you can see in the image below.

Tip: Use a program like Notepad++ to see your code with keyword highlighting, { }bracket count checks, and proper line-numbering. It can analyse your Arduino code as it is similar/same as C++ code.

It helps making the obvious beginner errors stand out. The Arduino IDE does this partially (keyword highlighting), it doesn’t show line-numbering. Nor does it show which { }-brackets are related.

Okay, thanks. I downloaded Notepad++ and fixed a lot more.

Background. I did this as my first sketch (which flies like a bird) (not like MH370…) :

#include <LiquidCrystal.h>

int chgaPin = 0;

LiquidCrystal lcd(12, 11, 5, 4, 3, 2);

void setup() 
{
  lcd.begin(16, 2);
}

void loop() {

  int chgaReading = analogRead(chgaPin);
  float chgaVolts = chgaReading * 1.0 / 5255.0;
  float chgaC = (chgaVolts) * 100.0;
  lcd.print("+     A");
  lcd.setCursor(2, 0);
  lcd.print(chgaC);

  delay(600);
}

but then decided I needed the 12-bit DAC so pasted from Adafruit which started my severe challenge.

I am now at this :

 #if ARDUINO >= 100
 #include "Arduino.h"
 #else
 #include "WProgram.h"
 #endif
 #include <Wire.h>
 #include <LiquidCrystal.h>
 
 LiquidCrystal lcd(12, 11, 5, 4, 3, 2);
 
/*    I2C ADDRESS/BITS    */
#define ADS1015_ADDRESS (0x48) // 1001 000 (ADDR = GND)

/*       CONVERSION DELAY (in mS)       */
#define ADS1015_CONVERSIONDELAY (1)

/*       POINTER REGISTER               */
#define ADS1015_REG_POINTER_MASK (0x03)
#define ADS1015_REG_POINTER_CONVERT (0x00)
#define ADS1015_REG_POINTER_CONFIG (0x01)
#define ADS1015_REG_POINTER_LOWTHRESH (0x02)
#define ADS1015_REG_POINTER_HITHRESH (0x03)

/*       CONFIG REGISTER                  */
#define ADS1015_REG_CONFIG_OS_MASK (0x8000)
#define ADS1015_REG_CONFIG_OS_SINGLE (0x8000) // Write: Set to start a single-conversion
#define ADS1015_REG_CONFIG_OS_BUSY (0x0000) // Read: Bit = 0 when conversion is in progress
#define ADS1015_REG_CONFIG_OS_NOTBUSY (0x8000) // Read: Bit = 1 when device is not performing a conversion

#define ADS1015_REG_CONFIG_MUX_MASK (0x7000)

#define ADS1015_REG_CONFIG_MUX_SINGLE_0 (0x4000) // Single-ended AIN0
#define ADS1015_REG_CONFIG_MUX_SINGLE_1 (0x5000) // Single-ended AIN1
#define ADS1015_REG_CONFIG_MUX_SINGLE_2 (0x6000) // Single-ended AIN2
#define ADS1015_REG_CONFIG_MUX_SINGLE_3 (0x7000) // Single-ended AIN3

#define ADS1015_REG_CONFIG_PGA_MASK (0x0E00)
#define ADS1015_REG_CONFIG_PGA_6_144V (0x0000) // +/-6.144V range = Gain 2/3
#define ADS1015_REG_CONFIG_PGA_4_096V (0x0200) // +/-4.096V range = Gain 1
#define ADS1015_REG_CONFIG_PGA_2_048V (0x0400) // +/-2.048V range = Gain 2 (default)
#define ADS1015_REG_CONFIG_PGA_1_024V (0x0600) // +/-1.024V range = Gain 4
#define ADS1015_REG_CONFIG_PGA_0_512V (0x0800) // +/-0.512V range = Gain 8
#define ADS1015_REG_CONFIG_PGA_0_256V (0x0A00) // +/-0.256V range = Gain 16

#define ADS1015_REG_CONFIG_MODE_MASK (0x0100)
#define ADS1015_REG_CONFIG_MODE_CONTIN (0x0000) // Continuous conversion mode
#define ADS1015_REG_CONFIG_MODE_SINGLE (0x0100) // Power-down single-shot mode (default)

#define ADS1015_REG_CONFIG_DR_MASK (0x00E0)
#define ADS1015_REG_CONFIG_DR_128SPS (0x0000) // 128 samples per second
#define ADS1015_REG_CONFIG_DR_250SPS (0x0020) // 250 samples per second
#define ADS1015_REG_CONFIG_DR_490SPS (0x0040) // 490 samples per second
#define ADS1015_REG_CONFIG_DR_920SPS (0x0060) // 920 samples per second
#define ADS1015_REG_CONFIG_DR_1600SPS (0x0080) // 1600 samples per second (default)
#define ADS1015_REG_CONFIG_DR_2400SPS (0x00A0) // 2400 samples per second
#define ADS1015_REG_CONFIG_DR_3300SPS (0x00C0) // 3300 samples per second

#define ADS1015_REG_CONFIG_CMODE_MASK (0x0010)
#define ADS1015_REG_CONFIG_CMODE_TRAD (0x0000) // Traditional comparator with hysteresis (default)
#define ADS1015_REG_CONFIG_CMODE_WINDOW (0x0010) // Window comparator

#define ADS1015_REG_CONFIG_CPOL_MASK (0x0008)
#define ADS1015_REG_CONFIG_CPOL_ACTVLOW (0x0000) // ALERT/RDY pin is low when active (default)
#define ADS1015_REG_CONFIG_CPOL_ACTVHI (0x0008) // ALERT/RDY pin is high when active

#define ADS1015_REG_CONFIG_CLAT_MASK (0x0004) // Determines if ALERT/RDY pin latches once asserted
#define ADS1015_REG_CONFIG_CLAT_NONLAT (0x0000) // Non-latching comparator (default)
#define ADS1015_REG_CONFIG_CLAT_LATCH (0x0004) // Latching comparator

#define ADS1015_REG_CONFIG_CQUE_MASK (0x0003)
#define ADS1015_REG_CONFIG_CQUE_1CONV (0x0000) // Assert ALERT/RDY after one conversions
#define ADS1015_REG_CONFIG_CQUE_2CONV (0x0001) // Assert ALERT/RDY after two conversions
#define ADS1015_REG_CONFIG_CQUE_4CONV (0x0002) // Assert ALERT/RDY after four conversions
#define ADS1015_REG_CONFIG_CQUE_NONE (0x0003) // Disable the comparator and put ALERT/RDY in high state (default)

#include <LiquidCrystal.h>

typedef enum
{
  GAIN_TWOTHIRDS = ADS1015_REG_CONFIG_PGA_6_144V,
  GAIN_ONE = ADS1015_REG_CONFIG_PGA_4_096V,
  GAIN_TWO = ADS1015_REG_CONFIG_PGA_2_048V,
  GAIN_FOUR = ADS1015_REG_CONFIG_PGA_1_024V,
  GAIN_EIGHT = ADS1015_REG_CONFIG_PGA_0_512V,
  GAIN_SIXTEEN = ADS1015_REG_CONFIG_PGA_0_256V
} 
adsGain_t;

class Adafruit_ADS1015
{
protected:
  // Instance-specific properties
  uint8_t m_i2cAddress;
  uint8_t m_conversionDelay;
  uint8_t m_bitShift;
  adsGain_t m_gain;

public:
  Adafruit_ADS1015(uint8_t i2cAddress = ADS1015_ADDRESS);
  void begin(void);
  uint16_t readADC_SingleEnded(uint8_t channel);
  int16_t readADC_Differential_0_1(void);
  int16_t readADC_Differential_2_3(void);
  void startComparator_SingleEnded(uint8_t channel, int16_t threshold);
  int16_t getLastConversionResults();
  void setGain(adsGain_t gain);
  adsGain_t getGain(void);

private:
};

// Derive from ADS1105 & override construction to set properties
class Adafruit_ADS1115 : 
public Adafruit_ADS1015
{   
};
// from Adafruit-4-channel-adc-breakouts/programming

Adafruit_ADS1015 ads1015;

void setup(void)
{
  Serial.begin(9600);

  ads1015.begin();
}
{
  int16_t adc0, adc1, adc2, adc3;

  adc0 = ads1015.readADC_SingleEnded(0);
  adc1 = ads1015.readADC_SingleEnded(1);
  adc2 = ads1015.readADC_SingleEnded(2);
  adc3 = ads1015.readADC_SingleEnded(3);
  Serial.print("AIN0: "); 
  Serial.println(adc0);
  Serial.print("AIN1: "); 
  Serial.println(adc1);
  Serial.print("AIN2: "); 
  Serial.println(adc2);
  Serial.print("AIN3: "); 
  Serial.println(adc3);
  Serial.println(" ");
  delay(1000);

  //end of ADS1015

  void loop(void)
    lcd.begin (16, 2);

  int chgaReading = analogRead(adc0);
  float chgaVolts = chgaReading * 1.0 / 27.0 ;

  lcd.setCursor(0, 0);
  lcd.print ("+     A");
  lcd.setCursor (1, 0);
  lcd.print(chgaVolts);

  int bavoltReading = analogRead(adc2);
  float bavoltVolts = bavoltReading * 1.0 / 56.0 ;

  lcd.setCursor (9, 0);
  lcd.print ("      V");
  lcd.setCursor (10, 0);
  lcd.print (bavoltVolts);
}

which gives me just one error : unexpected unqualified-id before ‘{’… (situated just above “int16_t adc0, adc1. adc2, adc3;”)

which I just cannot resolve. Whatever I try here simply adds to the problem. I realise that there is something BEFORE this point causing the hassle but I can’t find it.

(I also realise now that I should have attacked the problem in a different way, and have therefore wiped out other [momentarily unnecessary] stuff to simplify the sketch. Once THIS one is running I will test it and if that flies I’ll add the other stuff in small steps, checking regularly while climbing the ladder.)

Thanks for your patience and help…

which gives me just one error : unexpected unqualified-id before ‘{’… (situated just above “int16_t adc0, adc1. adc2, adc3;”)…

Again as the very first message: an isolated code block, without a function header to precede it telling the compiler how to interpret it. void setup ends right after ads1015.begin(); on line 127. What do you think starts after that with the { bracket?

And I’ll spoil you with the next error you will get. At line 148 there is the function header of loop inside it’s own codeblock. You can’t put void loop() anywhere you want to, it has to come before the { bracket that starts the code-block containing it’s functions. Guess where you need to put void loop to make it work. :wink:

[EDIT]Also it is: void loop()

, not: void loop(void)

Reference: http://arduino.cc/en/Tutorial/BareMinimum

http://arduino.cc/en/Reference/Braces#.UyRWaz5quvQ

How about we look at the code Adafruit published for a tutorial.

#include <Wire.h>
#include <Adafruit_ADS1015.h>

Adafruit_ADS1015 ads1015;

void setup(void)
{
  Serial.begin(9600);
  Serial.println("Hello!");
  
  Serial.println("Getting single-ended readings from AIN0..3");
  Serial.println("ADC Range: +/- 6.144V (1 bit = 3mV)");
  ads1015.begin();
}

void loop(void)
{
  int16_t adc0, adc1, adc2, adc3;

  adc0 = ads1015.readADC_SingleEnded(0);
  adc1 = ads1015.readADC_SingleEnded(1);
  adc2 = ads1015.readADC_SingleEnded(2);
  adc3 = ads1015.readADC_SingleEnded(3);
  Serial.print("AIN0: "); Serial.println(adc0);
  Serial.print("AIN1: "); Serial.println(adc1);
  Serial.print("AIN2: "); Serial.println(adc2);
  Serial.print("AIN3: "); Serial.println(adc3);
  Serial.println(" ");
  
  delay(1000);
}

Notice how simple it is because it “includes” the library code for the ADC rather than copying it into the sketch. Why don’t you start w/the above and add your LCD code to it ? Then we can add what’s needed to adjust the gain. But remember to install the ADC library (code Adafruit has already written for this ADC) into the Arduino’s file system as directed here. But use the manual installation instructions and be sure to change the subfolders name (after unzipping) from Adafruit_ADS1x15-master to Adafruit_ADS1015. Move that subfolder and it’s contents to where your added libraries are.

http://arduino.cc/en/Guide/Libraries#.UyRgrIUVBrA

The library code is here.

https://github.com/adafruit/Adafruit_ADS1X15

There’s a “download zip” button at the lower right part of the page.

Then startup the Arduino IDE, copy and paste the tutorial code into the new empty code window and see that it “verifies” for you as it just did for me.

 #if ARDUINO >= 100
 #include "Arduino.h"
 #else
 #include "WProgram.h"
 #endif

Why is the above in your program ? It’s not in the tutorial code. Do you need it ? KISS.

/*    I2C ADDRESS/BITS    */
#define ADS1015_ADDRESS (0x48) // 1001 000 (ADDR = GND)

/*       CONVERSION DELAY (in mS)       */
#define ADS1015_CONVERSIONDELAY (1)

/*       POINTER REGISTER               */
#define ADS1015_REG_POINTER_MASK (0x03)
#define ADS1015_REG_POINTER_CONVERT (0x00)
#define ADS1015_REG_POINTER_CONFIG (0x01)
#define ADS1015_REG_POINTER_LOWTHRESH (0x02)
#define ADS1015_REG_POINTER_HITHRESH (0x03)

/*       CONFIG REGISTER                  */
#define ADS1015_REG_CONFIG_OS_MASK (0x8000)
#define ADS1015_REG_CONFIG_OS_SINGLE (0x8000) // Write: Set to start a single-conversion
#define ADS1015_REG_CONFIG_OS_BUSY (0x0000) // Read: Bit = 0 when conversion is in progress
#define ADS1015_REG_CONFIG_OS_NOTBUSY (0x8000) // Read: Bit = 1 when device is not performing a conversion

#define ADS1015_REG_CONFIG_MUX_MASK (0x7000)

#define ADS1015_REG_CONFIG_MUX_SINGLE_0 (0x4000) // Single-ended AIN0
#define ADS1015_REG_CONFIG_MUX_SINGLE_1 (0x5000) // Single-ended AIN1
#define ADS1015_REG_CONFIG_MUX_SINGLE_2 (0x6000) // Single-ended AIN2
#define ADS1015_REG_CONFIG_MUX_SINGLE_3 (0x7000) // Single-ended AIN3

#define ADS1015_REG_CONFIG_PGA_MASK (0x0E00)
#define ADS1015_REG_CONFIG_PGA_6_144V (0x0000) // +/-6.144V range = Gain 2/3
#define ADS1015_REG_CONFIG_PGA_4_096V (0x0200) // +/-4.096V range = Gain 1
#define ADS1015_REG_CONFIG_PGA_2_048V (0x0400) // +/-2.048V range = Gain 2 (default)
#define ADS1015_REG_CONFIG_PGA_1_024V (0x0600) // +/-1.024V range = Gain 4
#define ADS1015_REG_CONFIG_PGA_0_512V (0x0800) // +/-0.512V range = Gain 8
#define ADS1015_REG_CONFIG_PGA_0_256V (0x0A00) // +/-0.256V range = Gain 16

#define ADS1015_REG_CONFIG_MODE_MASK (0x0100)
#define ADS1015_REG_CONFIG_MODE_CONTIN (0x0000) // Continuous conversion mode
#define ADS1015_REG_CONFIG_MODE_SINGLE (0x0100) // Power-down single-shot mode (default)

#define ADS1015_REG_CONFIG_DR_MASK (0x00E0)
#define ADS1015_REG_CONFIG_DR_128SPS (0x0000) // 128 samples per second
#define ADS1015_REG_CONFIG_DR_250SPS (0x0020) // 250 samples per second
#define ADS1015_REG_CONFIG_DR_490SPS (0x0040) // 490 samples per second
#define ADS1015_REG_CONFIG_DR_920SPS (0x0060) // 920 samples per second
#define ADS1015_REG_CONFIG_DR_1600SPS (0x0080) // 1600 samples per second (default)
#define ADS1015_REG_CONFIG_DR_2400SPS (0x00A0) // 2400 samples per second
#define ADS1015_REG_CONFIG_DR_3300SPS (0x00C0) // 3300 samples per second

#define ADS1015_REG_CONFIG_CMODE_MASK (0x0010)
#define ADS1015_REG_CONFIG_CMODE_TRAD (0x0000) // Traditional comparator with hysteresis (default)
#define ADS1015_REG_CONFIG_CMODE_WINDOW (0x0010) // Window comparator

#define ADS1015_REG_CONFIG_CPOL_MASK (0x0008)
#define ADS1015_REG_CONFIG_CPOL_ACTVLOW (0x0000) // ALERT/RDY pin is low when active (default)
#define ADS1015_REG_CONFIG_CPOL_ACTVHI (0x0008) // ALERT/RDY pin is high when active

#define ADS1015_REG_CONFIG_CLAT_MASK (0x0004) // Determines if ALERT/RDY pin latches once asserted
#define ADS1015_REG_CONFIG_CLAT_NONLAT (0x0000) // Non-latching comparator (default)
#define ADS1015_REG_CONFIG_CLAT_LATCH (0x0004) // Latching comparator

#define ADS1015_REG_CONFIG_CQUE_MASK (0x0003)
#define ADS1015_REG_CONFIG_CQUE_1CONV (0x0000) // Assert ALERT/RDY after one conversions
#define ADS1015_REG_CONFIG_CQUE_2CONV (0x0001) // Assert ALERT/RDY after two conversions
#define ADS1015_REG_CONFIG_CQUE_4CONV (0x0002) // Assert ALERT/RDY after four conversions
#define ADS1015_REG_CONFIG_CQUE_NONE (0x0003) // Disable the comparator and put ALERT/RDY in high state (default)

Same comments as above. Admittedly you may need a few of the defines to set the gain per a later tutorial.

#include <LiquidCrystal.h>

Didn’t I already see this at the top of your sketch, where it belongs ? Yes I did, once is enough.

typedef enum
{
  GAIN_TWOTHIRDS = ADS1015_REG_CONFIG_PGA_6_144V,
  GAIN_ONE = ADS1015_REG_CONFIG_PGA_4_096V,
  GAIN_TWO = ADS1015_REG_CONFIG_PGA_2_048V,
  GAIN_FOUR = ADS1015_REG_CONFIG_PGA_1_024V,
  GAIN_EIGHT = ADS1015_REG_CONFIG_PGA_0_512V,
  GAIN_SIXTEEN = ADS1015_REG_CONFIG_PGA_0_256V
}
adsGain_t;

class Adafruit_ADS1015
{
protected:
  // Instance-specific properties
  uint8_t m_i2cAddress;
  uint8_t m_conversionDelay;
  uint8_t m_bitShift;
  adsGain_t m_gain;

public:
  Adafruit_ADS1015(uint8_t i2cAddress = ADS1015_ADDRESS);
  void begin(void);
  uint16_t readADC_SingleEnded(uint8_t channel);
  int16_t readADC_Differential_0_1(void);
  int16_t readADC_Differential_2_3(void);
  void startComparator_SingleEnded(uint8_t channel, int16_t threshold);
  int16_t getLastConversionResults();
  void setGain(adsGain_t gain);
  adsGain_t getGain(void);

private:
};

// Derive from ADS1105 & override construction to set properties
class Adafruit_ADS1115 :
public Adafruit_ADS1015
{   
};

What’s all this ? It’s not in the tutorial code because by telling the compiler to “include” the ADC library you don’t have/want to copy it’s code into yours. Again KISS.

void setup(void)
{
  Serial.begin(9600);

  ads1015.begin();
}

Your setup() function is missing at least one thing that I found in your loop() function.

lcd.begin (16, 2);
{
  int16_t adc0, adc1, adc2, adc3;

  adc0 = ads1015.readADC_SingleEnded(0);
  adc1 = ads1015.readADC_SingleEnded(1);
  adc2 = ads1015.readADC_SingleEnded(2);
  adc3 = ads1015.readADC_SingleEnded(3);
  Serial.print("AIN0: ");
  Serial.println(adc0);
  Serial.print("AIN1: ");
  Serial.println(adc1);
  Serial.print("AIN2: ");
  Serial.println(adc2);
  Serial.print("AIN3: ");
  Serial.println(adc3);
  Serial.println(" ");
  delay(1000);

The above block looks familiar but it’s lost, neither in setup() nor in loop() and has either an extra { or a missing }. Again I would urge you to read the links I posted re: the fundamental pieces of a sketch.

    int chgaReading = analogRead(adc0);
      float chgaVolts = chgaReading * 1.0 / 27.0 ;

      lcd.setCursor(0, 0);
      lcd.print ("+     A");
      lcd.setCursor (1, 0);
      lcd.print(chgaVolts);

      int bavoltReading = analogRead(adc2);
      float bavoltVolts = bavoltReading * 1.0 / 56.0 ;

      lcd.setCursor (9, 0);
      lcd.print ("      V");
      lcd.setCursor (10, 0);
      lcd.print (bavoltVolts);
    }

And so we get to “your code”, which looks almost fine at 1’st glance. So what’s needed is to intelligently meld this w/the tutorial code. You’re using only 2 channels, the tutorial shows 4 being read. And on that note … what’s this do ?

int chgaReading = analogRead(adc0);
```Isn't the analogRead() function telling the Arduino to use it's internal ADC to read pin "adc0" (whatever pin that may be) ? Didn't you want to use the external ADC ? How did that external ADC read happen in the tutorial ?

adc0 = ads1015.readADC_SingleEnded(0);

What's stored in the variable adc0 ?

If you had an understanding of how to use the LiquidCrystal library then note the similarities btw these groups of statements.

#include <LiquidCrystal.h>

LiquidCrystal lcd(12, 11, 5, 4, 3, 2);

lcd.begin(16, 2);

lcd.print("+     A");
lcd.setCursor(2, 0);
lcd.print(chgaC);

===============================================

#include <Adafruit_ADS1015.h>

Adafruit_ADS1015 ads1015;

ads1015.begin();

adc0 = ads1015.readADC_SingleEnded(0);
adc1 = ads1015.readADC_SingleEnded(1);
adc2 = ads1015.readADC_SingleEnded(2);
adc3 = ads1015.readADC_SingleEnded(3);

If you’re still lost and have really given it a try, here’s something close to the final answer. I say close as I don’t know what you have for an external voltage divider for each voltage, and thus don’t know what to use for the ADC gain. I could guess from the comments but I’ve got to leave something for you to do. :mrgreen:

#include <Wire.h>
#include <Adafruit_ADS1015.h>
#include <LiquidCrystal.h>

Adafruit_ADS1015 ads1015;
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);

void setup(void)
{
  Serial.begin(9600);
  lcd.begin(16, 2);
  Serial.println("Hello!");
  Serial.println("ADC Range: +/- 6.144V (1 bit = 3mV)");
  ads1015.begin();
}

void loop(void)
{
  int chgaReading = ads1015.readADC_SingleEnded(0);
  float chgaVolts = chgaReading * 1.0 / 27.0 ;

  lcd.setCursor(0, 0);
  lcd.print ("+     A");
  lcd.setCursor (1, 0);
  lcd.print(chgaVolts);

  int bavoltReading = ads1015.readADC_SingleEnded(2);
  float bavoltVolts = bavoltReading * 1.0 / 56.0 ;

  lcd.setCursor (9, 0);
  lcd.print ("      V");
  lcd.setCursor (10, 0);
  lcd.print (bavoltVolts);

  delay(1000);
}

I forsee one problem with the way you’ve got the display written (I copied your code). Think about what might happen if you send 48.125 to the LCD followed by 47.8 in the next loop for the same voltage display. What will show up on the LCD ?

Yes, I am still lost.

I started from scratch and copied the (simplified) Adafruit sketch, wiped away the “Hello” stuff and added the basic minimum of my LCD stuff just to get this thing to fly. And yes, I have all 3 “.h” libraries.

#include <Wire.h>
#include <Adafruit_ADS1015.h>
#include <LiquidCrystal.h>

Adafruit_ADS1015 ads1015;
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);

void setup(void)
{
  Serial.begin(9600);
  lcd.begin(16, 2);
  
  Serial.println("ADC Range: +/- 6.144V (1 bit = 3mV)");
  ads1015.begin();
}

void loop(void)
{
  int chgaReading = ads1015.readADC_SingleEnded(0);
  float chgaVolts = chgaReading * 1.0 / 27.0 ;

  lcd.setCursor(0, 0);
  lcd.print ("+     A");
  lcd.setCursor (1, 0);
  lcd.print(chgaVolts);

  int bavoltReading = ads1015.readADC_SingleEnded(2);
  float bavoltVolts = bavoltReading * 1.0 / 56.0 ;

  lcd.setCursor (9, 0);
  lcd.print ("      V");
  lcd.setCursor (10, 0);
  lcd.print (bavoltVolts);

  delay(1000);
}

Now on my IDE I get error : ‘class Adafruit_ADS1015’ has no member named ‘begin’ with “ads1015.begin();” highlighted, copied directly from Adafruit, followed by a few more errors. (I see that they also use “ads.begin()” which gives the same error!)

I am not concerned about voltages for now : all I want is to see the UNO, ADS and LCD running, together. Only then will I worry about details I’m familiar with - I’ve been in analog industrial electronics long enough. It’s the micro’s, sketches and C++'s that I can’t quite get through my fingers…

If the code I posted just above doesn’t compile then you’re missing a library. Post a screenshot of your installed ADC library.

See if your Arduino IDE lists the installed ADC library as shown below.

(click on to open)

Yup!

You were right. My library (correctly) uploads the “h” file and shows :

#include <Adafruit_ADS1015.h>

as one would expect to be correct but doesn’t include the .cpp, etc, which is clearly the Humpty-Dumpty.

On re-reading the arduino/libraries/download/whatever I see that the full shopping basket is necessary and not just the ads1015.h on its own.

Silly of me, yes, but perhaps not clear enough in the soup for us newbies/dummies.

Also had a spot of trauma as the total file could not be saved to Library directly as per Arduino’s download library-thing - the red block gave me a long story saying that the file name should not contain numbers, fleas and windscreenwipers. I needed to do the alternative and create a file (which I named Adafruit_ads1015) , move all the necessary files in and THEN pitched it into the cauldron as instructed before it worked.

What’s interesting is that my (new) (correct) library file is now at bottom of the list (Sketch / Import Library) in the “Contributed” section and will not upload to a sketch automatically or list in the usual list of libraries - it keeps sucking up the ADS1015 number WITHOUT the shopping basket.

Is this perhaps because I have the existing (naughty) library called “ADS1015” in the main section/list of libraries and that there’s conflict?

PS. Don’t find any way to edit a previous entries/replies in the forum. Is this normal? Or is there a way one can change a previous entry which I don’t know about? minor issue…

Newbie10:

PS. Don’t find any way to edit a previous entries/replies in the forum. Is this normal? Or is there a way one can change a previous entry which I don’t know about? minor issue…

Odd, can’t see an edit button either on my posts. Some Sparkfunner must have consumed too much on St. Patrick’s Day.

[edit]But on this one I do. Very odd.