Project 18 - A Still Photo Camera

<< Click to Display Table of Contents >>

Navigation:  Projects >

Project 18 - A Still Photo Camera

This project shows the usage of the built-in still camera using the command RecorderPreview(). Upon invoking this command, it gains control on full screen and provides the functionality of taking a photo using still camera. CleO35 supports three types of image resolutions, namely - Low (QVGA - 320 * 240), Medium (VGA - 640 * 480) and High (WVGA - 800 * 480).

 

 

Component(s)

 

This project uses the following component(s) -

 

CleO Camera

SD Card

 

 

Hardware Setup

 

The picture below shows a Camera connected to the CleO35 module.

 

Project 18A

 

 

Code

 

The following code shows how to use the Still Photo Camera function:

 

void setup() {

 /* Initialize CleO */

 CleO.begin();

}

 

void loop() {

 int16_t x, y, dur, tag;

 

 /* Start drawing preview message */

 CleO.Start();

 

 /* Draw message */

 CleO.StringExt(FONT_MEDIUM, 160, 240, LIGHT_GREEN, MM, 0, 0, "Video Preview");

 

 /* Display screen frame */

 CleO.Show();

 

 delay(1000);

 

 /* Display recoder */

 CleO.RecorderPreview();

}

 

 

Output

 

 

Project 19 Output

 

Use this control for switching to Camera mode.

 

Use this control for switching to Video mode.

 

Use this control to on/off the flash mode.

 

Use this control to select the Low (QVGA - 320 * 240) image resolution.

 

Use this control to choose the Medium (VGA - 640 * 480) image resolution.

 

Use this control to select the High (WVGA - 800 * 480) image resolution.

 

Use this control for capturing images.

 

Use this control to close the application.