(I'm working from the MotionDetect example.)
Code: Select all
//cam.setImageSize(VC0706_640x480); // biggest
//cam.setImageSize(VC0706_320x240); // medium
cam.setImageSize(VC0706_160x120); // small
// You can read the size back from the camera (optional, but maybe useful?)
uint8_t imgsize = cam.getImageSize();
Serial.print("Image size: ");
if (imgsize == VC0706_640x480) Serial.println("640x480");
if (imgsize == VC0706_320x240) Serial.println("320x240");
if (imgsize == VC0706_160x120) Serial.println("160x120");
Serial.println(imgsize);
I commented out the code that checks the image size and got another surprise - I can't set the camera to motion capture mode unless I call cam.getImageSize() first. I'm thinking I have a module that doesn't quite conform to the expectations of the camera library.