资源简介
linux ov5640驱动源码 driver
代码片段和文件信息
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include “ov5640.h“
#define ov5640_CHIP_ID_H (0x56)
#define ov5640_CHIP_ID_L (0x40)
#define SXGA_WIDTH 1280
#define SXGA_HEIGHT 960
#define MAX_WIDTH 2560
#define MAX_HEIGHT 1920
#define MAX_PREVIEW_WIDTH SXGA_WIDTH
#define MAX_PREVIEW_HEIGHT SXGA_HEIGHT
#define OV5640_REG_END 0xffff
#define OV5640_REG_DELAY 0xfffe
#define OV5640_REG_VAL_PREVIEW 0xff
#define OV5640_REG_VAL_SNAPSHOT 0xfe
struct ov5640_format_struct;
struct ov5640_info {
struct v4l2_subdev sd;
struct ov5640_format_struct *fmt;
struct ov5640_win_size *win;
unsigned short vts_address1;
unsigned short vts_address2;
int frame_rate;
int binning;
};
struct regval_list {
unsigned short reg_num;
unsigned char value;
};
struct otp_struct {
unsigned int customer_id;
unsigned int module_integrator_id;
unsigned int lens_id;
unsigned int rg_ratio;
unsigned int bg_ratio;
unsigned int user_data[5];
};
static struct regval_list ov5640_init_regs[] = {
{0x3103 0x11}//SCCB system control
{0x3008 0x82}//software reset
{0x3008 0x42}//software power down
{0x3103 0x03}//SCCB system control
{0x3017 0x00}//set Frex Vsync Href PCLK D[9:6] input
{0x3018 0x00}//set d[5:0] GPIO[1:0] input
{0x3034 0x1a}//MIPI 10-bit mode
{0x3035 0x12}//System clock dividerScale divider for MIPI
{0x3036 0x69}//PLL multiplier(4~252)
{0x3037 0x13}//PLL root divider
{0x3108 0x01}//system divider
{0x3630 0x36}
{0x3631 0x0e}
{0x3632 0xe2}
{0x3633 0x12}
{0x3621 0xe0}
{0x3704 0xa0}
{0x3703 0x5a}
{0x3715 0x78}
{0x3717 0x01}
{0x370b 0x60}
{0x3705 0x1a}
{0x3905 0x02}
{0x3906 0x10}
{0x3901 0x0a}
{0x3731 0x12}
{0x3600 0x08}//VCM debug mode
{0x3601 0x33}//VCM debug mode
{0x302d 0x60}//system control
{0x3620 0x52}
{0x371b 0x20}
{0x471c 0x50}
{0x3a13 0x43}//AGC pre-gain0x40=1x
{0x3a18 0x00}//gain ceiling
{0x3a19 0xf8}//gain ceiling
{0x3635 0x13}
{0x3636 0x03}
{0x3634 0x40}
{0x3622 0x01}
{0x3c01 0x34}//50/60Hz
{0x3c04 0x28}// threshold for low sum
{0x3c05 0x98}// threshold for high sum
{0x3c06 0x00}// light meter 1 threshold high
{0x3c07 0x07}// light meter 1 threshold
{0x3c08 0x00}// light meter 2 threshold high
{0x3c09 0x1c}// light meter 2 threshold low
{0x3c0a 0x9c}// sample number high
{0x3c0b 0x40}// sample number low
{0x3820 0x40}//ISP flip off sensor flip off
{0x3821 0x00}//mirror
{0x3814 0x11}//timing: X inc
{0x3815 0x11}//Y inc
{0x3800 0x00}//image windowing configuration: HS
{0x3801 0x00}//HS
{0x3802 0x00}//VS
{0x3803 0x00}//VS
{0x3804 0x0a}//X Address End: HW:2623
{0x3805 0x3f}//HW
{0x3806 0x07}//Y Address End: VH:1951
{
相关资源
- Scratch源码
- E4A无障碍跨程序操作类库(带源码、
- 设备管理系统源码
- 安卓wifi直连app源码
- 我的世界源码(易语言版)
- labview编程软件滤波器以及编写程序设
- 我的界面(visual foxpro)源码
- 易语言:一键cf基址源码
- The Secret Path 3D 3D魔方迷宫[源码][scra
- scratch垃圾分类源码(最终版本).sb
- uboot到linux logo显示不间断 补丁
- 安卓QQ6.71协议源码易语言,qq协议源码
- 编译原理实验工具及参考源码(lex&
- E盾偷后台工具源码
- UNIX/LINUX编程实践教程的源码
- 十以内加减法练习 powerbuilder源码
- Linux任务管理器
- linux应用层的华容道游戏源代码
- 农场开发项目
- OCR源码
- PLC上位机编程软件
- 用foobar2000听google音乐[更新一下]
- 学生信息管理系统源码
- 用VC 编写的仿QQ聊天室程序源代码
- 毕业论文之温度传感器DS18B20(源码
- 可自定义导航网站源码
- 栅栏填充算法源码(VC)
- msp430F149操作红外接收模块源码
- [免费]图像识别c 源码
- 周易排盘源码
评论
共有 条评论