MaK11-12
Posts: 17
Joined: Tue Aug 09, 2011 6:27 pm

3.6" TFT fbtft help

Thu Feb 05, 2015 5:41 pm

Hi everyone.

I have a new 3.6" LCD that I have ordered from (dun dun dun) China.
There is an SD card image that I found that works with the LCD. As in, /dev/fb0 is the LCD. The problem is that omxplayer or retroarch do not work. The only way to get them to work is if there is /dev/fb0 and /dev/fb1, where the former is the HD/Composite output through the GPU and I mirror /dev/fb0 to /dev/fb1.

I think I can do this by using the fbtft module. None of the drivers currently in the fbtft_device module work with the LCD.
Therefore, I managed to get source code and a schematic for the TFT.
Here is the source code: http://a.pomf.se/vacicc.tar.gz
Here is the schematic:
Image

I have tried compiling the latest Linux kernel 3.18.5+ with all the fbtft modules including this one https://github.com/notro/fbtft/issues/222.
I've tried getting lcd_init(void) method from the spi_graphical.c and using the contents of that method in the init switch of the fbtft module http://a.pomf.se/neukbo.txt. That didn't work either and I'm not surprised.

I've been trying to get this working for the past two days continuously, and I would really appreciate some help to get this working with fbtft on Archlinux.

notro
Posts: 695
Joined: Tue Oct 16, 2012 6:21 pm
Location: Drammen, Norway

Re: 3.6" TFT fbtft help

Fri Feb 06, 2015 1:14 am

FBTFT won't work with this display.
If you look in spi_graphical.h, it mentions MCP23017. This is a SPI to 16-bit I/O expander.
They drive a parallel interfaced LCD controller entirely through SPI.
It resembles spritemods circuit in function: http://spritesmods.com/?art=spitft&page=2

FBTFT doesn't support this, and probably never will with the current codebase.
I'm currently rewriting FBTFT, which will make it possible to support such displays, but that is somewhere in the unknown future.

Ramblings:
The circuit is very slow, so I can't understand why people keep replicating spritemods hack. This isn't the only display using his circuit.

Note that the MCP23017 has a max speed of 10MHz, which is very slow for a 240x400 display.
Even if it could work with FBTFT, I doubt it would be useful for anything other than a mostly static GUI.
Using X windows with it would probably be bad for your mental health ;)

Sidenote:
The lack of high speed SPI to parallel off the shelf IC's led me to make this circuit (based on spritemods work): https://github.com/notro/fbtft/wiki/SPI ... ce-circuit
But a native LCD controller SPI interface is the fastest, or using something like Guzunty: https://github.com/Guzunty/Pi/wiki

Edit:
I just want to make clear that I in no way want to belittle spritemods work. I couldn't have made my circuit without his research.

MaK11-12
Posts: 17
Joined: Tue Aug 09, 2011 6:27 pm

Re: 3.6" TFT fbtft help

Fri Feb 06, 2015 8:13 am

notro wrote:FBTFT won't work with this display.
If you look in spi_graphical.h, it mentions MCP23017. This is a SPI to 16-bit I/O expander.
They drive a parallel interfaced LCD controller entirely through SPI.
It resembles spritemods circuit in function: http://spritesmods.com/?art=spitft&page=2

:snip:
Thank you very much for your in-depth post. I'm not surprised really, this LCD was much cheaper than the others so there had to be something wrong about it.

I have had a look at the LCD Modules on the fbtft wiki page https://github.com/notro/fbtft/wiki/LCD-Modules, and I was wondering if there was an LCD module that you could recommend to me please?

Edit: Is this good? http://www.wvshare.com/product/3.5inch-RPi-LCD-A.htm

Edit2: I just bought a waveshare 3.2" B since support for it was added to fbtft about two months ago. :)

geerttttt
Posts: 22
Joined: Wed Apr 15, 2015 1:49 pm

Re: 3.6" TFT fbtft help

Wed Apr 15, 2015 1:53 pm

I bought the same device. Which software image did you had to run it? I only got some source code to display a image as you had aswell.

Did you do anything with the display?

And, what was the framerate? Was it really bad? I need to display a GUI on it with some animations, but mostly nothing too heavy.

Hope to hear it soon, thank you!

Return to “Advanced users”