CTE35 was not declared in this typel

#include <UTFT.h>

extern uint8_t SmallFont[];
extern uint8_t BigFont[];
extern uint8_t SevenSegNumFont[];

UTFT myGLCD(CTE35,38,39,40,41); // Remember to change the model parameter to suit your display module!

void setup()
{
myGLCD.InitLCD();

myGLCD.clrScr();
}

void loop()
{
myGLCD.setColor(255, 255, 255);
myGLCD.setBackColor(0, 0, 0);

myGLCD.setFont(BigFont);
myGLCD.print(" !"#$%&'()*+,-./", CENTER, 16);
myGLCD.print("0123456789:;<=>?", CENTER, 32);
myGLCD.print("@ABCDEFGHIJKLMNO", CENTER, 48);
myGLCD.print("PQRSTUVWXYZ[\]^_", CENTER, 64);
myGLCD.print("`abcdefghijklmno", CENTER, 80);
myGLCD.print("pqrstuvwxyz{|}~ ", CENTER, 96);
myGLCD.print("by aitendo", CENTER, 150);

myGLCD.setFont(SmallFont);
myGLCD.print(" !"#$%&'()*+,-./0123456789:;<=>?", CENTER, 170);
myGLCD.print("@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_", CENTER, 182);
myGLCD.print("`abcdefghijklmnopqrstuvwxyz{|}~ ", CENTER, 194);

myGLCD.setFont(SevenSegNumFont);
myGLCD.print("0123456789", CENTER, 220);

myGLCD.setFont(BigFont);
myGLCD.print("www.aitendo.com", CENTER, 290);
while(1) {};
}

Please help me what is error.

abubaker:
#include <UTFT.h>

extern uint8_t SmallFont[];
extern uint8_t BigFont[];
extern uint8_t SevenSegNumFont[];

UTFT myGLCD(CTE35,38,39,40,41); // Remember to change the model parameter to suit your display module!

void setup()
{
myGLCD.InitLCD();

myGLCD.clrScr();
}

void loop()
{
myGLCD.setColor(255, 255, 255);
myGLCD.setBackColor(0, 0, 0);

myGLCD.setFont(BigFont);
myGLCD.print(" !"#$%&'()*+,-./", CENTER, 16);
myGLCD.print("0123456789:;<=>?", CENTER, 32);
myGLCD.print("@ABCDEFGHIJKLMNO", CENTER, 48);
myGLCD.print("PQRSTUVWXYZ[\]^_", CENTER, 64);
myGLCD.print("`abcdefghijklmno", CENTER, 80);
myGLCD.print("pqrstuvwxyz{|}~ ", CENTER, 96);
myGLCD.print("by aitendo", CENTER, 150);

myGLCD.setFont(SmallFont);
myGLCD.print(" !"#$%&'()*+,-./0123456789:;<=>?", CENTER, 170);
myGLCD.print("@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_", CENTER, 182);
myGLCD.print("`abcdefghijklmnopqrstuvwxyz{|}~ ", CENTER, 194);

myGLCD.setFont(SevenSegNumFont);
myGLCD.print("0123456789", CENTER, 220);

myGLCD.setFont(BigFont);
myGLCD.print("www.aitendo.com", CENTER, 290);
while(1) {};
}

Please help me what is error.
The target device is :
3.5インチ液晶 for Arduino MEGA2560 - aitendo

Did you download and install the UTFT library ?

Thanks for your reply!
Yes i have downloaded and installed the UTFT library.

CLICK MODIFY button.
HIGHLIGHT your CODE
CLICK "#" CODE button (this will create a scroll window to scroll through the code)
CLICK SAVE button.

@ luxxtek

I have installed the libraries. But error is still. Please help me, what can be possibility of error.

@
raschemmel

Sorry. I could not understand your reply.

I AM TALKING ABOUT YOUR INITIAL POST (FIRST POST)
LOOK AT UPPER RIGHT CORNER OF YOUR POST WINDOW.
WHAT DO YOU SEE ? (SEE ATTACHED SCREENSHOT)
NOW THAT YOU FOUND IT, DO THIS:

CLICK MODIFY button.
HIGHLIGHT your CODE
CLICK "#" CODE button (this will create a scroll window to scroll through the code)
CLICK SAVE button.

When you post your code, it should look like this: (scroll window)

 #include <UTFT.h>

extern uint8_t SmallFont[];
extern uint8_t BigFont[];
extern uint8_t SevenSegNumFont[];


UTFT myGLCD(CTE35,38,39,40,41);   // Remember to change the model parameter to suit your display module!


void setup()
{
  myGLCD.InitLCD();

  myGLCD.clrScr();
}

void loop()
{
  myGLCD.setColor(255, 255, 255);
  myGLCD.setBackColor(0, 0, 0);

  myGLCD.setFont(BigFont);
  myGLCD.print(" !\"#$%&'()*+,-./", CENTER, 16);
  myGLCD.print("0123456789:;<=>?", CENTER, 32);
  myGLCD.print("@ABCDEFGHIJKLMNO", CENTER, 48);
  myGLCD.print("PQRSTUVWXYZ[\\]^_", CENTER, 64);
  myGLCD.print("`abcdefghijklmno", CENTER, 80);
  myGLCD.print("pqrstuvwxyz{|}~ ", CENTER, 96);
  myGLCD.print("by aitendo", CENTER, 150);

  myGLCD.setFont(SmallFont);
  myGLCD.print(" !\"#$%&'()*+,-./0123456789:;<=>?", CENTER, 170);
  myGLCD.print("@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_", CENTER, 182);
  myGLCD.print("`abcdefghijklmnopqrstuvwxyz{|}~ ", CENTER, 194);

  myGLCD.setFont(SevenSegNumFont);
  myGLCD.print("0123456789", CENTER, 220);
 
   myGLCD.setFont(BigFont);
  myGLCD.print("www.aitendo.com", CENTER, 290);
  while(1) {};
}

Doesn't that look better ? Isn't that easier to read ?

In this thread, the code notes that there is a CTE modified UTFT library.
http://forum.arduino.cc/index.php?topic=199905.0
[See the notes in the post #1's sketch.]

Which UTFT library are you using?

I am using the UTFT library from TFT manufacturer website. They have provided an example sketch. TFT link is

@ luxxtek and raschemmel. Thanks for your valuable hints. I will follow it in next time.

Well, calling my input "valuable" is a bit of a stretch, but for everyone's sake it's best to use the '#" CODE button.

can you see the UTFT library examples in the IDE, this would confirm that you installed the libraries correctly.

Yes UTFT library examples are in IDE.

I am using the UTFT library from TFT manufacturer website. They have provided an example sketch. TFT link is
3.5インチ液晶 for Arduino MEGA2560 - aitendo

I couldn't read the info on this site but I did find a link to download a UTFT library. In this download, there was a document listing the supported displays. I did not see the CTE35 listed.

When I looked at the UTFT.h file included in this download, I did not see the CTE35 listed in the definitions of displays.

On the other hand, when I go to the modified UTFT library at
http://henningkarlsen.com/electronics/library.php?id=52
I see the CTE35IPS listed in the supported displays and the CTE35IPS defined in UTFT.h.

I still think you need to check which version of the library you are using.

Tonight I will download the sketch and the library from the links on the page where you bought the LCD and I will try to compile it.

OK, it compiles without errors on my mac.
What I did is :

  • I downloaded the sketch at the Japanese link mentioned above
  • I downloded the UTFT library at the same Japanese link
  • I downloaded IDE 1.0.5
  • I installed the downloaded UTFT library
  • I opened the sketch downloaded at the Japanese link with IDE 1.0.5
    The sketch compiles without error without any further editing.

NOTE: I have many other versions of the IDE on my mac with the UTFT library downloaded, directly from Electronics - Henning Karlsen
When compiling with these versions, I get the same error as you.

My advice is to make sure you use IDE 1.0.5 and the sketch and library from the Japanese site.
Reinstall the IDE and library and try again, it should work.

The screendump below is in Dutch but it says compiling has completed without errors.

I thought luxxtek's approach was a good one. So good, in fact, that I tried it myself. I didn't immediately post my results because I assumed that he and I would get similar results. Instead, the results are very different.

It may be due to configuration. I'm using Arduino 1.0.1 on a Linux (Mint) machine. When I used the OP's sketch and the UTFT library from the Japanese site, I got the same error the OP did that "CTE35 was not declared in this scope". When I used the library at Henning Karlsen, I got the sketch to compile after making a few small changes. The first was to change
UTFT myGLCD(CTE35,38,39,40,41);
to
UTFT myGLCD(CTE35IPS,38,39,40,41);

I also had to edit Defaults.c to declare the fontdatatype (s) as constants by adding "const" as shown:
const fontdatatype SmallFont[1144]
const fontdatatype BigFont[3044]
const fontdatatype SevenSegNumFont[2004]

If I was smarter, maybe I could explain this discrepancy.

Can you confirm that you own the display and that the sketch not only compiles without errors but that the display also works?
I don't have that display, I have 2 other that work well with UTFT.

When I use the updated library from Henning Karlsen's site, I am able to compile after making the changes I mentioned in my prior post. It would be nice if I could see if the display works but I don't own a CTE35. I was only addressing the OP's inability to compile.

I don't understand why you and I got different results. I posted mine in case the OP continued to have problems after trying what worked for you.

I'm surprised to see different results. It's mac versus linux and IDE 1.0.5 versus IDE 1.0.1.
Don't know if there's much more we can do for the moment to help the OP.