Primary display via SPI?
Apologies for the broad question. I've been reading and searching on this subject for over a week now and I'm lost. I find lots of information but can't quite seem to tie it together. Here's the situation:
- I know how to drive displays (very well in fact, I make demos for lots of them at work - character, graphic, OLED, TFT, various interfaces, etc). But I've always used microcontrollers or FPGAs to do this.
- Despite this I am an idiot when it comes to Linux. I don't think I've spent more than a year cumulatively on Linux-based platforms in my lifetime.
- I can already see how I might create a standalone application in C or Python which would drive a display. I will experiment with this first, as it's easier (also I need it for some specific projects anyway).
- But I want to create a proper 'display driver' which can be used to both (a) run the display from boot as the primary display and (b) run it as a secondary display I can point things like image viewers, games or video players to. This is where I'm getting lost!
- I know it won't perform like lightning and it can be resource intensive, that is fine.
- I'm not interested in X support or anything - would be a bonus, but I'm interested in displaying the command line, videos, games, images etc. Don't think I've ever plugged a mouse into my Pi, haha.
- I'd prefer not to use a 'library' file if possible and actually learn to implement everything myself. There are lots of cool displays I want to try with my Pi so I'll be doing this over and over again!
I could facilitate 50% of what I want to do without writing a 'driver' and using the display as a traditional display device. For example displaying images, text, bespoke graphics etc could all be done manually in my software. But I really want to achieve this final step! Having a display built into my Pi's casing would be awesome.
Please, does anyone know of a concise series of documents/threads which describe how one writes and installs a piece of software which will pipe everything to this display as if it were the normal HDMI/composite output? Perhaps it is not possible to get it to do that immediately from boot, but perhaps by the time it hits the bash login prompt it could be operational?
Am I correct in thinking this involves /dev/fb0 (or dev/fb1 as a 'secondary' display)?