How to Get Frame?(OV2640 - arducam mini 2mp - stm32)

1.Which seller did you purchase the product(s) from?
distributor
2.The Model number of the product(s) you have purchased?
Arducam mini 2mp , Rev.B
3.Which Platform are you using the product(s) on?
cubeIDE ( stm 32F7 board)
4.Which instruction are you following?
online documentation or arduino example
5.Has your product ever worked properly?
Never worked,First Attempting
6.What problems are you experiencing?
SPI, I2C communication connection confirmed.

but No 0xD8 & 0xFF were found when reading the data after the capture command.

Where should I check?

flush_fifo();
clear_fifo_flag();
start_capture();
Starting = false;

HAL_GPIO_TogglePin(GPIOI, GPIO_PIN_8);
if(check_fifo_done())
{
GrabJpegFrame();
}

void GrabJpegFrame(){

bool is_header = false;
uint32_t length =0;
uint8_t send=0x00;
uint8_t temp=0, temp_last = 0;

length = Read_FIFO_Length();

if((length >= MAX_FIFO_SIZE) | (length == 0))
{
return false;
}
fifo_size = length;

int nCnt = 0;
CS_LOW();
set_fifo_burst();

HAL_SPI_Transmit(&hspi2, (uint8_t*)&send, 1, 10);
HAL_Delay(10);

HAL_SPI_Receive(&hspi2, (uint8_t*)&temp, 1, 10);
HAL_Delay(10);

length–;

while(length–)
{
temp_last = temp;
HAL_SPI_Transmit(&hspi2, (uint8_t*)&send, 1, 10);
//HAL_Delay(10);

HAL_SPI_Receive(&hspi2, (uint8_t*)&temp, 1, 10);
//HAL_Delay(10);

if(is_header == true)
{
send_data[nCnt++] = temp;
HAL_GPIO_TogglePin(GPIOB, GPIO_PIN_7);

}
else if((temp == 0xD8) & (temp_last == 0xFF)){
is_header = true;
send_data[nCnt] = temp_last;
nCnt++;
send_data[nCnt] = temp;
}

if((temp==0xD9) && (temp_last == 0xFF))
{
HAL_GPIO_TogglePin(GPIOH, GPIO_PIN_4);
break;
}
MX_LWIP_Process();
HAL_Delay(10);

}

CS_HIGH();
clear_fifo_flag();

is_header = false;
return true;

}
7.What attempts at troubleshooting have you already made?
spi and i2c command and datasheet check
8.How would you like us to help you?
I want to check the captured data. I’d like a guide.

Hi,

We currently do not have an example on STM32F7, you can refer to our example of using SPI camera on stm32F1.

Link:https://github.com/ArduCAM/STM32