ArduCAM / Arduino

This is ArduCAM library for Arduino boards
MIT License
473 stars 349 forks source link

OV2640 Mini 2MP / UNO cannot detect camera #384

Open DarrelYee opened 5 years ago

DarrelYee commented 5 years ago

Hello, and Happy New Year!

I got an OV2640 Mini 2MP a while back and just plugged it into my UNO. I followed the instructions on the knowledge base, and opened ArduCAM_Host_V2. It tells me that the COM port is opened but no initialization of SPI or detection of the ArduCAM. See below:

ardu

My connections are correct, I've triple checked them. See below:

0c3b7edd-5eda-4f9d-9efa-cb5d1a2ae097 7629b1c4-2b7f-47e7-9f05-198fc2ce5055

I'm using the ArduCAM_Mini_2MP_OV2640_functions file as instructed. Is there a way to check if the program is detecting my Arducam correctly? Not sure if i'm doing something wrong or my arducam is faulty.

DarrelYee commented 5 years ago

Attached more pictures of my connections for clarity:

563a84c1-0e2c-48e6-af64-ab75a9b9c22a 73beb241-2468-4a15-8b2f-514a67aaf00c

DarrelYee commented 5 years ago

I ran ArduCAM_Mini_2MP_OV2640_functions on the IDE and only got this:

ACK CMD ArduCAM Start! END
ACK CMD SPI interface OK. END
ACK CMD OV2640 detected. END

So I guess the SPI and camera are detected. But I'm still not getting any response from ArduCAM_Host_V2.

UCTRONICS commented 5 years ago

@wangmasterX Are the serial port number and baud rate right?

DarrelYee commented 5 years ago

Yes, i'm only using one COM port so it can't be wrong. As you can see in the picture I set my baud rate to 921600, which appears to be the same as the Serial.begin() in the code. On the arduino serial monitor I used 1000000 baud which was the closest option.

UCTRONICS commented 5 years ago

@wangmasterX It is due to the baud rate. Please ensure your crystal oscillator is 16MHZ

DarrelYee commented 5 years ago

Im using an Uno clone, but my crystal oscillator IS 16MHz, unless you're referring to another oscillator. I have attached an image to show you:

daca7dfa-c4b5-4716-ae9e-85e8c769e784

The program was able to serial print at 921600 baud rate, so i'm not sure baud rate is the issue here. And even if its wrong, I should be receiving some garbage data, but i see nothing.

elvinosmanov commented 5 years ago

Did you find the solution of this problem?

UCTRONICS commented 5 years ago

Have you tried to set the baud rate to 115200?For some pc, the current of the usb port is low, which can't support high speed baud rate,please try to modify the baud rate ih the code.

UCTRONICS commented 5 years ago

What's more, I advise you use short cable line, if the cable line is too long, it will effect the signal of image data.