Library for Open-Smart 3.5 LCD ( Driver IC S6D05A1)

I recently bought an 3.5 inch LCD from Aliexpress with driver IC S6D05A1. Here is the link to the listing on AliExpress https://www.aliexpress.com/item/32956967893.html?spm=a2g0s.12269583.0.0.4d6f6030thstnm.

This particular model had a very good rating on the sellers page but in the hindsight it seems to be not a good choice as the provided instructions and the library don't work. Tried contacting the seller but not getting any support :frowning: The driver ic S6D05A1 seems to be not a very popular one as there is hardly any library that supports it.

I am using an Arduino uno with a 3.3 level shifter, tried using an old mcufriend library that the seller recomended but only get a blank screen. Could you please help me make it work? Thanks

I have never supported S6D05A1controller. But I could do, if you are prepared to give some feedback.

The Open-Smart video shows the display being used with a 3.3V "Uno clone" board. It is very important to use 3.3V GPIO pins.

Do you have a GitHub account? (not important but useful to know)
What country are you in? (it helps if we are in similar timezones)

Do you have a datasheet for the S6D05A1 ?

David.

Thanks David :slight_smile: I am definitely willing to work on this with you and give you all the feedback.

I suppose you are talking about the youtube video for the Open smart LCDs but they have different driver ICs I presume. But still I have tried using two different logic level converters with UNO.

I do have a Github account and I am in Belgium so GMT/UTC + 2h. Which timezone are you in?

I have one schematic for the S6D05A1 but not a datasheet. I will try to search it and let you know :slight_smile:

I am in the UK. One hour behind Belgium.

Did Open-Smart provide any code ?
Does Open-Smart have a datasheet ?

I have a datasheet for S6D02A1 which is 132x162 and has MIPI-style commands. I suspect that S6D05A1 will also have MIPI-style user commands. And hopefully, the manufacturer registers are "similar" to the S6D02A1.
Life is much easier with the genuine datasheet.

David.

Open-Smart did provide 4 libraries ( Adafruit_GFX, Open-Smart_tft, Touchscreen & LM75) and insisted to use these specific ones only.

Here is the link : S6D05A1 driver IC - Google Drive

In one of the header files I did find some code relevant to this specific driver IC. Perhaps it will give you some idea whether it uses MIPI-style commands. I don't know anything about that. Here is the code :

#ifdef SUPPORT_05A1

case 0x05A1:

    _lcd_capable = AUTO_READINC | MIPI_DCS_REV1 | MV_AXIS | READ_24BITS;

    static const uint8_t S6D05A1_regValues_max[] PROGMEM = {        // Atmel MaxTouch

        0xF0, 2, 0x5A,0x5A,

0xF1, 2, 0x5A, 0x5A,

0xF2,19,0x3B,0x33,0x03,0x0C,0x08,0x08,0x08,0x00,0x08,0x08,0x00,0x00,0x00,0x00,0x33, 0x0C,0x08, 0x0C,0x08,

0xF4,14, 0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00, 0x04,0x70,0x03,0x04,0x70,0x03,

0xF5,12, 0x00, 0x46,0x70,0x00,0x00,0x02,0x00,0x00,0x00,0x00,0x46,0x70,

0xF6,8,0x03,0x00,0x08,0x03,0x03,0x00,0x03,0x00,

0xF7,5,0x00,0x80,0x10,0x02,0x00,

0xF8,2,0x11,0x00,

0xF9, 1,0x14,

0xFA, 16,0x33,0x07,0x04,0x1A,0x18,0x1C,0x24,0x1D,0x26,0x28,0x2F,0x2E,0x00,0x00,0x00,0x00,

0xFB, 16,0x33,0x03,0x00,0x2E,0x2F,0x28,0x26,0x1D,0x24,0x1C,0x18,0x1A,0x04,0x00,0x00,0x00,

0xF9, 1,0x12,

0xFA, 16,0x36,0x07,0x04,0x1C,0x1C,0x23,0x28,0x1C,0x25,0x26,0x2E,0x2B,0x00,0x00,0x00,0x00,

0xFB, 16,0x33,0x06,0x00,0x2B,0x2E,0x26,0x25,0x1C,0x28,0x23,0x1C,0x1C,0x04,0x00,0x00,0x00,

0xF9, 1,0x11,

0xFA, 16,0x33,0x07,0x04,0x30,0x32,0x34,0x35,0x11,0x1D,0x20,0x28,0x20,0x00,0x00,0x00,0x00,

0xFB, 16,0x33,0x03,0x00,0x20,0x28,0x20,0x1D,0x11,0x35,0x34,0x32,0x30,0x04,0x00,0x00,0x00,

0x44,2,0x00,0x01,

0x2A,4,0x00,0x00,0x01,0x3F,

0x2B,4,0x00,0x00,0x01,0xDF,

0x36, 1,0x08,

0x3A, 1,0x55,

0x11,0,

TFTLCD_DELAY8, 120,

0x29,0,

    };

    init_table(S6D05A1_regValues_max, sizeof(S6D05A1_regValues_max));

    p16 = (int16_t *) & HEIGHT;

    *p16 = 480;

    p16 = (int16_t *) & WIDTH;

    *p16 = 320;

    break;

#endif

I have sent a message to the seller about the datasheet and hopefully will get one. In the meantime I will google it also.

I wish that they would "ask" instead of hacking obsolete library versions.

Then I could support their products seamlessly.
At least Open-Smart are better than the "badly spelled library" crew.

David.

Is this a hacked version of a library written by you?? :roll_eyes: Was this anyway relevant for you w.r.t. the commands ?

The datasheet for the S6D05A1 is not easy to find. However, I found a datasheet for another display that uses the same IC and has some code. Maybe it's useful?

Thanks for the PDF. Not for your controller interface but useful to see.

Do you possess any proper 3.3V boards?
e.g. Due, Zero, STM32, ESP32, Teensy3.x, Teensy4.x

Life is much simpler without level shifters.
Personally, I use Open-Smart Uno clones with switchable 3V / 5V

David.

Yes I do have ESP32 and Node MCU. Actually these are my preferred MCUs to work with. Besides I also have a pro mini but I suppose it will have some memory limitation with big libraries.

An 8MHz 3.3V Pro Mini is ideal. Connect all the LCD pins according to the regular Uno scheme:

//LCD pins  |D7 |D6 |D5 |D4 |D3 |D2 |D1 |D0 | |RD |WR |RS |CS |RST|
//AVR   pin |PD7|PD6|PD5|PD4|PD3|PD2|PB1|PB0| |PC0|PC1|PC2|PC3|PC4|
//UNO pins  |7  |6  |5  |4  |3  |2  |9  |8  | |A0 |A1 |A2 |A3 |A4 |

Then you can run the regular LCD_ID_readreg.ino from the examples

I will post a "test_S6D05A1" Branch on GitHub later today.

David.

Thanks David. Looking forward to your upload :slight_smile:

I presume that you have a USB-Serial dongle connected to the Pro Mini.

Which means that you can run LCD_ID_readreg.ino and copy-paste the Serial Terminal to your message.

David.

Yes I have a USB-FTDI dongle. Will post the output here once you share the branch on GitHub.

On Pro Mini there is no A4 so I have connected RST to Reset on Mini. Should work right?

Analog#4 (A4) is marked as SDA on the Pro Mini. It is PORTC.4 on the mega328P. Please connect LCD_RST pin to pin marked SDA

I have posted a "test_05A1" branch on GitHub.
And started an Issue. https://github.com/prenticedavid/MCUFRIEND_kbv/issues/181

It is best to continue discussions via the GitHub "Issue"

David.

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