I am trying to run my 2.8"TFT Breakout board for the first time. The Graphics Test.PDE doesn't want to compile for me. It gives me the following messages:
GraphicsTest.cpp: In function 'void setup()':
GraphicsTest:55: error: 'PSTR' was not declared in this scope
GraphicsTest.cpp: In function 'void progmemPrint(const char*)':
GraphicsTest:452: error: 'pgm_read_byte' was not declared in this scope
PSTR and pgm_read_byte are functions in the pgmspace.h. It is called with #include <avr\pgmspace> in the Adafruit_GFX.cpp and Adafruit_TFTLCD.cpp.
I left the #define USE_ADAFRUIT_SHIELD_PINOUT commented out in the Adafruit_TFTLCD.h like I am suppose to for my breakout board.
No sure why it can't find pgmspace.h. Please help. Thanks.
Graphics Test
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- pburgess
- Posts: 4161
- Joined: Sun Oct 26, 2008 2:29 am
Re: Graphics Test
Is this with an Arduino Due?
- whitehorsehawk
- Posts: 6
- Joined: Thu Jul 11, 2013 12:49 am
Re: Graphics Test
No, ATMega168.
Board is correct. Com port is correct.
Board is correct. Com port is correct.
- whitehorsehawk
- Posts: 6
- Joined: Thu Jul 11, 2013 12:49 am
Re: Graphics Test
my path is .../arduino-0022/hardware/tools/avr/avr/include/avr/pgmspace.h
- whitehorsehawk
- Posts: 6
- Joined: Thu Jul 11, 2013 12:49 am
Re: Graphics Test
my path is .../arduino-0022/hardware/tools/avr/avr/include/avr/pgmspace.h
- pburgess
- Posts: 4161
- Joined: Sun Oct 26, 2008 2:29 am
Re: Graphics Test
Away from computer at the moment. A couple things to try in the interim...
- Try including avr/pgmspace in the test sketch itself. Even if the functions aren't used there. Seem to recall something with include paths in Arduino.
- Try newer release of Arduino IDE. 0022 is somewhat "vintage."
- Try including avr/pgmspace in the test sketch itself. Even if the functions aren't used there. Seem to recall something with include paths in Arduino.
- Try newer release of Arduino IDE. 0022 is somewhat "vintage."
-
- Posts: 9
- Joined: Mon Nov 04, 2013 10:03 am
Re: Graphics Test
I'm having a similar issue - but different. My compile errors are:
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp: In constructor 'RobotControl::RobotControl()':
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:8: error: 'LCD_CS' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:8: error: 'DC_LCD' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:8: error: 'RST_LCD' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp: In member function 'void RobotControl::begin()':
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:18: error: 'MUXA' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:18: error: 'MUXB' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:18: error: 'MUXC' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:18: error: 'MUXD' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:19: error: 'MUX_IN' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:22: error: 'BUZZ' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:25: error: 'Serial1' was not declared in this scope
I followed the Tutorial instructions.
I am using an Ardiuno Uno
The Ardiuno software is rev 1.0.5
Any ideas? I'm anxious to play with this display
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp: In constructor 'RobotControl::RobotControl()':
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:8: error: 'LCD_CS' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:8: error: 'DC_LCD' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:8: error: 'RST_LCD' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp: In member function 'void RobotControl::begin()':
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:18: error: 'MUXA' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:18: error: 'MUXB' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:18: error: 'MUXC' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:18: error: 'MUXD' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:19: error: 'MUX_IN' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:22: error: 'BUZZ' was not declared in this scope
C:\Program Files (x86)\Arduino\libraries\Robot_Control\ArduinoRobot.cpp:25: error: 'Serial1' was not declared in this scope
I followed the Tutorial instructions.
I am using an Ardiuno Uno
The Ardiuno software is rev 1.0.5
Any ideas? I'm anxious to play with this display
- pburgess
- Posts: 4161
- Joined: Sun Oct 26, 2008 2:29 am
Re: Graphics Test
Howdy,
This is a known glitch in the Arduino 1.0.5 IDE; it'll be fixed in a future release. In the meantime, a workaround is to download 1.0.4.
This is a known glitch in the Arduino 1.0.5 IDE; it'll be fixed in a future release. In the meantime, a workaround is to download 1.0.4.
-
- Posts: 9
- Joined: Mon Nov 04, 2013 10:03 am
Re: Graphics Test
Thanks that solved my issue!
-
- Posts: 1
- Joined: Thu Apr 17, 2014 11:37 pm
Re: Graphics Test
Hello,
Can I please know the procedure to connect TFT to Intel BANNED or any other Arduino board?? As long as I am trying, it is giving the error that some or the other library is missing. Currently it is showing the following error if I try to run a sample program.
tftpaint1.ino: In function 'void progmemPrint(const char*)':
tftpaint1.ino:179:32: error: 'pgm_read_byte' was not declared in this scope
Can I please know the procedure to connect TFT to Intel BANNED or any other Arduino board?? As long as I am trying, it is giving the error that some or the other library is missing. Currently it is showing the following error if I try to run a sample program.
tftpaint1.ino: In function 'void progmemPrint(const char*)':
tftpaint1.ino:179:32: error: 'pgm_read_byte' was not declared in this scope
- adafruit_support_mike
- Posts: 67454
- Joined: Thu Feb 11, 2010 2:51 pm
Re: Graphics Test
If you're using the 2.8" TFT breakout, the tutorial showing how to make it work is here: https://learn.adafruit.com/adafruit-2-d ... reakout-v2
Please be positive and constructive with your questions and comments.