ILI948x_t4_mm - An 8 bit parallel display driver for the Teensy MicroMod

Rezo

Well-known member
After being a member of this forum for the past 2-3 years, consuming the vast amount of knowledge & expertise from the very smart and talented forum members.. It's time for me to give back a little something.

In the past few weeks I started to dig into FlexIO and DMA to try and understand how the hell it works in hopes of creating an 8 bit parallel display driver for the ILI9481/9486/9488.

Thanks to all the help from forum member easone and threads by KurtE, miciwan and Paul - I have a proof of concept library available:

ILI948x_t4_mm
https://github.com/david-res/ILI948x_t4_mm
mm_flexio_example.jpeg

This is a BASIC display driver - it has several setup function that will allow a user to set rotation, frame rate, invert display etc
And it's main function allows a user to pass an array of pixels in 16 bit format (RGB565).

This library has alot more work needed to get it working 100%, but as a proof of concept it's a great starting point.

It utilizes FlexIO to create an 8 bit bus on the Teensy MicroMod
It also utilizes DMA to offload the large transfers from the CPU, although a polling method can be used as well.

The following Teensy MM pins are used to drive the display and cannot be changed:
  • pin 10 - WR
  • pin 40 - D0
  • pin 41 - D1
  • pin 42 - D2
  • pin 43 - D3
  • pin 44 - D4
  • pin 45 - D5
  • pin 6 - D6
  • pin 9 - D7

For CS, D/C, RST pins, any GPIO pins can be used.

The basic setup is explained in the Readme file under the repo and an example sketch has been provided as well.

The next features to be added are a function to changed the bus speed - this directly affects the actual refresh rate, and I also intend to incorporate some simple functions to read data from the screen such as display make/model, setup config and GRAM content.

There are still some glitches with DMA, so I encourage anyone and everyone to contribute in enhancing this library!

Enjoy,
David
 
Hi David,

There are still some glitches with DMA, so I encourage anyone and everyone to contribute in enhancing this library!

I would like to do, but buy a MicroMod?
With the Teensy 4.1 probably does not work?

Kind regards
Bruno
 
This library will work only on the MicroMod.
The Teensy 4.1 does not expose enough FlexIO pins to get enough contiguous pins on FlexIO 1 and 2.
 
I think the MicroMod is nice, but the carrier plate is just too big for my projects.
Maybe there will be something smaller at some point, wait and see.
Unfortunately I can not handle M.2 sockets myself :rolleyes:

If there was the Teensy 4.2 with enough FlexIO pins for a parallel display and an SGTL5000, I'd order 1000+ of them right now, really :cool:
 
Technically it can be done on a Teensy 4.1 but without the use of DMA - so the transfers will hold up the main loop for 5-6ms on a full screen (480x320) update. But the current version of the library does not have the configuration for this yet.

I actually prefer the MicroMod Teensy as it makes it much easier for me to remove the Teensy if needed and is square form factor does not limit me to a min width PCB for mounting it.
 
Hi David,

Would it be easy to modify your library to drive a 16 bit LCD ?

I like to drive a 5" 800 x 400 SSD1963 panel in 16 bit mode.
 
Hi David,

Would it be easy to modify your library to drive a 16 bit LCD ?

I like to drive a 5" 800 x 400 SSD1963 panel in 16 bit mode.

On a MicroMod - can't be done at this time.

On a Teensy4.1:
You can strip down the library and make modifications to it so that it uses FlexIO3 instead of FlexIO2
You need to update the pin setup for FlexIO, update the pointer size to the functions, and update the SHIFTCFG and SHIFTCTRL registers
You need to rewrite the display init sequence for the SSD1963.
You need to ditch the DMA portion as that's not supported on FlexIO3.
It's not a hard task to anyone familiar with FlexIO, but not something I can work on at the moment unfortunately.
 
Back
Top