adafruit 1947 Touchscreen works with Arduino Uno r3 butnot Arduino Uno rev2 wifi

I'm new to this forum so apologies if I don't include enough information. I have a Adafruit 1947 2.8 inch capacitive touch screen shield. I spent a while and got everything working on a Arduino Uno r3 board. I need wifi and it looked like the Arduino Uno rev 2 wifi would be the easiest to get going. My program works on the r3 but all I get is a white screen on the display using the uno rev2 wifi. I also get the following error when compiling the code but I have read that this error is benign and shouldn't matter:

Does anyone know of an edit to the Adafruit libraries that might allow me to use the touch screen with the rev2 wifi?

Also have this list of errors:

In file included from C:\Program Files (x86)\Arduino\libraries\Adafruit_FT6206_Library-master\Adafruit_FT6206.cpp:19:0:

C:\Users\John\AppData\Local\Arduino15\packages\arduino\hardware\megaavr\1.8.5\libraries\Wire\src/Wire.h: In member function 'void Adafruit_FT6206::readData()':

C:\Users\John\AppData\Local\Arduino15\packages\arduino\hardware\megaavr\1.8.5\libraries\Wire\src/Wire.h:62:13: note: candidate 1: uint8_t TwoWire::requestFrom(int, int)

uint8_t requestFrom(int, int);

^~~~~~~~~~~

C:\Users\John\AppData\Local\Arduino15\packages\arduino\hardware\megaavr\1.8.5\libraries\Wire\src/Wire.h:60:13: note: candidate 2: virtual uint8_t TwoWire::requestFrom(uint8_t, size_t)

uint8_t requestFrom(uint8_t, size_t);

^~~~~~~~~~~

C:\Users\John\AppData\Local\Arduino15\packages\arduino\hardware\megaavr\1.8.5\libraries\Wire\src/Wire.h: In member function 'uint8_t Adafruit_FT6206::readRegister8(uint8_t)':

C:\Users\John\AppData\Local\Arduino15\packages\arduino\hardware\megaavr\1.8.5\libraries\Wire\src/Wire.h:62:13: note: candidate 1: uint8_t TwoWire::requestFrom(int, int)

uint8_t requestFrom(int, int);

^~~~~~~~~~~

C:\Users\John\AppData\Local\Arduino15\packages\arduino\hardware\megaavr\1.8.5\libraries\Wire\src/Wire.h:60:13: note: candidate 2: virtual uint8_t TwoWire::requestFrom(uint8_t, size_t)

uint8_t requestFrom(uint8_t, size_t);

^~~~~~~~~~~

Sketch uses 18134 bytes (37%) of program storage space. Maximum is 48640 bytes.
Global variables use 650 bytes (10%) of dynamic memory, leaving 5494 bytes for local variables. Maximum is 6144 bytes.
avrdude: WARNING: invalid value for unused bits in fuse "fuse5", should be set to 1 according to datasheet
This behaviour is deprecated and will result in an error in future version
You probably want to use 0xcd instead of 0xc9 (double check with your datasheet first).

A significant difference between the Uno and the Uno WiFi Rev2 is that the SPI pins on the Uno are on both pins 11, 12, 13 and the 2x3 ICSP header, but on the Uno WiFi Rev2 the SPI pins are only on the 2x3 ICSP header. This can cause problems with shields that have an SPI device connected to pins 11, 12, 13, assuming those are the SPI pins. The way to make a shield compatible with all Arduino boards is to make the SPI connections via the ICSP header, but this is not always done.

From reading the product page for your shield, it sounds like the capacitive touch screen version does make the SPI connection via ICSP header, but the resistive touch screen version makes the connection via pins 11, 12, 13:

So I think it's a bit of a long shot, but just to be sure, please check the solder jumpers on the bottom of the shield:


The three jumpers nearest the "ICSP" on the silkscreen should be bridged and the ones marked "13 12 11" should be open. You'll see a small trace connecting the jumper pads on the bridged jumpers.

1 Like

I wanted to add that the screen does correctly register the position when touched. Therefore the touch part works, it's just the display part that is giving me a whitescreen. Any insight would be appreciated.

Thank you! I will look at that tonight.

12jcarduino34:
I wanted to add that the screen does correctly register the position when touched.

That is good information. On the capacitive touch version, the touch data is sent over the I2C bus, whereas the display is controlled over the SPI bus. So we know the communication over I2C is working, but it is still possible the display problem is about the SPI pins. Like I said, it's purely a wild guess I have about the SPI pins, but it's all I could think of and it's a quick thing to check. Hopefully someone else here on the forum will have a better idea of what's going wrong.

Pert, you got it. All I had to do was cut the 11,12, and 13 bridges and bridge the ones next to the ICSP. This is awesome, thanks!

Yay! I guess sometimes wild guesses turn out to be right. I'm glad to hear it's working now.

This is a good thing to learn about the Uno WiFi Rev2: that the SPI pins are only on the ICSP header. Similarly, the I2C pins are only on the SDA and SCL pins, not also on pins A4 and A5 as on the classic Uno.

The different pin routing causes some confusion, but there is an upside. Due to not having pins routed to multiple headers like the Uno, you actually have 5 more IO pins on the Uno WiFi Rev2, even though it has the same form factor as the classic Uno!

Enjoy!
Per