TFT-LCD card for Blackfin BF537 STAMP board Targets MainBoard: BF537 STAMP (unknown if this card works with the BF537-EZKIT Lite). LCD type: LQ035Q7DB03 Interface: PPI (Parallel Peripheral Interface)(P8), Timers(P11) Schematics & BOM Hardware Setup STAMP Board Setup Set all switches of SW5 on BF537 stamp board to the OFF position Set SW4.1 and SW4.3 to OFF, and SW4.2 and SW4.4 on ON. LCD Board Setup To assemble the LCD Card, follow the following directions: Cover the resistor packs, so they do not get shorted out, when the LCD is laying on them. Connect the control cable of the LCD panel to the control socket (bit one) on the daughter board. Metal side faces up. Connect the back light cable of the LCD panel to the back light socket (small one) on the daughter board. Be careful closing the connectors. Tape both ends of the LCD to the card for mechanical stability. Normally the end with the cables is taped first. Connect the LCD daughter board to the PPI (Parallel Peripheral Interface) socket. Make sure that the LCD hangs off the end of the BF537 STAMP. Connect the 10-PIN (Personal Identification Number) cable to the timer connector on both BF537 stamp board and LCD daughter board. Pin 1 should be connect to pin 1 of both connectors. Switch S1.2, S1.3, S1.4 to off. S1.1 should be ON. This should provide a working QVGA LCD Card. Kernel Config The latest version of uClinux for Blackfin can be obtained from the Blackfin/uClinux website. The current kernel source supports all existing blackfin parts. Assume uClinux-dist is current directory, and user is cvshdr. cvshdr@colinux:~/uclinux/uClinux-dist$ make menuconfig A window will display, configure it as follows: Vendor/Product Selection ---> --- Select the Vendor you wish to target (AnalogDevices) Vendor --- Select the Product you wish to target (BF537-STAMP) AnalogDevices Products Kernel/Library/Defaults Selection ---> --- Kernel is linux-2.6.x (uClibc) Libc Version [ ] Default all settings (lose changes) [*] Customize Kernel Settings (NEW) [*] Customize Vendor/User Settings (NEW) [ ] Update Default Vendor Settings Exit and save the new kernel, and a new window will display. If some prompts display, just press 'ENTER'. The new window looks like: Make configurations as follows: Blackfin Processor Options ---> --- Processor and Board settings CPU (BF537) ---> Kernel is configured for (BF537-STAMP) ---> --- Cache Support [*] Enable 1M Uncached SDRAM region Device Drivers ---> I2C support ---> <*> I2C support I2C Hardware Bus support ---> Blackfin TWI I2C support Graphics support ---> <*> Support for frame buffer devices <*> SHARP LQ035 TFT LCD on uClinux (BF537 STAMP) [*] Backlight & LCD device support ---> --- Backlight & LCD device support <*> Lowlevel Backlight controls <*> Lowlevel LCD controls Exit and save configuration. Now another windows will display: This windows looks like: Make Microwindows configurations as follows: MicroWindows ---> [*] MicroWindows --- Libraries [*] Microwin (NEW) --- Demos [*] MicrowinDemo (NEW) --- Settings (Packed-16bit-5/6/5) Screeen PixType --- Mouse/Touch Screen [*] Serial Mouse --- Keyboard [*] No Keyboard Exit ans save the new configurations. Then: cvshdr@colinux:~/uclinux/uClinux-dist$ make Test Download the kernel image to BF537 STAMP board. If the video driver has been compiled as a module, you must install it. root:~> modprobe bf537-lq035 root:~> root:~> video_test The test curve will display on the LCD panel. Mouse The mouse will be connected to UART (universal asynchronous receiver/transmitter) 0. To use it, you need to disable the shell on that UART (universal asynchronous receiver/transmitter). Then use telnet as a shell. Disable the UART (universal asynchronous receiver/transmitter) shell enter the folder of uClinux-dist. cvshdr@colinux:~/uclinux/uClinux-dist$ make menuconfig Select: Kernel/Library/Defaults Selection ---> [*] Customize Vendor/User Settings (NEW) Exit and save, then you will see the Vendor/User configuration Dialog. Select: Core Applications ---> [*] init [ ] enable console shell Exit and save. Modify uClinux-dist/vendors/AnalogDevices/BF537-STAMP/rc, make sure it includes ifconfig eth0 up inetd & the ipaddr can be any address the user wants, for example: ifconfig eth0 up inetd & Type 'make' in folder “uClinux-dist” to rebuild the linux image cvshdr@colinux:~/uclinux/uClinux-dist$ make After the kernel bootup, use the telnet shell to control the system, for example, telnet The connection of mouse 537-stamp RS232 port mouse 2 ------------------ 3 3 ------------------ 2 5 ------------------ 5 7 -------- 5V power Because there are no RTS/CTS signals on the stamp board, the mouse will need external power on it's number 7 pin. (As a suggestion, you can use the UART1's pin 2 on stamp board as 5V power) Special Notes when using LCD card with SPI device Since Lq035 uses GPIO (General Purpose Input/Output) PF13 as UD signal, which conflicts with SPICLK. This will cause problem when using SPI (Serial Peripheral Interface) device like AD1836 sound card, AD7877 touch screen board, etc. We need to modify the board, by grounding the pin on the BF537-STAMP board that corresponds to the UD feed using a resistor (after cutting the UD lead) which drove the signal to zero. Also the Lq-035 driver need to be changed to disable “UD” setting (Comment out ”#define UD GPIO (General Purpose Input/Output)_PF13 /* Up / Down */”).