The tcDspQvga16 class provides access to a 16-bit color QVGA (320x240 pixel) display device. It is derived from the tcDspDisplayDriver base class to provide a consistent interface to the underlying frame buffer. Additional functions to set and get the display backlighting are provided. An instance of the tcDspFpgaDma class must be provided to exchange data with the device. This driver in turn may be used to setup direct access to the device's frame buffer, or may be used in conjunction with the tcDisplay class.
A flag is provided to allow use with portrait or landscape devices.
This is a simple example of tcDspQvga16 creation and usage:
#define DISPLAY_DMA_BASE 0xB0000400 #define QVGA_DISPLAY_BASE 0xB0000480 { tcDspFpgaDma *mpDisplayDma; tcDspQvga16 *mpQvgaDisplay; // instantiate the interface to the FPGA DMA controller mpDisplayDma = new tcDspFpgaDma((void *)DISPLAY_DMA_BASE); // create interface to QVGA display, and provide DMA access and channel mpQvgaDisplay = new tcDspQvga16((void *)QVGA_DISPLAY_BASE, mpDisplayDma, tcDspFpgaDma::eeChannel1); // Usually used in conjunction with tcDspDisplay, see this class // for example usage... ... }