Planar EL Display Driver
MasterC
Posts: 39
Hello,
I need to interface a Prop to a 512x256 monochrome Planar EL display (to be exact, model EL512.256-H3-FRA). I was hoping to use the Prop' video generator to do so, and ideally I was hoping to use or tweak the default video drivers from the Propeller library, or find something in the obex that I could use without too much tweaking. It seems like what I need to do can't be too far off from either the standard TV or VGA implementations. However, I searched around here for quite awhile, but I'm afraid I am not well versed enough in video output schemes to tell for sure what might work at first glance. If anybody can provide any pointers, I would very much appreciate it!
The datasheet for that display is available from a google search, but it looks like the video input interface boils down to four lines:
VID - signal that supplies the pixel information
TVID - (optional) Second data input for two bit parallel mode
VS - vertical sync
HS - horizontal sync
VCLK - shifts data on the VID and TVID lines into the display
From this and the timing diagrams, I can gather what my driver would have to do. What I don't know is if that is like something that already exists.
Does it sound close to something one of the existing objects can handle?
Thanks!
I need to interface a Prop to a 512x256 monochrome Planar EL display (to be exact, model EL512.256-H3-FRA). I was hoping to use the Prop' video generator to do so, and ideally I was hoping to use or tweak the default video drivers from the Propeller library, or find something in the obex that I could use without too much tweaking. It seems like what I need to do can't be too far off from either the standard TV or VGA implementations. However, I searched around here for quite awhile, but I'm afraid I am not well versed enough in video output schemes to tell for sure what might work at first glance. If anybody can provide any pointers, I would very much appreciate it!
The datasheet for that display is available from a google search, but it looks like the video input interface boils down to four lines:
VID - signal that supplies the pixel information
TVID - (optional) Second data input for two bit parallel mode
VS - vertical sync
HS - horizontal sync
VCLK - shifts data on the VID and TVID lines into the display
From this and the timing diagrams, I can gather what my driver would have to do. What I don't know is if that is like something that already exists.
Does it sound close to something one of the existing objects can handle?
Thanks!
Comments
In short, you need to shift data out and synthesize a clock. The video generator doesn't generate an external clock AFAIK.
The most novel way I've seen this done is this:
You will have to generate the hsync and vsync signals per the datasheet, but the snippet above should give you an idea. The high speed propeller communication object uses the same shift mechanism IIRC, I know kurenko wrote an object that does.
That would mean you could WAITVID to send 32 bits serially, or 4 bytes parallel transfer. I think the limiting factor would be minimum number of PASM instructions to fetch and stuff data from hub memory. Certainly faster than the 20Mbits using the stuff and shift method.
Get cracking then!
BTW, Sharp has an interesting 6" bistable display that works a bit differently than the normal ones that uses a technology called "memory LCD" (with a memory bit behind each pixel, or maybe 2 bits, I forget, as it may have 4 shades). It was released a couple years ago. At one point, I think it was sampling for around $90 bucks, but since it seems like no mainline manufacturers have picked it up, it'll probably stay expensive and/or fall by the wayside. I wonder if anyone here has used it, or any of the other bistable displays. Anyway, I wish Sharp had come out with a limited color version of it as they had roadmapped to do, but, so far, I guess not, which will apparently leave the market to Qualcomm's Mirasol (already on e-books in Korea/China and Taiwan) and Samsung's Liquivista technologies to battle it out, though I doubt such displays will be available cheaply to Joe and Joanna Hacker, even if they had the hardware (and skills) to drive them. Anyway, the cost of the EL display of this post really makes me appreciate the Solomon and Illitek driven displays and the composite/VGA driven displays, as well as the cheaper RGB ones. We now return you to your regularly scheduled program.
You only need one or two data lines instead of 6 or 8, but still it should work...
pedward, thanks for the info and example code; I'll keep this in mind if I decide to implement without the video generator.
kuroneko, it sounds like you are saying it can be done with the video generator, but so far I do not understand exactly how...using one of the existing drivers (with a tweak), or from scratch?
I haven't looked at existing LCD drivers in terms of signal generation but I believe they are similar enough to what you need (Rayman?). So it may be beneficial for you to start with one of them and tweak it and maybe later - when you're comfortable with the HowTo - write one specifically for this display.
Anyway, I was hoping to get up and running quickly by leveraging existing objects, but I'm starting to wonder if I would actually come up to speed quicker by writing my own display driver. I was looking through Rayman's code and Chip's default VGA and graphics drivers trying to figure out what I need to change to work with my monochrome display, but I keep getting lost somewhere between the "front porch" and the "back porch" and all the other stuff in there. I think my display driver doesn't need all that complexity. Then again, it would be really nice if I could make use of the existing graphics object, and I'm not sure I know how to do that starting from scratch.
If you have any further input, I'm all ears (and I'd really appreciate it).
Thanks!
P.S. Yes...this display is a bit spendy!
Your code then becomes:
The ones_and_zeros is a constant declared in the DAT section as $0000_FF00 since the upper 2 bytes aren't used in 2 color mode.
You then configure the VGA mask in Vpins field of VCFG to be % 0000_0001 for a single bit output. The PLL mode needs to be 2 per kurenoko's post, that APIN will be your clock output. You then need to configure a pixel clock (FRQA value) for the number of pixels per line, plus the extra clocks around hsync and vsync, multiplied by the number of rows and then multiply that by 70hz. You will end up with around 9.8Mhz pixel clock. The PLLA clocks per pixel should allow you to either do dot addressing or stretch the pixels to use less system memory for the screen buffer. The frame clocks is just 32*PixelClocks.
You will need to twiddle the hsync and vsync bits in software, or you can use part of the color mask value, but that complicates things more than need be. Just stuff a line, twiddle the sync, stuff a line, twiddle the sync, etc, until you have a complete output.
You can use the random number generator to give you test data, or you could use an alternating pattern such as $AAAA_AAAA or $5555_5555, which would give 1 pixel on/off vertical bars. This would help with testing to ensure alignment from row to row, and it simplifies the coding to eliminate the need to stream data while working out the mechanics of driving the display.
Get it to generate your test pattern on the display it's built for. Then (assuming you have gear) look at the timings you see, compare to data sheet and compare to instructions in the driver. That's to get you oriented. Make small modifications to each, verifying against the data collected earlier.
That's your template.
Take the timing data from the target display, and modify the driver to match those.
On your way through, comment the driver code so that you know what each instruction does. That's how I got some of my early driver code working nicely. You may learn there are short cuts, or special requirements, at which point, you also know enough to perform a rewrite.
Thanks again!