McuFriend Library with 3.97inch 16BIT Tft (NT35510)?

Good evening All,

Some time ago I acquired a 800x480 tft screen (details of the model are here: 3.97inch 16BIT Module NT35510 SKU:MRB3973 - LCD wiki)
The model supports 8bit or 16 bits and mine is configured for 16 bits.
(Solder R3 and R4 with 0Ω and disconnect R2 and R6: select 16-bit data bus mode (default), use DB0~DB15 data pin)

I then acquired a 34 pins adaptor (the TFT LCD Mega Shield V3.0 as can be seen in the pictures here: https://www.auselectronicsdirect.com.au/3.2-inch-touchscreen-lcd-screen-shield-for-arduino)
I am now trying to marry the 2 and make them work with an Arduino Mega 2560.

I have amended the MCUFRIEND_SHIELD.H file to indicate "#define USE_SPECIAL" and amended the "MCUFRIEND_SPECIAL.H" to select the shield that would work.
The only one that would is: #define USE_MEGA_8BIT_SHIELD
This surprised me as I would have expected the 16BITS shield to work....but it did not (I get a blank screen).

The results that I get with the USE_MEGA_8BIT_SHIELD are very random: A collection of horizontal green lines.
The "tft.readID()" functions returns the generic "0xD3D3" value and therefore the library replaced it by 0x9481".
A few tests indicated that a few other ID would "work" (0x9329, 0x9486, 0x8357) but the display remains random (altering the controller ID only affects the color of the random lines: Green, White, or Red in the main).

I understand that the Shields are "write only" and that because of this the "LCD_ID_readreg" will not return any usable data.

I was wondering if any one had managed to make one of these 3'97 screens work with the MCUFRIEND Library.

Regads
H

Did you try to force ID to 5310 ?

    if (ret == 0x5310)          //NT35310: [xx 01 53 10]
        return 0x5310;

Hi JM,
Thanks for the answer.
I eventually (after much searching) found this: 4.0inch Arduino Display-Mega2560 NT35510 - LCD wiki
There is a link to a large amount of source code & examples for Arduino, C51 and STM32.
I was able to "remap" the pins to my need (by software). So all is well.
Regards
H

Hi @hml_2, Sorry,

I just found out that NT35510 really exists, and is for a higher resolution than NT35310.
I found one on AliExpress from Surenoo: 3.97 / 4 inch 480*800 16.7M HD MCU Parallel IPS TFT LCD Module Display Screen Resistive Touch Panel NT35510 for Alientek STM32
It is not supported by MCUFriend.kbv.
But it is supported by Arduino_GFX: Arduino_NT35510.cpp
-jz-

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