⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 s3c2440a_camif.h

📁 linux下cmos摄像头驱动模块
💻 H
字号:
#ifndef _VIDEODEV_S3C2440_H_#define _VIDEODEV_S3C2440_H_#include <linux/videodev.h>#define CAM_CLK_DIV	(0) // 0:24M, 1:12M, 2:8M, 3:6M, 5:4M, 11:2M#define MAX_OPENS 1#define MAX_NUM_FRAMES	15#define CAMIF_MAX_W 800#define CAMIF_MAX_H 625#define CAMIF_MIN_W 160#define CAMIF_MIN_H 120struct img_buf_t {	unsigned int phys_addr;	unsigned char *buf;};struct s3c2440_camif {	struct video_device	v;	spinlock_t			lock;	struct semaphore	change;	struct completion	stop;	int					open_count;	wait_queue_head_t	wait;	unsigned long		time_acquired;/* millisecond time stamp */	int set_chg;	int mode;	int flag;	int rdy;	unsigned long size;};struct s3c2440_camif_cfg_t {	int src_x;	int src_y;#if 1	int dst_x;	int dst_y;	int dst_fmt;	int pre_x;	int pre_y;	int pre_fmt;	__u16 bypass;	__u16 ycbcr;#endif	struct s3c2440_camif *dev;};//Camera Interface.  Edited for 2440A         //#define S3C2440_VA_CAMIF_T  (unsigned long)ioremap((unsigned long)0x4f000000,0XA0);#define S3C2440_CAMREG(x) (unsigned long)ioremap((x) + 0x4f000000,4)                     #define rCISRCFMT           S3C2440_CAMREG(0x0)        #define rCIWDOFST           S3C2440_CAMREG(0x4)        #define rCIGCTRL            S3C2440_CAMREG(0x8)       #define rCICOYSA1           S3C2440_CAMREG(0x18)#define rCICOYSA2           S3C2440_CAMREG(0x1C)#define rCICOYSA3           S3C2440_CAMREG(0x20)        #define rCICOYSA4           S3C2440_CAMREG(0x24)        #define rCICOCBSA1          S3C2440_CAMREG(0x28)        #define rCICOCBSA2          S3C2440_CAMREG(0x2C)        #define rCICOCBSA3          S3C2440_CAMREG(0x30)        #define rCICOCBSA4          S3C2440_CAMREG(0x34)#define rCICOCRSA1          S3C2440_CAMREG(0x38)#define rCICOCRSA2          S3C2440_CAMREG(0x3C)#define rCICOCRSA3          S3C2440_CAMREG(0x40)#define rCICOCRSA4          S3C2440_CAMREG(0x44)#define rCICOTRGFMT         S3C2440_CAMREG(0x48)#define rCICOCTRL           S3C2440_CAMREG(0x4C)        #define rCICOSCPRERATIO     S3C2440_CAMREG(0x50)        #define rCICOSCPREDST       S3C2440_CAMREG(0x54)#define rCICOSCCTRL         S3C2440_CAMREG(0x58)#define rCICOTAREA          S3C2440_CAMREG(0x5C)#define rCICOSTATUS         S3C2440_CAMREG(0x64)#define rCIPRCLRSA1         S3C2440_CAMREG(0x6C)#define rCIPRCLRSA2         S3C2440_CAMREG(0x70)#define rCIPRCLRSA3         S3C2440_CAMREG(0x74)        #define rCIPRCLRSA4         S3C2440_CAMREG(0x78)        #define rCIPRTRGFMT         S3C2440_CAMREG(0x7C)        #define rCIPRCTRL           S3C2440_CAMREG(0x80)        #define rCIPRSCPRERATIO     S3C2440_CAMREG(0x84)        #define rCIPRSCPREDST       S3C2440_CAMREG(0x88)        #define rCIPRSCCTRL         S3C2440_CAMREG(0x8C)        #define rCIPRTAREA          S3C2440_CAMREG(0x90)#define rCIPRSTATUS         S3C2440_CAMREG(0x98)#define rCIIMGCPT           S3C2440_CAMREG(0xA0)#define	CICOSTAY(i)			S3C2440_CAMREG(0x18+(i)*4)#define	CICOSTACb(i)		S3C2440_CAMREG(0x28+(i)*4)#define	CICOSTACr(i)		S3C2440_CAMREG(0x38+(i)*4)#define	CIPRSTARGB(i)		S3C2440_CAMREG(0x6C+(i)*4)#define	STILL_IMAGE			1#define	VIDEO_START			0#define	VIDEO_STOP			-1#endif /* _VIDEODEV_S3C2440_H_ */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -