lcdc.h

Go to the documentation of this file.
00001 /*This file has been prepared for Doxygen automatic documentation generation.*/
00022 /* Copyright (c) 2006, Atmel Corporation All rights reserved.
00023  *
00024  * Redistribution and use in source and binary forms, with or without
00025  * modification, are permitted provided that the following conditions are met:
00026  *
00027  * 1. Redistributions of source code must retain the above copyright notice,
00028  * this list of conditions and the following disclaimer.
00029  *
00030  * 2. Redistributions in binary form must reproduce the above copyright notice,
00031  * this list of conditions and the following disclaimer in the documentation
00032  * and/or other materials provided with the distribution.
00033  *
00034  * 3. The name of ATMEL may not be used to endorse or promote products derived
00035  * from this software without specific prior written permission.
00036  *
00037  * THIS SOFTWARE IS PROVIDED BY ATMEL ``AS IS'' AND ANY EXPRESS OR IMPLIED
00038  * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
00039  * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE EXPRESSLY AND
00040  * SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT,
00041  * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
00042  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
00043  * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
00044  * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
00045  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
00046  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
00047  */
00048 
00049 #ifndef _AVR32_LCDC_H_
00050 #define _AVR32_LCDC_H_
00051 
00052 #ifdef __GNUC__
00053 #include <avr32/io.h>
00054 #elif __ICCAVR32__
00055 #include <avr32/ioap7000.h>
00056 #else
00057 #error No known compiler used
00058 #endif
00059 
00062 typedef struct lcdc_configuration_s {
00064         unsigned int dmabaddr1; 
00066         unsigned int dmabaddr2; 
00068         unsigned char burst_length;  
00070         unsigned short  xres;
00072         unsigned short  yres;
00073         
00080         unsigned char set2dmode;
00081         
00085         unsigned int virtual_xres;
00086         
00090         unsigned int virtual_yres;
00091         
00093         unsigned short frame_rate;
00094         
00099         unsigned int lcdcclock;
00100         
00102         unsigned short guard_time;  
00103         
00104         /* LCD configuration register 2 */
00110         unsigned char   memor;
00111         
00117         unsigned char   ifwidth;
00122         unsigned char   scanmod;
00128         unsigned char   distype;
00133         unsigned char   invvd;
00134         
00139         unsigned char   invframe;
00140         
00145         unsigned char   invline;
00150         unsigned char   invclk;
00151         
00156         unsigned char invdval;
00157         
00162         unsigned char   clkmod;
00163         
00173         unsigned char pixelsize;
00174         
00179         unsigned char ctrstval;
00180         
00188         unsigned char ctrst_ps;
00189         
00197         unsigned char ctrst_pol;
00198         
00203         unsigned char ctrst_ena;
00204         
00210         unsigned char mmode;
00211         
00217         unsigned char mval;
00218          
00222         unsigned short  hpw;
00223         
00227         unsigned char hbp;              /* Wait before of line */
00228         
00232         unsigned char   hfp;            /* Wait end of line */
00233 
00238         unsigned char   vpw;
00239         
00243         unsigned char   vbp;            /* Wait before of frame */
00244         
00248         unsigned char   vfp;            /* Wait end of frame */
00249         
00254         unsigned char vhdly;
00255 
00256 } lcdc_conf_t;
00257 
00258 #define STN_MONO 0
00259 #define STN_COLOR 1
00260 #define TFT 2
00261 
00262 #define SINGLE_SCAN 0
00263 #define DUAL_SCAN 1
00264 
00265 #define IF_WIDTH4 0
00266 #define IF_WIDTH8 1
00267 #define IF_WIDTH16 2
00268 
00269 #define BIG_ENDIAN 0
00270 #define LITTLE_ENDIAN 1
00271 #define WIN_CE 2
00272 
00273 #define MODE_2D_ON 1
00274 #define MODE_2D_OFF 0
00275 
00276 #define BPP_1 1
00277 #define BPP_2 2
00278 #define BPP_4 4
00279 #define BPP_8 8
00280 #define BPP_16 16
00281 #define BPP_24 24
00282 #define BPP_32 32
00283 
00284 #define NORMAL 0
00285 #define INVERTED 1
00286 
00287 #define ENABLED 1
00288 #define DISABLED 0
00289 
00290 #define PRE_NONE 0
00291 #define PRE_HALF 1
00292 #define PRE_FOURTH 2
00293 #define PRE_EIGTH 3
00294 
00295 #define PARTLY_ACTIVE 0
00296 #define ALWAYS_ACTIVE 1
00297 
00298 #define EACH_FRAME 0
00299 #define MVAL_DEFINED 1
00300 
00310 int lcdc_init (lcdc_conf_t* lcdc_conf);
00311 
00312 #endif // _AVR32_LCDC_H_

Generated on Wed May 7 16:03:16 2008 for AVR32114 Using the AVR32 LCD Controller by  doxygen 1.5.3-20071008