Go Down

Topic: 2.4 inch TFT touch LCD Screen Module For Arduino UNO R3 SD low price jocks (Read 205752 times) previous topic - next topic

paulftw

I have (what appears to be) exactly same board.
Drawing example works but there are weird rainbow stripes across the screen.
Anyone knows how to fix this, or at least where to look for a bad connection/short?

casemod

CircuitGuru
http://www.circuitguru.co.uk/

paulftw


Post #14.


Thanks casemod, you are awesome.
For anyone in the same boat as me - I was using a buggy version of TFTLCD. Haven't tried the sketch linked to in Reply #14, but half way through this tread someone attached their sketch a file named st7783.zip.

I've fixed a couple of compile time errors by removing glcdfont.c and usage of it in drawChar. It now works great.

stez90

Hi guys!
I also have the same board (advertised for spdf5408 controller).
I got it (quite) working with UTFT and with TFTLCD, but there is an error in how pixel are drawed.
Looks like it shifts of some pixel every some lines while drawing..
Check the image.
Any advice?

Stefano

casemod

CircuitGuru
http://www.circuitguru.co.uk/

stez90

Yes I have! I tried almost all of the attached libraries/sketch..
I also tried the code snippet from misc.ws and my display says "Unknown driver chip 7783".
Maybe my TFT is damaged, it shows  banding (lots of, not very visible in attached images)..  :(

casemod


Yes I have! I tried almost all of the attached libraries/sketch..

And those are? And forget UFTF, unless you modify the library yourself.

I also tried the code snippet from misc.ws and my display says "Unknown driver chip 7783".

Thats what the controller is, as mentioned on post #11. I dont know why the chinese guys keep mentioning the other controller... But for the price is the best display you'll get your hands on, so worth the hassle.

Maybe my TFT is damaged, it shows  banding (lots of, not very visible in attached images)..  :(

Seems very heathy to me. One of the initialization commands is wrong tough. I find it hard that the libraries for the ST778x are not working. Try the link on post #13 and report. What IDE version are you using?

Did you install the "ADAFRUIT_GFX" library?
CircuitGuru
http://www.circuitguru.co.uk/

stez90

It was the Adafruit Gfx the problem. But before it gives me no error when compiling, and i didn't find any reference to it in the thread.. :~
Now I have problem with the touch, but that is another story :) .. Seems like that Adafruit renamed Point function to TSPoint.. I'll try to modify something..

Anyway Thank you!

stez90

Sorted it out... I left installed the Adafruit library, but "st7783" has it integrated... Conflicts all around  :smiley-red:
Removed the Adafruit one and everything works like a charm..

casemod


Sorted it out... I left installed the Adafruit library, but "st7783" has it integrated... Conflicts all around  :smiley-red:
Removed the Adafruit one and everything works like a charm..


Great. So you basically had the same library installed twice most likelly with different versions.
In the end which version have you used?
CircuitGuru
http://www.circuitguru.co.uk/

stez90

The st7783. I removed all other libraries.
All with 1.0.5 IDE.
With 1.5.7 beta it gives
Code: [Select]
Arduino:1.5.7 (Windows 7), Scheda:"Arduino Duemilanove or Diecimila, ATmega328"

C:\Users\Stez\Documents\Arduino\libraries\st7783\glcdfont.c:9:23: error: variable 'font' must be const in order to be put into read-only section by means of '__attribute__((progmem))'
static unsigned char  font[] PROGMEM = {
                       ^

  Questo report potrebbe essere più ricco
di informazioni con
  "Mostra un output dettagliato durante la compilazione"
  abilitato in "File > Impostazioni"


Not a problem for me, since it works with 1.0.5  8) but i point it out if someone else has troubles.

stez90

Is there a way to use Adafruit GFX functions instead of the one included in st7783? Need a way to use text with background option... St7783 has not that function, so i have to hide the old value that i want to overwrite manually.
GFX has also other useful functions..

casemod


St7783 has not that function, so i have to hide the old value that i want to overwrite manually.


Could this be what you're looking for?

do something (ST7735_something colour, ST7735_background color);

Code: [Select]

tft.setTextColor(ST7735_YELLOW, ST7735_BLACK);
tft.setTextSize(2);
tft.println("Hello World!");
CircuitGuru
http://www.circuitguru.co.uk/

stez90

Wait. I was using the library attached to post #23, wich is different from the one attached to #13.
The #13 is better and faster. And has the required function.

The problem is that #13 has no touchscreen bundled in, so you have to add the adafruit one.

Too much info in a single thread XD

So, as recap:

USE THE LIBRARY FROM POST #13 (http://www.smokeandwires.co.nz/blog/a-2-4-tft-touchscreen-shield-for-arduino/)
USE ADAFRUIT_GFX (https://github.com/adafruit/Adafruit-GFX-Library)
USE ADAFRUIT TOUCHSCREEN (https://github.com/adafruit/Touch-Screen-Library)

BUT

about "tftpaint" example:
Don't know why, but the touch library bundled with st7783 (#23) works better than the adafruit one. The adafruit works good in the lower left corner of the screen, but lacks of speed in the other places and is completely orrible in the top right corner. The st7783 one is way better over all the screen. Unfortunately they are non compatible each other (Adafruit one is upgraded and some functions have different names).

So if you need a good touch then ADAFRUIT_GFX + st7783 (#23) is the way to go. And remember to remove adafruit touchscreen or it won't work.

bricofoy

MANY thanks to all contributors to this post !!! I'm searching how to get this display to work since 3 months, with no luck... And i just read that last post, erase all the crappy libraries I had, install those on the 3 links and... it work like a charm :) :)

so, again THANK YOU !
-tu savais que si tu passe le CD de windows à l'envers, tu entends une chanson satanique ?
-non, mais il y a pire : à l'endroit, ça l'installe !

Go Up