P2 7" LCD
David Betz
Posts: 14,516
I finally got my P2 Rev C eval board and case assembled and I ordered the 7" LCD at the same time. Isn't there demo software for this combination? Where can I find it?
Comments
Sounds like it comes with PNut version V.
https://forums.parallax.com/discussion/171196/pnut-spin2-latest-version-v34v-graphical-debugger/p1
Make sure you have a common ground with the power to the display.
The display is reported to take 400ma.
You've probably figured this out by now but my ANSI driver is for VGA, not HDMI, so I don't think it will work with the 7" LCD.
No, the one time I tried to use an HDMI sample I blew up my monitor . Not quite literally, but somehow it caused the monitor's HDMI and DVI ports to stop working; fortunately it still has VGA and DisplayPort. After that fiasco my enthusiasm for HDMI testing dimmed considerably!
I think most of Chip's samples should compile with fastspin, although I haven't tried all of them yet.
If you haven't blown it up you might be able to run my complex video driver demo with the output configured as DVI/HDMI instead of its default VGA. It is configured for 640x480 but it might still work on that display it if scales. Otherwise it might be possible to setup a native mode of 800x480 if the timing can be tweaked to fit the P2 and display's capabilities. If I had one of these monitors myself I'd have already tried that out.
My driver code is found in the first post of this thread:
https://forums.parallax.com/discussion/170676/p2-dvi-vga-driver
You will need to setup this line to your base pin on the P2-EVAL: and disable the VGA output type here by commenting this line and enable the DVI output type line here (note I think the commented out code had passed lineBuffer2 but it probably should be passing lineBuffer1 like the others, probably a bug)
Update: Note that code is still for Fastspin only. But the PNut driver updates are done and it already seems to work in PNut when I last tested it, I just need to add the release notes and update the top post with the newer version.
Chip seems to have added a new command for PASM which sets the clock frequency in PNUT. But Fastspin and also PropTool-Alpha don't know that command (asmclk).
This version sets the clockfreq the old way and also clears the memory aftr the code, which seems to be necessary.
Andy
Really? I've done a lot of crazy stuff but have not actually damaged a modern monitor...
I'm interested to know how low the TMDS clock could be for 800x480 with reduced blanking. The typical value seems to ~332 MHz without reduced blanking. I think these 800x480 HDMI displays also support 640x480 at standard timings but no other modes.
Just to be sure, when you powered the display was it via the supplied cable? Did you take note of the insert showing that with the supplied cable, +5v goes to the white wire, and ground goes to the red wire?
I found this data but it may not be the exact model and the AT070TN92 might be a generic name for many different panels (can't be sure there) but might be a reasonable start though. If it is valid it looks like it takes a 26.4-46.8MHz dot clock with a decently wide range of sync/blanking timing possible. This would be nice to try with a P2 at 264MHz or 270MHz perhaps, operating at the 10x pixel rate for DVI. It is quite easy to experiment with the timing in my driver to find what might work for native resolution. The Realtek(?) converter part may have some of its own timing constraints however, so maybe that can be looked up too.
https://www.olimex.com/Products/Retired/A13-LCD7-TS/resources/S700-AT070TN92.pdf
Ken Gracey
Let me know by e-mail if you want a replacement and I'll take care of that.
Early Adopters as yourself exhibit lots of patience, thanks!
Ken Gracey
Thanks for offering to replace my display. Let me try at least one more thing first. I'll try hooking it up to a bench supply in case maybe the P2 Eval board and the separate breadboard power supplies that I've tried can't supply enough current. If it still doesn't work, I'd be happy to have a replacement.
400ma current for the display is steep for some USB supplies. I'm using a Hub that has 2000ma output that feeds the AUX power on P2ES board and use the AUX 5 and GND on the P2 board.
- I powered the 5VDC to an external power source .
- I ensured that "_clkfreq = 250_000_000 'system clock frequency must be 250 MHz for HDMI"
- I just used the Pnut (version V) and the HDMI Spiral demo
'*****************
'* HDMI Spiral *
'*****************
CON hdmi_base = 48 'must be a multiple of 8
_clkfreq = 250_000_000 'system clock frequency must be 250 MHz for HDMI
fast = 1 '0 for small code (7.8 fps), 1 for fast code (36.6 fps)
bitmap = $400 'HDMI bitmap (300 KB)
DAT org
asmclk
coginit #1,##@pgm_hdmi 'launch HDMI
coginit #0,##@pgm_bmap 'launch bitmap cog
'*********************************
'* HDMI 640 x 480 x 8bpp rgbi8 *
'*********************************
Has anyone been able to tweak the timing to get native 800x480 with this panel from the P2 over HDMI yet? With any luck that is also going to be achievable, perhaps at something less than 60Hz or with other reduced blanking settings.
EDIT: looks like this was answered in the other P2 HDMI thread.
'************************************************************
'* VGA 640 x 480 x 16bpp 5:6:5 RGB - HDMI *
' Works Han 22, 2020 - HDMI Port - 5 Birds Picture
'***************************************************************
CON hdmi_base = 48
DAT org
'
'
' Setup
'
hubset ##%1_000001_0000011000_1111_10_00 'configure PLL, 20MHz/2*25*1 = 250MHz
waitx ##20_000_000 / 200 'allow crystal and PLL 5ms to stabilize
hubset ##%1_000001_0000011000_1111_10_11 'switch to PLL
rdfast ##640*350*2/64,##$1000 'set rdfast to wrap on bitmap
setxfrq ##$0CCCCCCC+1 'set transfer frequency to 1/10th clk, +1 for initial rollover
setcmod #$100 'enable HDMI
drvl #7<<6 + hdmi_base 'enable HDMI pins
'wrpin ##%10110_1111_1110_10_00000_0,#7<<6 + hdmi_base '123-ohm DAC needs 1-step diff
'wrpin ##%10110_0001_0000_10_00000_0,#7<<6 + hdmi_base '123-ohm DAC needs 1-step diff
'wrpin ##%10100_1111_1100_10_00000_0,#7<<6 + hdmi_base '990-ohm DAC needs 3-step diff
'wrpin ##%10100_0011_0000_10_00000_0,#7<<6 + hdmi_base '990-ohm DAC needs 3-step diff
wrpin ##%001001_00_00000_0,#7<<6 + hdmi_base '1k-ohm drive
'