Hi Chris,
Thank you very much for staying with me on this. It is greatly appreciated. Looking at the
"Library in the wrong location" first.
While yes, it could be, but this is the results of this line of inquiry here.
1. I have three library locations (don't know why?), they are:
a)
/home/mprowe/Arduino/libraries/ b)
/home/mprowe/.arduino15/packages/arduino/hardware/avr/1.6.18/libraries/ c)
/opt/arduino-1.8.0/libraries/2.
For testing purposes only, I have put your library in all three locations - with a customized library.properties file.
3. The log output (below) shows that it has found all three & is using the copy at (2.b) see lines 86 to 89. This is alongside the wire library.
74 Linking everything together...
75 "/home/mprowe/.arduino15/packages/arduino/tools/avr-gcc/4.9.2-atmel3.5.4-arduino2/bin/avr-gcc" [.... truncated by me]
76 /tmp/ccVbwl16.ltrans0.ltrans.o: In function `__static_initialization_and_destruction_0':
77 /home/mprowe/Arduino/nhd-i2c/oled-example/oled-example.ino:16: undefined reference to `OLedI2C::OLedI2C()'
78 /tmp/ccVbwl16.ltrans0.ltrans.o: In function `setup':
79 /home/mprowe/Arduino/nhd-i2c/oled-example/oled-example.ino:24: undefined reference to `OLedI2C::init(unsigned char)'
80 /tmp/ccVbwl16.ltrans0.ltrans.o: In function `loop':
81 /home/mprowe/Arduino/nhd-i2c/oled-example/oled-example.ino:29: undefined reference to `OLedI2C::sendString(char const*, unsigned char, unsigned char)'
82 /home/mprowe/Arduino/nhd-i2c/oled-example/oled-example.ino:30: undefined reference to `OLedI2C::sendFloat(float, unsigned char, unsigned char, unsigned char, unsigned char)'
83 /tmp/ccVbwl16.ltrans0.ltrans.o: In function `_GLOBAL__sub_D_LCD':
84 /home/mprowe/Arduino/nhd-i2c/oled-example/oled-example.ino:16: undefined reference to `OLedI2C::~OLedI2C()'
85 collect2: error: ld returned 1 exit status
86 Multiple libraries were found for "OLedI2C.h"
87 Used: /home/mprowe/.arduino15/packages/arduino/hardware/avr/1.6.18/libraries/OLedI2C
88 Not used: /home/mprowe/Arduino/libraries/OLedI2C.home
89 Not used: /opt/arduino-1.8.0/libraries/OLedI2C.opt
90 Using library Wire at version 1.0 in folder: /home/mprowe/.arduino15/packages/arduino/hardware/avr/1.6.18/libraries/Wire
91 Using library OLedI2C at version 1.0 in folder: /home/mprowe/.arduino15/packages/arduino/hardware/avr/1.6.18/libraries/OLedI2C
92 exit status 1
93 Error compiling for board Arduino/Genuino Uno.
4. Compiling with only one copy of the OLedI2C in each location. First run with OLedI2C in 2.a), second run with OLedI2C in 2.b) and finaly with OLedI2C in location 2.c) still results in a compilation error?
5. I have placed a full copy of the compilation log
ftp://mpr75@talktalk.net@www.mpr75.talktalk.net/oled-example.log. This is what I meant in the last over, about sharing the full log file. In many forums you can upload and link these files but I can not find any way to do the same on this site? If you can find the time to have a look at the whole whole log file in the hope that any other clues should "jump out"?
Best regards, Martin