Embedded Adventures PLT1001 LED Matrix driver - compiler errors

Hello,

I'm having problems compiling code for an Embedded Adventures PLT1001 LED driver board.

I'm using their example code for driving an Embedded Adventrues LDP8008 LED matrix through the PLT1001. The library was downloaded from their GitHub depository, here.

As you can see, there are errors in compilation but despite trying various approaches to try to solve the issue, I'm getting nowhere.

I apologise for posting the whole compilation error text but I do so in the hope it will be of some use.

If anyone can help, I will be very grateful for your time.

Thank you,

M.

Compiler Dialog

Arduino: 1.6.11 (Windows 10), Board: "Arduino/Genuino Mega or Mega 2560, ATmega2560 (Mega 2560)"

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001_ldp8008_test\PLT1001_ldp8008_test.ino: In function 'void loop()':

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001_ldp8008_test\PLT1001_ldp8008_test.ino:56:25: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

demo_text("EA plt1001");

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001_ldp8008_test\PLT1001_ldp8008_test.ino:61:69: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

plt1001.scroll(3, 0, 7, 80, "This is a demonstration of scrolling");

^

In file included from C:\Users\Mark\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp:45:0:

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.h:43:18: warning: extra tokens at end of #ifndef directive

#ifndef __PLT1001-I2C_h

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.h:44:18: warning: ISO C99 requires whitespace after the macro name

#define __PLT1001-I2C_h

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp: In member function 'char* PLT1001v2Class::board()':

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp:83:11: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

return "LDP8008";

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp:86:11: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

return "LDP6416";

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp:89:11: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

return "LDP6432";

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp:92:11: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

return "LDP6408";

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp:95:11: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

return "LDP6432-RED";

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp:98:11: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

return "LDP3208-S";

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp:101:11: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

return "LDP3216-S";

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp:104:11: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

return "LDP080507-R";

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp: At global scope:

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp:482:97: error: no 'void PLT1001v2Class::scrollVertical(unsigned char, unsigned int, unsigned int, unsigned int, unsigned int, char*)' member function declared in class 'PLT1001v2Class'

void PLT1001v2Class::scrollVertical(uns8 color, uns16 x, uns16 y, uns16 wd, uns16 ht, char* text) {

^

C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp:503:95: error: no 'void PLT1001v2Class::scrollColumn(unsigned char, unsigned int, unsigned int, unsigned int, unsigned int, char*)' member function declared in class 'PLT1001v2Class'

void PLT1001v2Class::scrollColumn(uns8 color, uns16 x, uns16 y, uns16 wd, uns16 ht, char* text) {

^

exit status 1

Error compiling for board Arduino/Genuino Mega or Mega 2560.

The problem is that for some reason the Embedded Adventures commented out the function prototypes for scrollVertical() and scrollColumn()(see https://github.com/embeddedadventures/PLT1001/blob/master/PLT1001-I2C.h#L87-L88). Evidently Embedded Adventures doesn't even do the most minimal testing of their code(which has been posted online for 8 months), as well as providing no documentation, in fact they don't even know that you're supposed to put the example sketches included with Arduino libraries in an "examples" folder. Definitely not a sign of caring much for their customers. I'd recommend sending back any products of theirs you currently have for a refund and not supporting this company in the future.

You can fix the issue by opening C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.h with a text editor and changing lines 87 and 88 from:

//void scrollVertical(uns8 color, uns16 x, uns16 y, uns16 ht, uns16 wd, char* text);
 //void scrollColumn(uns8 color, uns16 x, uns16 y, uns16 ht, uns16 wd, char* text);

to:

void scrollVertical(uns8 color, uns16 x, uns16 y, uns16 ht, uns16 wd, char* text);
 void scrollColumn(uns8 color, uns16 x, uns16 y, uns16 ht, uns16 wd, char* text);

changing line 94 from:

extern PLT1001v2Class plt1001;

to:

extern PLT1001v2Class plt1001v2;

Then save the file.
Open C:\Users\Moi\Documents\Arduino\libraries\PLT1001-master\PLT1001-I2C.cpp with a text editor and changing lines 567 from:

PLT1001v2Class plt1001;

to:

PLT1001v2Class plt1001v2;

Then save the file.

I don't own the hardware so I can't actually test but it does compile after those changes. These issues, as well as a complete rookie mistake with their include guard doesn't give me much confidence that there are not more bugs in their code.

Many grateful thanks for your time and advice, Pert, it is much appreciated.

I managed to debug the code too, albeit eventually. Like you noted the comment syntax but your other suggestions to correct the errors I didn't see and again I am grateful to you for pointing them out. I also agree with you about the documentation or support from Embedded Adventures, in relation to this product - there is none!

I believe the 'backpack module' (PLT1001) I have for the LDP8008 is not working but nonetheless, I wanted to run the LDP-8008 directly from the Arduino itself to produce a very simple LED display message containing just a few words (and not even scrolling!).

Despite scouring the web and other forums for what feels like an eternity, I've been unable to find any working code that can run this LDP-8008 matrix directly from an Arduino, i.e. from a sketch.

In this respect I've completely given up on the matrix from Embedded Adventures and switched to a standard well supported system based on the MAX 7219's.

This is all a shame really as when the LDP-8008 is working (as I have managed running a python script on a Raspberry Pi) it works well. But like I say, documentation and support from Embedded Adventures is next to useless.

So much time wasted on this product, my project is now weeks behind schedule.

Live and learn.

Many thanks again,

M.