00001 /* 00002 * $Id: gbcam.h,v 1.8 2002/12/02 20:19:18 dwalters Exp $ 00003 * 00004 * Copyright (C) 2001 Dafydd Walters 00005 * dwalters@users.sourceforge.net 00006 * 00007 * This library is distributed under the terms of the GNU Lesser General 00008 * Public License (LGPL). You should have received a copy of the 00009 * license along with this library (LGPL.txt); if not, write to 00010 * the Free Software Foundation, Inc., 59 Temple Place, Suite 330, 00011 * Boston, MA 02111-1307 USA 00012 */ 00013 00044 #ifndef __GBCAM_H__ 00045 #define __GBCAM_H__ 00046 00047 #include <68332/types.h> 00048 00049 #define gbcam_IMAGE_WIDTH 128 00050 #define gbcam_IMAGE_HEIGHT 123 00051 #define gbcam_IMAGE_SIZE (gbcam_IMAGE_WIDTH * gbcam_IMAGE_HEIGHT) 00052 00058 extern uint8 gbcam_imageBuffer[gbcam_IMAGE_SIZE]; 00059 00070 typedef struct _gbcam_RegistersType gbcam_RegistersType; 00071 00080 struct _gbcam_RegistersType 00081 { 00082 unsigned O : 6; 00083 unsigned Z : 2; 00084 unsigned G : 5; 00085 unsigned VH : 2; 00086 unsigned N : 1; 00087 unsigned C : 16; 00088 unsigned P : 8; 00089 unsigned M : 8; 00090 unsigned X : 8; 00091 unsigned V : 3; 00092 unsigned I : 1; 00093 unsigned E : 4; 00094 }; 00095 00131 extern gbcam_RegistersType gbcam_registers; 00132 00133 #ifdef __cplusplus 00134 extern "C" { 00135 #endif 00136 00137 00141 void gbcam_init(void); 00142 00153 void gbcam_exposure(void); 00154 00159 void gbcam_shoot(void); 00160 00161 00162 #ifdef __cplusplus 00163 } 00164 #endif 00165 00166 #endif /* __GBCAM_H__ */ 00167