why some circuit uses analog pin to wire up TFT and the the other ones don´t?

Hi to all!,

I noticed that there are some wiring circuito for TFT 2.8 hooked up to ANALOG Arduino pin and another ones to digitla pins .COuld someone tell me why?

THis is the module:
descarga.jpg

This is the wiring connections:

This is confused to me.

Whats is the difference?

Greetings

descarga.jpg

There are three ways to implement Touch:

  1. Resistive Panel. Unintelligent.
  2. Resistive panel with XPT2046 controller chip.
  3. Capacitive Panel with FT2606 controller chip.

(1) MCU applies voltage across XP, XM pins. Reads analog voltage on YP. Then YP, YM and read analog XM.
(2) Exactly the same procedure but done by the XPT2046. Read result via SPI bus
(3) Not sure exactly how the chip works. Read result via I2C bus.

Method (1) must have YP, XM pins as Analog. The YM, XP can be any digital pins.
The intelligent chips work best if they use the hardware SPI or I2C pins. Most libraries bit-bash SPI on GPIO pins.

David.

Other controller chips are available. They all tend to work the same.

Hi buddy!,

I attached the modulo picture and the wirings connections so that you can see it better.

I realize that I have to put this code portion to be able to work my app properly:

#include "SPI.h"
#include "Adafruit_GFX.h"
#include "Adafruit_ILI9341.h"


#define TFT_DC 9
#define TFT_CS 10
#define TFT_RST 8     ---------> according to my circuito wirings         
#define TFT_MISO 12         
#define TFT_MOSI 11         
#define TFT_CLK 13  

Adafruit_ILI9341 tft = Adafruit_ILI9341(TFT_CS, TFT_DC, TFT_MOSI, TFT_CLK, TFT_RST, TFT_MISO);

I tries many others libraries but it doesn´t work.The problem is that I don´t know how to modify them acoording to my need.

A big hug to you!

descarga.jpg

You have an SPI ILI9341 TFT controller
With an SPI XPT2046 Touch controller
And an SPI SD Card (that you have not connected)

In theory you would place all three 3.3V SPI devices on the same 3.3V hardware SPI bus.
This works 100% with a proper 3.3V Arduino like Zero, Due, ...

In practice 5V Uno or Mega is painful to use with 3.3V devices.

Your Fritzing diagram looks as if it should work. Note that you have to use a bit-banging Touch library like HCTFT_Touch or URTouch. It is an unusual choice of T_IRQ pin.

David.

Hi buddy, did you see the attachments I posted to you?

My module is running fine and in fact I run 2 program codes succesfully.

My problem is to know:

A) How would be the complete wiring connections to make work out touch and SD card slot inside the module.

B) Which are the right libraries to bang this module.

C) To make some simple buttons interactive menu on screen.

Thank you so much!