0

TFT touchscreen selection question
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

TFT touchscreen selection question

by NineFingers on Sat Jun 17, 2017 6:50 pm

All,
I am working on a project that requires a capacitive touch screen interface in excess of 4.5". due to limited motor skills of the user a touch screen rather than physical buttons must be used.

I currently have my proof of concept working with the the. 2.8"tft. PRODUCT ID: 1947, controlled with an Arduino MEGA 2560.

My coding ability is not the strongest, so a strong library support is preferred, and the Arduino control is a must so I do not have to re-code everything.

Your experience and insight appreciate,
Jason
Ninefingers
Last edited by NineFingers on Sun Jun 18, 2017 12:00 pm, edited 1 time in total.

NineFingers
 
Posts: 14
Joined: Fri Jun 02, 2017 1:38 pm

Re: TFT touchscreen selection question

by adafruit_support_rick on Sun Jun 18, 2017 8:00 am

Have a look at this screen:
https://www.adafruit.com/product/1596
and this controller:
https://www.adafruit.com/product/1590

We also have a 7" display that will work with that controller
https://www.adafruit.com/product/2354

adafruit_support_rick
 
Posts: 33782
Joined: Tue Mar 15, 2011 11:42 am
Location: Buffalo, NY

Re: TFT touchscreen selection question

by NineFingers on Sun Jun 18, 2017 12:23 pm

Rick,
Thank you for the input. Will this this driver / library combination support displaying integers as easily as the one I am using now, or will I have to convert integers to a string first?

Currently the ili9341 library supports printing integers by using a simple tft.println(); command. I noticed that this library uses a specific tft.textWrite(string); command. If I have a variable that is stored as an integer will it display it properly?
Example below VAR_4 is a numeric variable stored as an INT.
Code: Select all | TOGGLE FULL SIZE
        tft.setCursor(60, i * 16); // defines starting text position for this code block
        tft.print("Item #"); // prints to the the TFT Screen
        tft.print(i); // prints to the the TFT Screen
        tft.print(" = "); // prints to the the TFT Screen
        tft.println(VAR_4); // prints to the the TFT Screen
        tft.setCursor(60, (i * 16) + 16); //sets cursor for printing


Thank you again for your time, I really want this project to be successful, and have now purchased WAY more hardware than needed due to my failing to research it properly first.

Jason

NineFingers
 
Posts: 14
Joined: Fri Jun 02, 2017 1:38 pm

Re: TFT touchscreen selection question

by adafruit_support_rick on Mon Jun 19, 2017 9:22 am

You don't have to use text mode. If you leave it in graphics mode, then the regular print statements work the same as the tft code you already have. Of course, you'll have to adjust your cursor coordinates, since this is a larger display.

adafruit_support_rick
 
Posts: 33782
Joined: Tue Mar 15, 2011 11:42 am
Location: Buffalo, NY

Re: TFT touchscreen selection question

by NineFingers on Mon Jun 19, 2017 9:30 am

Thank you again Rick. Order incoming. Now to sell the $75.00 worth of buttons I can no longer use,or..... start another project;)

NineFingers
 
Posts: 14
Joined: Fri Jun 02, 2017 1:38 pm

Please be positive and constructive with your questions and comments.