I want to interface my OV7670 camera (without FIFO) to my Arduino Uno. I have browsed internet quite a lot about it and found people either saying it's not possible or they just give me the link to this github repository (As this guy has done exactly what I want). As the author of this repository is a man of few words, he did not help me very much. I just want to know how to use this to get image sent to my PC serially. I only know how to use Arduino IDE in windows platform and no other platform.

  • rename main.c to <project-name>.ino, and change int main(void){ to void loop(void){
    – Gerben
    Apr 18, 2015 at 8:58
  • Hello, I did exactly that and now it shows this error. sketch_apr17a.cpp.o: In function loop': H:\arduino-1.0.3_1/sketch_apr17a.ino:122: undefined reference to camInit()' H:\arduino-1.0.3_1/sketch_apr17a.ino:124: undefined reference to setRes(unsigned char)' H:\arduino-1.0.3_1/sketch_apr17a.ino:125: undefined reference to setColor(unsigned char)' H:\arduino-1.0.3_1/sketch_apr17a.ino:126: undefined reference to wrReg(unsigned char, unsigned char)' core.a(main.cpp.o): In function main': H:\arduino-1.0.3_1\hardware\arduino\cores\arduino/main.cpp:11: undefined reference to `setup'
    – Arpit
    Apr 18, 2015 at 12:38
  • Apply the fix in stackoverflow.com/a/21276414 to 0v7670.h
    – Gerben
    Apr 18, 2015 at 20:19
  • Hey, gerben. What I did is just changed the name of the main.c to <sketchname>.ino and copied the content of ov7670.c to that sketch and compiled and it compiled succefully. All I want to know is, can I do it this way?
    – Arpit
    Apr 19, 2015 at 4:57

3 Answers 3


I am ComputerNerd. I read this post and realized the real problem and why I am having difficulty helping you. You are asking the wrong question. What you should be asking is "how do I compile it using GNU Make and Avr-Gcc on Windows?". Instead you are asking "how can I use this code in the Arduino IDE?".

The answer to what you should be asking is simple. Use what you already have. The Arduino IDE ships with Avr-gcc and (maybe) GNU Make. Just run the programs directly. Better yet download MinGW and compile GCC to target the AVR yourself.

  • Thanks ComputerNerd, I was not able to ask more technically right question but I anyway got the solution about running your code in Arduino IDE.
    – Arpit
    Apr 19, 2015 at 19:02

ComputerNerds work is good, but it is has only code and limited description. I have prepared detailed instruction using his code. You can try it: How to use OV7670 and Arduino uno


I have successfully compiled the project in arduino IDE, simply concatenated main.c and ov7670.c ov7670.h into .ino file

didn't test it with the camera yet, but it uploaded to my arduino (Duemilanove) Tell me if it worked for you...

see here: https://github.com/eranws/ov7670-no-ram-arduino-uno

Not the answer you're looking for? Browse other questions tagged or ask your own question.