Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Black screen #6

Open
Mr-Julien opened this issue Apr 23, 2015 · 27 comments
Open

Black screen #6

Mr-Julien opened this issue Apr 23, 2015 · 27 comments

Comments

@Mr-Julien
Copy link

Hello,
I succeed at uploading your program to my Arduino Uno using in the main.c #define useQqvga but when after I use your simpleFrameGrabber-master program with the bash qqvga, I end up with a black screen. Do you know what am I doing wrong ?
Thank you a lot.

Sincerly

@ComputerNerd
Copy link
Owner

What does the frame grabber print? Does the orange led blink fast?

Also I know this may sound like stating the obvious but make sure you remove the lens cap when using the OV7670. I am just saying this on the off chance that you forgot to remove it.

@Mr-Julien
Copy link
Author

The frame grabber print: 160 120 1 4101 0, and yes the orange led blink fast.
My lens cap was removed but yes it could have been the reason of a black screen !
An idea of the problem ?
Thank you for your concern.

@ComputerNerd
Copy link
Owner

It is a connection problem. The orange LED should not be blinking. I make the LED blink when there is an i2c error. Make sure you have pullup resistors to 3.3v on SIO_C and SIO_D and try again. Also did you see that I forgot to add two connections? See my latest commit and more specifically the changes I have made to README.

@Mr-Julien
Copy link
Author

it is still not working, I think I did all of it correctly except that I converted 5V to 2.5V for XCLK, I will monday buy some new resistors to be able to be more accurate, Perhaps this is the reason of my problems. Here my wiring: http://oi60.tinypic.com/nb9mvl.jpg

@ComputerNerd
Copy link
Owner

You need to wire both RESET and PWDN otherwise i2c will not work. Also you need to wire D0-D7 to get an image.

@Mr-Julien
Copy link
Author

Yes I wired everything, I just didn't do it on the image because it would have been unreadable.
I wired on the image only the 3 pins that need a resistor because I wasn't sure I did it correctly.
PS: the only pin that I didn't use, is the HREF pin because you don't refer to it in the README, should I use it ?

@ComputerNerd
Copy link
Owner

No

@Mr-Julien
Copy link
Author

I wired everything, and used the appropriate resistors, but my led is still blinking and my screen still black. What am I doing wrong ? The only 2 pins that need pull up resistor are SIOC and SIOD ?

@ComputerNerd
Copy link
Owner

Yes. Make sure that you are reading the latest version of the README file.

@Mr-Julien
Copy link
Author

I did, could it be an informatic mistake. Here what I do:
I change in main.c #define useQqvga
and change nothing else even in the makefile.
Then ( I am on Ubuntu ):
cd /home/.../ov7670-no-ram-arduino-uno-master
make
make disasm
make stats
make hex
make writeflash
make clean
cd /home/.../simpleFrameGrabber-master
bash build
bash qqvga
Am I doing something wrong ?

@ComputerNerd
Copy link
Owner

I doubt that is the cause. It is your connections.

@simon0356
Copy link

I begin a fritzing file presenting the connection for ov7670-no-ram-arduino-uno, because i'm more software developper than electronicians and I think that i'm not alone in my case ^^, i juste have no time to finish it but maybe today. i will shared to you.
I personaly destroy 3 ov7670 when trying to make it work ( I2C resitor too small or tension divider), i think this repository is the more able to make it work

@Mr-Julien
Copy link
Author

Here my wiring: http://oi59.tinypic.com/2nai554.jpg
What am I doing wrong ?
If it's good, I may be destroyed the camera ?
Anyway, if my wiring is good, feel free to use it as an example.

@simon0356
Copy link

What software did you use ?

@Mr-Julien
Copy link
Author

For the drawing ? Proteus Isis
For the camera I used Arduino-mk I think.

@simon0356
Copy link

It's something like Proteus Isis that i search , i don't success to get something good on Fritzing.

Anyway i think your wiring is good and correspond to updated readme Mr-Julien is there a way to get your mail ? i don't see the the informations on your profile and i don't want to post more comment that not correspond to the topic here

@Mr-Julien
Copy link
Author

sure, if we can help each other : [email protected]

@ComputerNerd
Copy link
Owner

I admit to doing a few foolish things regarding incorrect wiring that may lead one to suspect damage to the sensor however my OV7670 camera module still works. What am not sure about in regards to your schematic is the resistor divider. The reason for this is that there may be lots of noise. Please verify this with an oscilloscope before drawing a conclusions.

@simon0356
Copy link

I will use that kind of regulator for my next OV7670 : http://boutique.semageek.com/fr/251-powerpod-1117-3v3.html

@Mr-Julien
Copy link
Author

I did some test, and my camera still works. If it still works and there is no wiring mistakes, it must be a programming issue. Any idea of what could it be ?

@simon0356
Copy link

How did you test ?

@Mr-Julien
Copy link
Author

I applied a 10 MHz clock on XCLK and when PCLK is rising I sample D0-D7 and read it on the serial port, and it is seems to respond correctly.
Here what I did: https://github.com/Mr-Julien/OV7670/blob/master/OV7670.ino
Could you help me deal with SCCB ?

@Mr-Julien
Copy link
Author

I found out my mistake: http://i60.tinypic.com/cs4zb.jpg
But know I have some thing like that: http://i61.tinypic.com/24ydcgi.png
And I use the adapted color space and serial speed for qqvga, I don't understand...

@Mr-Julien
Copy link
Author

Do you know what I can do to improve the quality ?

@juan-negron
Copy link

Mr-Julien, I try to test your code, you program run? how is the conection???

@themathgeek13
Copy link

@Mr-Julien - I am getting a similar green noisy image from the camera. Did you find the solution to this problem?

@TodorGinchev
Copy link

The reason of the black screen can also be the register 0x11 which controls the pixel clock divider. Your XCLK is 8MHz, but the with the divider you transform the pixel clock in lower frequency, because generating 8MHz clock and sampling data a 8MHz with the Arduino Uno while sending it via UART looks pretty impossible to me.

So I think you should try different values for the register 0x11 (actually @ComputerNerd has already implemented a loop that tries different values, you only have to uncomment it).

But still, I am using a digital analyzer and yet not able to change the clock divider via SCCB, I always see 8MHz clock at XCLK and 8MHz clock at PCLK where I expect 4MHz, 2MHz,...

Regards.
Todor.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants