CPU speed 40 MHz
This example shows the use of the 2D addressing mode on the LCD controller. It uses the TFT display on the STK1000 to show a part of the "virtual" framebuffer. The virtual frame buffer (640*480) is four times the size of the LCD viewing area (320*240). A bitmap picture (320*240) will read from the flash, enlarged by four and then written to the framebuffer. So you will only see a part of the picture on the screen. This viewing area can be moved around the "virtual" framebuffer with switches on the STK1000.
Before you run this application program the picture (AVR32.bmp) must be written into the flash at address 0x00400000. Use the avr32program application for this purpose. avr32program program -F bin -O 0x00400000 -evfcfi@0 AVR32.bmp If you intend to program the picture to another location change the define BITMAP_FILE_ADDRESS accordingly in the source. Feel free to use your own bitmap file.
The input (switches) header marked J25, used for moving around the virtual frame buffer, must be connected to the header labeled J1 (PORTB[0..7]).
To move the viewing area use following switches: Switch0: Move viewing area 10 pixels to the right Switch1: Move viewing area 10 pixels to the left Switch2: Move viewing area 10 lines up Switch3: Move viewing area 10 lines down