Changes that I've missed in ILI9431_t3?

boroko

Active member
Hi all,
Pulled out an older project to resurrect it (update it really), and while it runs on the device, the program won't compile any longer. Teensy 3.2 and Adafruit LCD with ILI9431. If I remember correctly, I was using Arduino 1.8.(teens) when I built it. When I go back in to start playing I'm getting compile errors and a number of warnings, the worst seem to be on a couple of the colors. ILI9431_LIGHTGREY, ILI9431_ORANGE, and ILI9431_DARKCYAN: all showing "not declared in this scope". I went back into the current GIT and the keywords appear to be the same so I have no idea how they could not be declared with #include "ILI9431_t3.h" in the header. Current IDE is Arduino 2.3.2 and it has been updating automatically. I found that Paul suggested that TeensyDuino 1.59 should be fine with that, is there something possibly related to updates that I'm not looking at? Been looking through the forums and anywhere else I can think of. Any suggestions would be welcome on where to start. I suppose I could re-spin the whole thing with current parts, but I kind of dread the thought of that.

Side note: I know it's already past, but reading through the death of 3.2 really made me sad. I understand, and I can't begin to think just how hard this hit others far more than me. Thank you Paul for letting us have it for a while.
 
I think there may be something else maybe going wrong... That is the ILI9341_t3 library does still define
those colors.

From the latest Teensyduino, I see the header file still has:
Code:
// Color definitions
#define ILI9341_BLACK       0x0000      /*   0,   0,   0 */
#define ILI9341_NAVY        0x000F      /*   0,   0, 128 */
#define ILI9341_DARKGREEN   0x03E0      /*   0, 128,   0 */
#define ILI9341_DARKCYAN    0x03EF      /*   0, 128, 128 */
#define ILI9341_MAROON      0x7800      /* 128,   0,   0 */
#define ILI9341_PURPLE      0x780F      /* 128,   0, 128 */
#define ILI9341_OLIVE       0x7BE0      /* 128, 128,   0 */
#define ILI9341_LIGHTGREY   0xC618      /* 192, 192, 192 */
#define ILI9341_DARKGREY    0x7BEF      /* 128, 128, 128 */
#define ILI9341_BLUE        0x001F      /*   0,   0, 255 */
#define ILI9341_GREEN       0x07E0      /*   0, 255,   0 */
#define ILI9341_CYAN        0x07FF      /*   0, 255, 255 */
#define ILI9341_RED         0xF800      /* 255,   0,   0 */
#define ILI9341_MAGENTA     0xF81F      /* 255,   0, 255 */
#define ILI9341_YELLOW      0xFFE0      /* 255, 255,   0 */
#define ILI9341_WHITE       0xFFFF      /* 255, 255, 255 */
#define ILI9341_ORANGE      0xFD20      /* 255, 165,   0 */
#define ILI9341_GREENYELLOW 0xAFE5      /* 173, 255,  47 */
#define ILI9341_PINK        0xF81F

In cases like this (and most others) it would help to see the code and maybe full set of error listing.
 
Wonder of wonders... in the act of trying to pare down a 1200 line program to something I could present here, I had some lucky guesses.

I apologize for not posted some code for you to at least get an idea, because I realize it's almost impossible to guess what someone is doing and tests peoples good graces. I didn't in this case in the hopes that it was just such a global oversight that someone would recognize it.

Turns out that when the compiler warns you that multiple libraries are found and it tells you which one it used and which it didn't, there's a hint there. I don't doubt that most of you probably already knew that, but I always got away with it and was not one of the "most" in this case. What evidently happened was that my prior way of storing the libraries was different, and it was pulling old ones, while the new ones managed by the 2.x.x method were not being used. No telling what it was thinking.

Well, I'm at least back to trying to conventionally repair a poorly written program. Thanks for listening and being a sounding board so I could hear myself think.
bo

EDIT: May not be a complete answer. Just compiled a different version of the program, and I'm seeing some of the same issues. Still working on it....
 
Last edited:
A little bit of an update: I've found that explicitly declaring function prototypes has greatly reduced some of the very odd behavior. New one for me. Still a few things I need to sort though.
 
Back
Top