Lower M4 sensor clock.

* Add PLL config to board to fine tune M4 sensor clock.
* Note M4 sensor clock is lowered, the MCU can't keep up with high FPS.
This commit is contained in:
iabdalkader 2017-09-13 23:46:00 +02:00
parent 0cf13e8777
commit 260479ae0f
3 changed files with 9 additions and 2 deletions

View File

@ -21,7 +21,10 @@
#define OMV_XCLK_SOURCE (OMV_XCLK_TIM)
// Sensor external clock timer frequency.
#define OMV_XCLK_FREQUENCY (5000000)
#define OMV_XCLK_FREQUENCY (6000000)
// Sensor PLL register value.
#define OMV_OV7725_PLL_CONFIG (0x41) // x4
// Have built-in RGB->LAB table.
#define OMV_HAVE_LAB_TABLE

View File

@ -23,6 +23,9 @@
// Sensor external clock timer frequency.
#define OMV_XCLK_FREQUENCY (9000000)
// Sensor PLL register value.
#define OMV_OV7725_PLL_CONFIG (0x81) // x6
// Have built-in RGB->LAB table.
#define OMV_HAVE_LAB_TABLE

View File

@ -14,12 +14,13 @@
#include "ov7725.h"
#include "systick.h"
#include "ov7725_regs.h"
#include "omv_boardconfig.h"
static const uint8_t default_regs[][2] = {
{COM3, COM3_SWAP_YUV},
{COM7, COM7_RES_VGA | COM7_FMT_RGB565 | COM7_FMT_RGB},
{COM4, 0x81}, /* PLL x6 */
{COM4, OMV_OV7725_PLL_CONFIG},
{CLKRC, 0xC0}, /* Res/Bypass pre-scalar */
// VGA Window Size