Problem compiling example 8x8 LED matrix backpack sketch

Post here about your Arduino projects, get help - for Adafruit customers!

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Dr_ukendermen
 
Posts: 3
Joined: Sun Nov 03, 2013 4:22 pm

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by Dr_ukendermen »

Now, before I get started I want to tell you that I am not the best a at programming.
I tried to upload *matrix8x8* to am arduino Uno ,but got hit by a brick wall which seems impenetrable.
I installed the Adafruit_gfx and Adafruit_Ledbackpack libraries but when I tried to open the matrix8x8 sketch and verified it it threw many errors at me! (16!)
I read through the previous comments but to no to a vale did I fix the problem.
I tried the libraries at this post ,but the same bug occurred.
Here is the console log.


matrix8x8.ino:23:34: error: Adafruit_LEDBackpack.h: No such file or directory
matrix8x8:26: error: 'Adafruit_8x8matrix' does not name a type
matrix8x8.ino: In function 'void setup()':
matrix8x8:32: error: 'matrix' was not declared in this scope
matrix8x8.ino: In function 'void loop()':
matrix8x8:65: error: 'matrix' was not declared in this scope
matrix8x8:66: error: 'LED_ON' was not declared in this scope

Please help me, I need to do this for school.
---Dr_ukendermen :D

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by adafruit_support_rick »

You don't have the libraries installed correctly. Please review our tutorial on installing libraries.
http://learn.adafruit.com/adafruit-all- ... nstall-use

Also note that you have to restart the IDE after installing a library. Otherwise, the IDE will not recognize it.

Dr_ukendermen
 
Posts: 3
Joined: Sun Nov 03, 2013 4:22 pm

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by Dr_ukendermen »

adafruit_support_rick wrote:You don't have the libraries installed correctly. Please review our tutorial on installing libraries.
http://learn.adafruit.com/adafruit-all- ... nstall-use

Also note that you have to restart the IDE after installing a library. Otherwise, the IDE will not recognize it.
I did follow the tutorial ,and Restarted the IDE. I followed the tutorail straight on ,but now it's even worse.
Here is the console log:

In file included from matrix8x8.ino:23:
C:\Users\Admin\Documents\Arduino\libraries\Adafruit_LEDBackpack/Adafruit_LEDBackpack.h:32:26: error: Adafruit_GFX.h: No such file or directory
In file included from matrix8x8.ino:23:
C:\Users\Admin\Documents\Arduino\libraries\Adafruit_LEDBackpack/Adafruit_LEDBackpack.h:72: error: expected class-name before '{' token
C:\Users\Admin\Documents\Arduino\libraries\Adafruit_LEDBackpack/Adafruit_LEDBackpack.h:81: error: expected class-name before '{' token
matrix8x8.ino: In function 'void loop()':
matrix8x8:66: error: 'class Adafruit_8x8matrix' has no member named 'drawBitmap'
matrix8x8:71: error: 'class Adafruit_8x8matrix' has no member named 'drawBitmap'
matrix8x8:76: error: 'class Adafruit_8x8matrix' has no member named 'drawBitmap'
matrix8x8:86: error: 'class Adafruit_8x8matrix' has no member named 'drawLine'
matrix8x8:91: error: 'class Adafruit_8x8matrix' has no member named 'drawRect'
matrix8x8:92: error: 'class Adafruit_8x8matrix' has no member named 'fillRect'
matrix8x8:97: error: 'class Adafruit_8x8matrix' has no member named 'drawCircle'
matrix8x8:101: error: 'class Adafruit_8x8matrix' has no member named 'setTextSize'
matrix8x8:102: error: 'class Adafruit_8x8matrix' has no member named 'setTextWrap'
matrix8x8:103: error: 'class Adafruit_8x8matrix' has no member named 'setTextColor'
matrix8x8:106: error: 'class Adafruit_8x8matrix' has no member named 'setCursor'
matrix8x8:107: error: 'class Adafruit_8x8matrix' has no member named 'print'
matrix8x8:111: error: 'class Adafruit_8x8matrix' has no member named 'setRotation'
matrix8x8:114: error: 'class Adafruit_8x8matrix' has no member named 'setCursor'
matrix8x8:115: error: 'class Adafruit_8x8matrix' has no member named 'print'

User avatar
pburgess
 
Posts: 4161
Joined: Sun Oct 26, 2008 2:29 am

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by pburgess »

Looks like you have the matrix library properly installed, but not the GFX library yet. Make sure you follow the same installation process (confirming folder names & locations, etc.) for the latter library.

Dr_ukendermen
 
Posts: 3
Joined: Sun Nov 03, 2013 4:22 pm

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by Dr_ukendermen »

