I'm building a radio control transmitter using a Mega 2560, 16 button keypad, two pots, nRF24L01 transceiver, and an ILI9225 TFT. Originally I was using an OLED for the display, and the pots worked nicely with no bouncing, but since installing the TFT they are all over the place. If I unplug it the bouncing stops.
According to the information on the eBay link, the TFT draws a maximum of 80mA. Searching the forum for similar problems, I saw it suggested that a different TFT should be powered from an external supply, so I'm wondering if it's necessary with this one. I've already added 0.1uF capacitors between the Mega pins the pots are connected to and ground, as I read on here as a way to stop bouncing, but it doesn't make any difference.
So is this problem caused by the TFT drawing power from the Mega, and will running it off the same battery with its own voltage regulator solve the problem? Or is it something different?
While trying to sort this problem, I wondered if disabling the display by setting SS/CS HIGH might make a difference. This is something I'll need to do as it's sharing the SPI with the nRF24L01, but I haven't tried that yet. However, setting it HIGH before writing to the display doesn't stop the display updating. Would this be because the library overrides that by enabling it before writing? If so, can I assume that setting it HIGH after updating is disabling it? I don't think it's relevant to the bouncing problem, but I'm getting confused and desperate :) .
I've had to rewire parts of this several times already as the design has changed (and I've corrected my incompetence :) ), so would appreciate some idea if I'm on the right track before I get the soldering iron out again!