I have a Waveshare device which I believe uses the GC9A01 LCD driver. Waveshare has sample code in Python as well as C. The C code references LVGL and has a copy of version 8.1.0 of the LVGL code. I came here because I thought the code I had questions about came from here but it appears that is not correct. However, I’m hoping someone here will be kind enough to help me out.
The Python code as well as the C code both use commands in the initialization process that are not documented in the datasheet for the chip. A post on another forum suggested that this chip is probably similar to other chips and so I went looking for datasheet for those chips and they are also lacking in the commands that I’m looking for. I guess this might be a common problem but I’m hoping someone can point me to a reference for the common (and I assume historic) commands used by LCD drivers.
Just a few examples, the first sequence sent in both the Python and C sample code from Waveshare is 0xEF as a command, 0xEB as a command, and 0x14 as data. There are also a sequence of command/data pairs with the commands 0x84 through 0x8F. None of these are documented. I’m hoping someone here has knowledge of these commands.
It is not uncommon to have undocumented commands for a display IC. Sometimes it’s the documentation you are looking at is stale and there is a newer version of the IC so there is a newer version of the datasheet.You might not be able to locate a newer version of the datasheet because a lot of them are not supposed to be distributed without being a vendor for that display IC.
You can take a look here at this driver as I know this one works. I am the person that wrote it.
Thank you… I don’t think I have any real questions. Your code has magic numbers like the code I’m looking at.
I wrote Waveshare support asking about this and here is their reply
The initialization sequence used is based on parameters calibrated at the factory for the specific LCD module.
These command values are provided directly by the manufacturer and are intended to ensure proper display performance.
Unfortunately, many of these commands are undocumented and not explained in the GC9A01 datasheet, as they are part of the factory-optimized configuration.
We recommend using the provided initialization routine as-is for best results. If you are looking to customize specific display behavior, we advise caution when altering the core init sequence.
If you have any further questions, feel free to contact me