Thanks Guys! It's working great!

Pfiff
 
Posts: 3
Joined: Mon Feb 10, 2014 11:19 am

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by Pfiff »

Same problem, differned user...

Hi there, I've installed GFX and LEDBackpack for my Adafruit Bi-Color 8x8 Matrix librarys like:

Code: Select all

pfiff@Computersname:~/Arbeitsfläche/arduino-1.0.5/libraries$ git clone https://github.com/adafruit/Adafruit-LED-Backpack-Library
Cloning into 'Adafruit-LED-Backpack-Library'...
remote: Reusing existing pack: 110, done.
remote: Total 110 (delta 0), reused 0 (delta 0)
Receiving objects: 100% (110/110), 68.74 KiB, done.
Resolving deltas: 100% (42/42), done.
pfiff@Computersname:~/Arbeitsfläche/arduino-1.0.5/libraries$ git clone https://github.com/adafruit/Adafruit-GFX-Library
Cloning into 'Adafruit-GFX-Library'...
remote: Reusing existing pack: 78, done.
remote: Total 78 (delta 0), reused 0 (delta 0)
Unpacking objects: 100% (78/78), done.
pfiff@Computersname:~/Arbeitsfläche/arduino-1.0.5/libraries$ mv ./Adafruit-GFX-Library/ ./Adafruit_GFX
pfiff@Computersname:~/Arbeitsfläche/arduino-1.0.5/libraries$ mv ./Adafruit-LED-Backpack-Library/ ./Adafruit_LEDBackpack
pfiff@Computersname:~/Arbeitsfläche/arduino-1.0.5/libraries$ 
now ir run Arduino 1.0.5 sketch with sudo privilegs.

when I load the Adafuit 8x8 Bi Color example and start compiling it, I get the following errors:
/home/pfiff/Arbeitsfläche/arduino-1.0.5/libraries/Adafruit_LEDBackpack/Adafruit_LEDBackpack.cpp: In constructor ‘Adafruit_8x8matrix::Adafruit_8x8matrix()’:
/home/pfiff/Arbeitsfläche/arduino-1.0.5/libraries/Adafruit_LEDBackpack/Adafruit_LEDBackpack.cpp:97: error: no matching function for call to ‘Adafruit_GFX::Adafruit_GFX(int, int)’
/home/pfiff/Arbeitsfläche/arduino-1.0.5/libraries/Robot_Control/Adafruit_GFX.h:41: note: candidates are: Adafruit_GFX::Adafruit_GFX(const Adafruit_GFX&)
/home/pfiff/Arbeitsfläche/arduino-1.0.5/libraries/Robot_Control/Adafruit_GFX.h:41: note: Adafruit_GFX::Adafruit_GFX()
/home/pfiff/Arbeitsfläche/arduino-1.0.5/libraries/Adafruit_LEDBackpack/Adafruit_LEDBackpack.cpp: In constructor ‘Adafruit_BicolorMatrix::Adafruit_BicolorMatrix()’:
/home/pfiff/Arbeitsfläche/arduino-1.0.5/libraries/Adafruit_LEDBackpack/Adafruit_LEDBackpack.cpp:133: error: no matching function for call to ‘Adafruit_GFX::Adafruit_GFX(int, int)’
/home/pfiff/Arbeitsfläche/arduino-1.0.5/libraries/Robot_Control/Adafruit_GFX.h:41: note: candidates are: Adafruit_GFX::Adafruit_GFX(const Adafruit_GFX&)
/home/pfiff/Arbeitsfläche/arduino-1.0.5/libraries/Robot_Control/Adafruit_GFX.h:41: note: Adafruit_GFX::Adafruit_GFX()
I've also downloaded the librarys as ZIP file an installed it manualy, some problem. And I have done it for more than one time.

Whats wrong?

Best Regards
Pfiff

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by adafruit_support_rick »

You have to rename the library folders to replace the '-' characters with '_'. For instance "Adafruit_GFX" and "Adafruit_LED_Backpack"

Pfiff
 
Posts: 3
Joined: Mon Feb 10, 2014 11:19 am

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by Pfiff »

adafruit_support_rick wrote:You have to rename the library folders to replace the '-' characters with '_'. For instance "Adafruit_GFX" and "Adafruit_LED_Backpack"
Have I already done...

I tried it with "Adafruit_LED_Backpack" and "Adafruit_LEDBackpack"
same problem...

my library folder looks like:

Code: Select all

