mirror of
https://github.com/openmv/openmv.git
synced 2025-11-04 14:49:50 +08:00
Lower pixel clock frequency to 54MHz
* Lower pixel clock frequency to be within the DCMI specs (max 54MHz)
This commit is contained in:
parent
3461e93fdf
commit
0ffb74df7a
@ -24,7 +24,7 @@
|
|||||||
|
|
||||||
#define OV9650_PID 0x96
|
#define OV9650_PID 0x96
|
||||||
#define OV2640_PID 0x26
|
#define OV2640_PID 0x26
|
||||||
#define XCLK_FREQ (12000000)
|
#define XCLK_FREQ (13000000)
|
||||||
#define BREAK() __asm__ volatile ("BKPT")
|
#define BREAK() __asm__ volatile ("BKPT")
|
||||||
|
|
||||||
struct sensor_dev sensor;
|
struct sensor_dev sensor;
|
||||||
@ -174,13 +174,18 @@ int sensor_init()
|
|||||||
SCCB_Init();
|
SCCB_Init();
|
||||||
systick_sleep(10);
|
systick_sleep(10);
|
||||||
|
|
||||||
/* Configure the external clock (XCLK) */
|
/* Configure the sensor external clock (XCLK) to XCLK_FREQ (13MHz).
|
||||||
#ifdef OPENMV1
|
Note: The sensor's internal PLL (when CLKRC=0x80) doubles the XCLK_FREQ
|
||||||
|
(XCLK=XCLK_FREQ*2), and the unscaled PIXCLK output is XCLK_FREQ*4 */
|
||||||
extclk_config(XCLK_FREQ);
|
extclk_config(XCLK_FREQ);
|
||||||
#else
|
|
||||||
(void) extclk_config;
|
/* Uncomment this to pass through the MCO1 clock (HSI=16MHz) this results in a
|
||||||
HAL_RCC_MCOConfig(RCC_MCO1, RCC_MCO1SOURCE_HSI, RCC_MCODIV_1);
|
64MHz PIXCLK output from the sensor.
|
||||||
#endif
|
Note: The maximum pixel clock input on the STM32F4xx is 54MHz,
|
||||||
|
the STM32F7 can probably handle higher input pixel clock.
|
||||||
|
*/
|
||||||
|
//(void) extclk_config;
|
||||||
|
//HAL_RCC_MCOConfig(RCC_MCO1, RCC_MCO1SOURCE_HSI, RCC_MCODIV_1);
|
||||||
|
|
||||||
/* Reset the sesnor state */
|
/* Reset the sesnor state */
|
||||||
memset(&sensor, 0, sizeof(struct sensor_dev));
|
memset(&sensor, 0, sizeof(struct sensor_dev));
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user