LedControl icon indicating copy to clipboard operation
LedControl copied to clipboard

Doesnt work with esp8266 based boards

Open richms opened this issue 9 years ago • 7 comments

In file included from C:\Users\richard\Documents\Arduino\libraries\LedControl\src\LedControl.cpp:28:0: C:\Users\richard\Documents\Arduino\libraries\LedControl\src\LedControl.h:30:26: fatal error: avr/pgmspace.h: No such file or directory #include <avr/pgmspace.h> ^ compilation terminated. Error compiling.

richms avatar Jan 01 '16 06:01 richms

remove this line from LedControl.h, then it works great (obviously its not an AVR chip):

#include <avr/pgmspace.h>

https://github.com/wayoda/LedControl/blob/master/src/LedControl.h#L30

sej7278 avatar Jan 08 '16 21:01 sej7278

To save everyone looking this up, would it possible for this very useful library to have the following context diff applied? Thanks.

LedControl_context_diff.txt

pcvm avatar Feb 12 '16 06:02 pcvm

actually this is the proper fix, as it still lets pgmspace work with the esp8266 for 7-segment displays (its not needed for led matrices):

https://github.com/sej7278/LedControl/commit/d82d522791b805ebaebe926c45ca18a1ba35a3cc

sej7278 avatar Feb 12 '16 09:02 sej7278

Using this for a 7-segment display this worked fine. Thanks!

MStylesMS avatar Jul 30 '16 17:07 MStylesMS

I second this! @sej7278 fix worked great!

1n5aN1aC avatar Nov 15 '16 02:11 1n5aN1aC

#if (defined(AVR)) #include <avr\pgmspace.h> #else #include <pgmspace.h> #endif

ianbren avatar Mar 29 '17 20:03 ianbren

@wayoda don't You have time to repair this ? :( This is great https://github.com/wayoda/LedControl/issues/10#issuecomment-290219444

apacholik avatar Feb 16 '18 19:02 apacholik