pfiff@Computersname:~/Arbeitsfläche/arduino-1.0.5/libraries$ ls
Adafruit_GFX           Adafruit_PWM_ServoDriver  Ethernet     LiquidCrystal  Servo           TFT
Adafruit_LED_Backpack  AFMotorShield             Firmata      Robot_Control  SoftwareSerial  WiFi
Adafruit_MPL115A2      EEPROM                    GSM          Robot_Motor    SPI             Wire
Adafruit_NeoPixel      Esplora                   keypad_1602  SD             Stepper

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by adafruit_support_rick »

Ah, you have installed your libraries in the wrong location. You have installed them in the system libraries folder. That is not correct.
You must create a new folder, called "libraries", in your sketchbook folder.
You can find the path to your sketchbook folder by opening the "Preferences" dialog in the Arduino IDE.
Please see this page for details:
http://learn.adafruit.com/adafruit-all- ... -a-library

Pfiff
 
Posts: 3
Joined: Mon Feb 10, 2014 11:19 am

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by Pfiff »

adafruit_support_rick wrote:Ah, you have installed your libraries in the wrong location. You have installed them in the system libraries folder. That is not correct.
You must create a new folder, called "libraries", in your sketchbook folder.
You can find the path to your sketchbook folder by opening the "Preferences" dialog in the Arduino IDE.
Please see this page for details:
http://learn.adafruit.com/adafruit-all- ... -a-library

Thank you, this solved my problem...

Schauls276
 
Posts: 3
Joined: Thu Apr 24, 2014 6:43 pm

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by Schauls276 »

I am a novice programmer. i started to attempt this example today and i continue to get the error: C:\Program Files (x86)\Arduino\libraries\Adafruit_LEDBackpack\Adafruit_LEDBackpack.cpp: In constructor 'Adafruit_8x8matrix::Adafruit_8x8matrix()':
C:\Program Files (x86)\Arduino\libraries\Adafruit_LEDBackpack\Adafruit_LEDBackpack.cpp:130: error: no matching function for call to 'Adafruit_GFX::Adafruit_GFX(int, int)'
C:\Program Files (x86)\Arduino\libraries\Robot_Control/Adafruit_GFX.h:41: note: candidates are: Adafruit_GFX::Adafruit_GFX(const Adafruit_GFX&)
C:\Program Files (x86)\Arduino\libraries\Robot_Control/Adafruit_GFX.h:41: note: Adafruit_GFX::Adafruit_GFX()
C:\Program Files (x86)\Arduino\libraries\Adafruit_LEDBackpack\Adafruit_LEDBackpack.cpp: In constructor 'Adafruit_BicolorMatrix::Adafruit_BicolorMatrix()':
C:\Program Files (x86)\Arduino\libraries\Adafruit_LEDBackpack\Adafruit_LEDBackpack.cpp:167: error: no matching function for call to 'Adafruit_GFX::Adafruit_GFX(int, int)'
C:\Program Files (x86)\Arduino\libraries\Robot_Control/Adafruit_GFX.h:41: note: candidates are: Adafruit_GFX::Adafruit_GFX(const Adafruit_GFX&)
C:\Program Files (x86)\Arduino\libraries\Robot_Control/Adafruit_GFX.h:41: note: Adafruit_GFX::Adafruit_GFX()


I have downloaded the Adafruit_GFX library many times in an attempt to solve this, i put it where it says to, and rename it how it should be named. nothing seems to work! someone please help me...

User avatar
adafruit_support_mike
 
Posts: 67446
Joined: Thu Feb 11, 2010 2:51 pm

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by adafruit_support_mike »

That problem isn't your fault. It's a mistake in the Arduino IDE.

Version 1.0.5 of the IDE added support for the Arduino Robot kit, and the code used to control it includes an older version of the Adafruit_GFX library. Even though you've named the library correctly and put it in the correct place, the compiler is ignoring it because the old version lives in its "look here first" path.

The easiest way to solve the problem is to use version 1.0.4 of the IDE. It works perfectly well, and doesn't contain the inconveniently-placed library.

You can also solve the problem in 1.0.5 by going into the IDE's internal library path and deleting the folder named 'RobotControl'.

Schauls276
 
Posts: 3
Joined: Thu Apr 24, 2014 6:43 pm

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by Schauls276 »

