文件名称:STM32 OV2640 ESP8266图像传输
文件大小:29.97MB
文件格式:ZIP
更新时间:2022-05-06 04:23:38
STM32 OV2640 ESP826 图像传输 wifi
STM32 OV2640 ESP8266图像传输
int main()
{
u16 temp;
u8 *p;
u32 i,k;
u32 count,spi_send_len;
delay_init(168);
uart_init(115200);
printf("usart init.\r\n");
OV2640_Init();
DCMI_Config();
user_SPI_Config();
SPI1_SetSpeed(21);
printf("ov2640 init\r\n");
OV2640_JPEG_Mode();
OV2640_OutSize_Set(1600,1200);
DCMI_DMA_Init((u32)&frame;_data,JPEG_BUFF_LEN,DMA_MemoryDataSize_Word,DMA_MemoryInc_Enable);
DMA_Cmd(DMA2_Stream1,ENABLE);
DCMI_CaptureCmd(ENABLE);
printf("init success.\r\n");
delay_ms(1000);
GPIO_SetBits(GPIOB,GPIO_Pin_12);
while(1)
{
if(jpeg_ok==1)
{
printf("send...\r\n");
count=0;
wr_rdy=1;
p = (u8*)frame_data;
spi_send_len = jpeg_len/8; //byte-->word
spi_send_len+=1;
FRAME_START();//开始传输信号
for(k=0;k