2019-11-08 11:48 PM
I've poured through every doc I could find and only find 2 mentions of interfacing w/ parallel character LCD , 3 if you count the Cube MX drop down menu indicating it can be done. The data sheet clearly indicates it is a thing. The last paragraph of the FMC feature, section 2.8, pg 24 is entirely about this interface Happens to also be the only mention of it. The big book, RM0410, has exactly one bullet point on page 332, again FMC, listing it as a main feature. Not another word. No register mapping, no alternate function pin mapping, no driver/HAL that I can seem to spot...
I'm sure it's relatively straight forward, but without basic info, hacking the chip and bit banging my UI isn't really what I was hoping to do for the rest of my life. I just can't find any details, actual information. Any help would be appreciated.
Dale
2019-11-09 12:41 AM
Dale,
Thing is, that that section shouldn've made to the DS at all. I guess you are from the younger generation - the seasoned hardware developer with no prior experience with parallel-interfaced LCD would look at the its DS and immediately say, "oh, it's just another SRAM-like interface, except just with one address bit" (often marked as D/C for Data/Command). He would then look up the FMC chapter in the STM32 RM and he's done.
Because that's it.
Setting it up is then the same as with any SRAM, setting up the respective pins for the given AF in GPIO, and writing two or three registers in FMC.
Using it you don't need any driver or whatnot, it's simply writing the needed value to one of two addresses, depending on which address pin of STM32 you've connected to the C/D pin of LCD (and which bank you've used, that's given by which chipselect pin you've used on STM32).
That ST might've written a clear appnote once they've started to push this non-thing as a thing, is another thing. (@Vincent Onde this goes to the dozen which belongs to the SRAM subfeature of FMC).
JW
PS. Please change your username to a normal nick.
2019-11-09 01:49 AM
Okay, I found AN2790.
@Vincent Onde ,
JW
2019-11-09 06:05 AM
What LCD, some generic 162 LCD ? Surely lots of examples for those.
But those are rather 1990's plenty of nice OLED displays now driven via I2C, using SSD-1306/1309, code examples for those easy enough to locate.
2019-11-09 02:55 PM
Ah, HD44780-compatible? It's totally not worth it - F(S)MC probably can't be set slow enough; it's a 6800-style E-latched interface so there's no direct support in F(S)MC without external circuitry; and then it's usually not worth to go for the 8-bit communication which makes the timing even more weird. This is the prime case for timer-driven-GPIO for data and timer outputs for the control signals, as I mentioned above.
JW