How can i revert back to the 1.0.4 IDE? i deleted the file names " robot_control" and attempted to verify and compile, and still got an error message... a different one though.. i just dont think im very inclined on this Arduino stuff...
In file included from bicolor8x8.pde:23:
C:\Program Files (x86)\Arduino\libraries\Adafruit_LEDBackpack/Adafruit_LEDBackpack.h:32:26: error: Adafruit_GFX.h: No such file or directory
In file included from bicolor8x8.pde:23:
C:\Program Files (x86)\Arduino\libraries\Adafruit_LEDBackpack/Adafruit_LEDBackpack.h:82: error: expected class-name before '{' token
C:\Program Files (x86)\Arduino\libraries\Adafruit_LEDBackpack/Adafruit_LEDBackpack.h:91: error: expected class-name before '{' token
bicolor8x8.pde: In function 'void loop()':
bicolor8x8:67: error: 'class Adafruit_BicolorMatrix' has no member named 'drawBitmap'
bicolor8x8:72: error: 'class Adafruit_BicolorMatrix' has no member named 'drawBitmap'
bicolor8x8:77: error: 'class Adafruit_BicolorMatrix' has no member named 'drawBitmap'
bicolor8x8:87: error: 'class Adafruit_BicolorMatrix' has no member named 'drawLine'
bicolor8x8:92: error: 'class Adafruit_BicolorMatrix' has no member named 'drawRect'
bicolor8x8:93: error: 'class Adafruit_BicolorMatrix' has no member named 'fillRect'
bicolor8x8:98: error: 'class Adafruit_BicolorMatrix' has no member named 'drawCircle'
bicolor8x8:102: error: 'class Adafruit_BicolorMatrix' has no member named 'setTextWrap'
bicolor8x8:103: error: 'class Adafruit_BicolorMatrix' has no member named 'setTextSize'
bicolor8x8:104: error: 'class Adafruit_BicolorMatrix' has no member named 'setTextColor'
bicolor8x8:107: error: 'class Adafruit_BicolorMatrix' has no member named 'setCursor'
bicolor8x8:108: error: 'class Adafruit_BicolorMatrix' has no member named 'print'
bicolor8x8:112: error: 'class Adafruit_BicolorMatrix' has no member named 'setRotation'
bicolor8x8:113: error: 'class Adafruit_BicolorMatrix' has no member named 'setTextColor'
bicolor8x8:116: error: 'class Adafruit_BicolorMatrix' has no member named 'setCursor'
bicolor8x8:117: error: 'class Adafruit_BicolorMatrix' has no member named 'print'
bicolor8x8:121: error: 'class Adafruit_BicolorMatrix' has no member named 'setRotation'

User avatar
adafruit_support_rick
 
Posts: 35092
Joined: Tue Mar 15, 2011 11:42 am

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by adafruit_support_rick »

You need to download and install the Adafruit_GFX library:
https://github.com/adafruit/Adafruit-GFX-Library

As noted earlier in this thread, do not intsall libraries in the Arduino libraries folder. Instead, you should have a folder called 'libraries' inside of your sketchbook folder. That is where user libraries belong.

Please see our tutorial on installing Arduino libraries:
https://learn.adafruit.com/adafruit-all ... nstall-use

MasterErik
 
Posts: 1
Joined: Fri May 02, 2014 11:07 am

Re: Problem compiling example 8x8 LED matrix backpack sketch

Post by MasterErik »

C:\Users\u\Documents\Arduino\libraries\Adafruit_LED\Adafruit_LEDBackpack.cpp: In constructor 'Adafruit_8x8matrix::Adafruit_8x8matrix()':
C:\Users\u\Documents\Arduino\libraries\Adafruit_LED\Adafruit_LEDBackpack.cpp:130: error: no matching function for call to 'Adafruit_GFX::Adafruit_GFX(int, int)'
C:\Program Files\Arduino\libraries\Robot_Control/Adafruit_GFX.h:41: note: candidates are: Adafruit_GFX::Adafruit_GFX(const Adafruit_GFX&)
C:\Program Files\Arduino\libraries\Robot_Control/Adafruit_GFX.h:41: note: Adafruit_GFX::Adafruit_GFX()
C:\Users\u\Documents\Arduino\libraries\Adafruit_LED\Adafruit_LEDBackpack.cpp: In constructor 'Adafruit_BicolorMatrix::Adafruit_BicolorMatrix()':
C:\Users\u\Documents\Arduino\libraries\Adafruit_LED\Adafruit_LEDBackpack.cpp:167: error: no matching function for call to 'Adafruit_GFX::Adafruit_GFX(int, int)'
C:\Program Files\Arduino\libraries\Robot_Control/Adafruit_GFX.h:41: note: candidates are: Adafruit_GFX::Adafruit_GFX(const Adafruit_GFX&)
C:\Program Files\Arduino\libraries\Robot_Control/Adafruit_GFX.h:41: note: Adafruit_GFX::Adafruit_GFX()

Any ideas why this is not working with my 8x8 bi color display?

Locked
Please be positive and constructive with your questions and comments.

Return to “Arduino”