Touchscreen I2C Failing With Wires Soldered to Pins

Hi all,

I have an Adafruit Metro (Uno R3) and an Adafruit 2.8" capacitive LCD touchscreen. The graphical controller is a ILI9341 using SPI and the touchscreen controller is a FT6206.

Touchscreen link:

Arduino link:

When I plug the touchscreen directly into the Arduino as a shield, the touchscreen works totally fine with my application. I can view graphics and it reads my touches perfectly well.

However, I want to be able to physically separate the touchscreen from the Arduino using wires. This is for packaging and electrical purposes (adding an RTC onto the I2C bus).

Because I am overconfident, I soldered wires directly to the touchscreen shield. I plugged the wires into the Arduino and everything except touch works fine. The screen lights up, displays graphics, but the touch does not work.

I thought I did something wrong, so I did the same to a second (identical) touchscreen to a second (identical) Arduino. Same issue.

I verified my I2C connections with a multimeter (measuring an exposed part of the base of the pins on the touchscreen shield to the backside of the via on the Arduino) and I read 0 ohms. I tried measuring across the two wires and I got open wire (~12MOhm). I think I am fairly confident this isn't necessarily exclusively an issue with the wiring being incorrect. I think something is either missing or I am missing a core concept.

Here is the relevant part of my code where I define the touchscreen pins and start the touch and video controllers:

Adafruit_ILI9341 tft = Adafruit_ILI9341(TFT_CS, TFT_DC);
Adafruit_FT6206 ts = Adafruit_FT6206();
#define TFT_CS 10
#define TFT_DC 9


void setup() {
  tft.begin();
  ts.begin();
}

That said, I don't think it's a code issue, as the touchscreen module works fine plugged directly into the Arduino as a shield. Something seems to be going wrong with I2C comms in the conversion between the touchscreen being used as a shield and the touchscreen being connected with wires to the Arduino.

The SPI is using pins 11-13, FYI. SPI handles video, so again, this should not be a problem, but I am including this here for completeness. I should also say I am using single conductor 20AWG wire from Adafruit

Can anyone point me to what may be going wrong? I am at the end of my rope here.

Thanks!

Here is a link to photos of my nasty setup:

(edited - accidentally uploaded same photo to Imgur. New Imgur link)

1 Like

Welcome!!!

  • Did you connect all pins? Some pins may be useless, but there's not a good way to tell, especially with > 2-layer PCBs.
  • Did you connect ISCP headers? I think so, but maybe not!

I verified for a third time - the black wire indeed does make electrical connection with A4 and with the second to the left pin on the shield in my photo. The wire wire does make electrical connection with A5 and with the leftmost pin on the shield in my photo. There is no short between these two lines.

Thank you for the warm welcome!

I connected all the pins I believe matter, and I think I mostly got it right. I say mostly, because obviously something is wrong. Considering the failure mode is just a failure to read from the touchscreen, I believe my issue with with the I2C pins, but of course I may be wrong. Is there a ground reference specific to the I2C pins that I am missing, or something like that?

My understanding is I2C just needs SDA and SCL. Using these 2 communication pins (as well as ground and +5Vdc) I have gotten other I2C devices working without issue before.

I guess I don't possibly know what pins actually matter. I really don't want to connect every single pin from the touchscreen to my Arduino just to get this working, when I2C really should just be 2 communications wires.

I am not using ISCP, I am using the DI pins 11-13 instead. I have made the appropriate modifications to the touchscreen shield and that seems to work fine, as the graphics work and the graphics are carried over SPI. Only I2C seems to be a problem here.\

Thanks!

Try using jumper wires to connect the shield to the Arduino and experiment with the wires, finding the ones that are necessary are which are not.

@anon44338819

Your topic has been moved to a more suitable location on the forum. Installation and Troubleshooting is not for problems with (nor for advice on) your project.

Does the code use interrupts? If so there may be a pin for this also

God invented Shields. You plug them into your Arduino and everything works.

Shields are VERY reliable.

Mystery joints covered in sticking plasters are suspect.
Especially when you connect the "A4" and "A5" shield pins instead of the proper SDA, SCL pins.

Dupont jumper cables are reasonably reliable. Wise to test your "unusual" wiring scheme with jumpers first.
If you are really stuck you will have to read the Adafruit documentation e.g. for why there are eight solder-bridges and three cuttable solder-links.

No, I have not read the documents. Only looked at the photos of the Adafruit pcb.

David.

p.s. you don't need to change any of the default solder-bridge pads.

Hi all, sorry for going dark. I figured out my issue by connecting the shield entirely by jumpers and removing all devices one by one (thank you for the recommendation @anon44338819). My issue was a missing connection from the IOREF pin. I had erroneously believed GND alone to be sufficient. In reality the opposite is true - GND is not even necessary (I still plan on connecting to it just in case I am missing something). To be clear - here is what is required of Adafruit ILI9341/FT6206 touchscreen:

chip select (pin 10 in my code)
data/command (pin 9 in my code)
SDA (analog 4)
SCL (analog 5)
SPI pins (either ICSP or pins 11-13)

@david_prentice The reason I wanted to separate the shield from the Arduino was detailed the original post: packaging and adding to the I2C bus. Additionally, I think implying A4 and A5 are the improper pins to use is a bit ridiculous, considering

  1. The shield natively uses A4 and A5 instead of SDA and SCL pins.
  2. A4 is electrically identical to SDA and A5 is electrically identical to SCL.

Additionally I did read the documentation before posting this, forward and backwards. Believe it or not, IOREF does not appear once in the documentation. Seems to me you should read the documentation (and quite honestly the parent post, as it is clear you didn't) before you accuse me of not reading the documentation.

When you make a Shield you want it to fit Uno, Leo, Zero, Due, Mega2560, ..., Metro328

This means that you put the SPI pins on the 3x2
And you put the I2C pins on the SDA, SCL (next to D13)

God invented Shields so that everything should work on an Arduino.
God invented males and females so that anatomies fit together nicely.

You can buy a Shield and then ignore the fundamental design.
You just connect the SDA, SCL with Dupont cables as if it was the native Shield.
Likewise you connect 3.3V, 5V, GND, DC, CS, RST, LED as if it was the native Shield.

Of course you might find it more convenient to use A4, A5 instead of SDA, SCL. There is a solder-bridge to connect SDA to A4 on the Shield. (and A5 to SCL)
Likewise you might find it convenient to use D11, D12, D13 instead of the 3x2.

You might find it convenient to permanently shine the LED backlight.

For a Uno. The default solder-bridges will work out of the box.
For a Zero, Due, Mega, Leo you cut the D11, D12, D13 bridges. Make the 3x2 bridges.
For a Duemilanove (and original Uno) you make the SDA, SCL bridges because SDA, SCL sockets don't exist.

Personally I would default to SDA, SCL, 3x2. Which would mean every Arduino would work out of the box. But the current arrangement is not difficult for a non-Uno.

Confession. I struggled with a Waveshare Shield on a Nucleo board. ( I forgot to make the 3x2 jumpers to enable D11, D12, D13 )

Confession#2. I still have not read your manual. Only studied the schematic. IOREF is not mentioned in the schematic. Perhaps the schematic on the Adafruit site is wrong or been superseded.

David.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.