kopia lustrzana https://github.com/DL7AD/pecanpico9
Fixed camera sampling bug
rodzic
955c33a2f8
commit
09c1ff92dc
|
@ -1111,9 +1111,9 @@ bool OV5640_Capture(uint8_t* buffer, uint32_t size)
|
|||
*/
|
||||
void OV5640_InitGPIO(void)
|
||||
{
|
||||
palSetLineMode(LINE_CAM_PCLK, PAL_MODE_ALTERNATE(3));
|
||||
palSetLineMode(LINE_CAM_PCLK, PAL_MODE_ALTERNATE(3) | PAL_STM32_OSPEED_HIGHEST);
|
||||
palSetLineMode(LINE_CAM_VSYNC, PAL_MODE_INPUT_PULLUP | PAL_STM32_OSPEED_HIGHEST);
|
||||
palSetLineMode(LINE_CAM_XCLK, PAL_MODE_ALTERNATE(0));
|
||||
palSetLineMode(LINE_CAM_XCLK, PAL_MODE_ALTERNATE(0) | PAL_STM32_OSPEED_HIGHEST);
|
||||
palSetLineMode(LINE_CAM_D2, PAL_MODE_INPUT_PULLUP | PAL_STM32_OSPEED_HIGHEST);
|
||||
palSetLineMode(LINE_CAM_D3, PAL_MODE_INPUT_PULLUP | PAL_STM32_OSPEED_HIGHEST);
|
||||
palSetLineMode(LINE_CAM_D4, PAL_MODE_INPUT_PULLUP | PAL_STM32_OSPEED_HIGHEST);
|
||||
|
|
|
@ -48,12 +48,12 @@
|
|||
#define STM32_PLLSRC STM32_PLLSRC_HSI
|
||||
#define STM32_PLLM_VALUE 16
|
||||
#define STM32_PLLN_VALUE 192
|
||||
#define STM32_PLLP_VALUE 2
|
||||
#define STM32_PLLP_VALUE 4
|
||||
#define STM32_PLLQ_VALUE 4
|
||||
#if ACTIVATE_USB /* Activate 48MHz when USB is activated, otherwise 6MHz */
|
||||
#define STM32_HPRE STM32_HPRE_DIV1
|
||||
#define STM32_HPRE STM32_HPRE_DIV2
|
||||
#else
|
||||
#define STM32_HPRE STM32_HPRE_DIV1
|
||||
#define STM32_HPRE STM32_HPRE_DIV2
|
||||
#endif
|
||||
#define STM32_PPRE1 STM32_PPRE1_DIV2
|
||||
#define STM32_PPRE2 STM32_PPRE2_DIV2
|
||||
|
|
Ładowanie…
Reference in New Issue