TFT display

Hi, I received an LCD 3.2" display to put on my project. A demo sketch came with it. I can't figure out why the compiler doesn't like it. I changed this line from TFT to LCD to TFT_HX8357 with no luck. I'm not good with programming but I am learning. I am posting the sketch with the errors. Please help. Without this there is no benefit trying to write the sketch to program the display. So far I can't get any further than line 73.

_3.5_TFT_DEMO.ino (1.18 KB)

Compiles for me on an Uno.

Sorry, After posting this I forgot to change the board to the Mega board which they advertised what this display worked with.

What version IDE are you using? If I change to UNO board it doesn't like any line with TFT in it. Since the display plugs right in the Mega board, what would I have to change for it to accept the Mega board?

jcann9960:
What version IDE are you using? If I change to UNO board it doesn't like any line with TFT in it.

i'm on 1.6.5 but have you installed the proper libraries ?

jcann9960:
Since the display plugs right in the Mega board, what would I have to change for it to accept the Mega board?

can't tell without seeing the way you wired it up.

As far as I can tell. I added a few extra libraries that work with LCDs. The demo wouldn't work as they say right out of the box.

these 2 need to be installed (via the library manager)

#include <Adafruit_GFX.h>    
#include <Adafruit_TFTLCD.h>

what are the error code you are getting (increase the size of the compiler-monitor by dragging the top upwards)

Thats the two libraries that came with the demo sketch. It would not compile with the TFTLCD.h in it. I will try to compile the original sketch again using the UNO board.

No luck when the TFTLCD.h library is in the sketch using the UNO board. The only thing I haven't tried is th change the IDE to the one you used. It takes so much to erase the 1.8.8 and change it.

jcann9960:
The only thing I haven't tried is th change the IDE to the one you used. It takes so much to erase the 1.8.8 and change it.

don't roll back the IDE.
The other thing you haven't tried is showing us the compiler error messages. also you may not the correct version of TFTLCD.h on your computer.

I have the sketch on my opening question. It should have the errors within the sketch.

Here it is again.

_3.5_TFT_DEMO.ino (1.18 KB)

When you encounter an error you'll see a button on the right side of the orange bar "Copy error messages". Click that button. Paste the error in a message here USING CODE TAGS (</> button on the forum toolbar). If the text exceeds the forum's 9000 character limit, save it to a text file and post it as an attachment. If you click the "Reply" button here, you will see an "Attachments and other settings" link.

Would you be able to tell me the name of the library? If I put in "Manage Libraries" and type TFTLCD nothing comes up. Thanks.

Both libraries are 'built-in' so actually no need to install them, but there may be a 'stray' version of Adafruit_TFTLCD.h somewhere that the compiler is choosing of the proper version, to find out what is actually going on we need to see your Error Messages as explained in reply #13

Hi, I'm sorry if I am doing it wrong but I added an attachment to my reply where I said "Here it is again"

Sorry to take up your time. I need to learn how to post things to the forum. When I use the<> I dont know how to get it posted from there. I tried an attachment but when I looked at it it didn't have the errors with it. ???

pert:
When you encounter an error you'll see a button on the right side of the orange bar "Copy error messages". Click that button. Paste the error in a message here USING CODE TAGS (</> button on the forum toolbar). If the text exceeds the forum's 9000 character limit, save it to a text file and post it as an attachment. If you click the "Reply" button here, you will see an "Attachments and other settings" link.

I think this can not be explained more clearly, if you can not manage this i can't help you... honestly i don't think i can help you if you can not manage this.

jcann9960:
Sorry to take up your time. I need to learn how to post things to the forum. When I use the<> I dont know how to get it posted from there. I tried an attachment but when I looked at it it didn't have the errors with it. ???

When you click the </> button on the forum toolbar, the following text will be inserted:

[code][/code]

These are code tags. The forum software will display any text between these tags in a window that makes it easy to read and copy code. The forum software will also not accidentally interpret code within the code tags as forum markup, which prevents unintentional smiley faces, italics, etc. where parts of your code should be.

After the code tags are inserted, your cursor will be inbetween the opening and closing tag. This means you can click the code tags button and then immediately paste your code. Just remember to move the cursor outside of the code tags before you continue typing normal text into your post. You can also select existing text in the post and then click the code tags button, after which the selected text will be wrapped in those code tags.

It should look something like this:

[code]// your code is here[/code]

If your browser doesn't show the posting toolbar, then you can manually add the code tags. The code tags button doesn't work any magic. It only saves you from having to type out the code tags.

Sorry, the forum horribly mangled my previous reply when I posted it, even though it was fine in the preview. I have now fixed it.