Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of JPEGCamera by
JPEGCamera Class Reference
Interface for LinkSprite JPEG Camera module LS-Y201. More...
#include <JPEGCamera.h>
Public Member Functions | |
JPEGCamera (PinName tx, PinName rx) | |
Create JPEG Camera. | |
bool | setPictureSize (JPEGCamera::PictureSize size, bool doReset=true) |
Set picture size. | |
bool | isReady () |
Return whether camera is ready or not. | |
bool | isProcessing () |
Return whether camera is processing the taken picture or not. | |
bool | takePicture (char *filename) |
Take a picture. | |
bool | processPicture () |
Process picture (writing the file) | |
bool | reset () |
Perform reset oepration (it takes 4 seconds) | |
bool | takePicture (void) |
Send a picture command to the camera module. | |
bool | stopPictures (void) |
Send a stop pictures command to the camera module. | |
int | getImageSize () |
Get the picture image size. | |
int | readData (char *dataBuf, int size, int address) |
Read the picture data to the buffer. |
Detailed Description
Interface for LinkSprite JPEG Camera module LS-Y201.
Definition at line 16 of file JPEGCamera.h.
Constructor & Destructor Documentation
JPEGCamera | ( | PinName | tx, |
PinName | rx | ||
) |
Member Function Documentation
int getImageSize | ( | ) |
Get the picture image size.
- Returns:
- the actual image size in bytes
Definition at line 134 of file JPEGCamera.cpp.
bool isProcessing | ( | ) |
Return whether camera is processing the taken picture or not.
- Returns:
- true if the camera is in processing, false otherwise
Definition at line 36 of file JPEGCamera.cpp.
bool isReady | ( | ) |
Return whether camera is ready or not.
- Returns:
- true if ready, false otherwise
Definition at line 32 of file JPEGCamera.cpp.
bool processPicture | ( | ) |
Process picture (writing the file)
- Returns:
- true if no error in processing, false otherwise
Definition at line 84 of file JPEGCamera.cpp.
int readData | ( | char * | dataBuf, |
int | size, | ||
int | address | ||
) |
Read the picture data to the buffer.
- Parameters:
-
dataBuf data buffer address to store the received data size data size to read address the address of the picture data to read
- Returns:
- the size of the data read
Definition at line 142 of file JPEGCamera.cpp.
bool reset | ( | ) |
Perform reset oepration (it takes 4 seconds)
- Returns:
- true if succeeded, false otherwise
Definition at line 104 of file JPEGCamera.cpp.
bool setPictureSize | ( | JPEGCamera::PictureSize | size, |
bool | doReset = true |
||
) |
Set picture size.
- Parameters:
-
size picture size (available sizes are SIZE160x120, SIZE320x240, SIZE640x480) doReset flag to perform reset operation after changing size
- Returns:
- true if succeeded, false otherwise
Definition at line 20 of file JPEGCamera.cpp.
bool stopPictures | ( | void | ) |
Send a stop pictures command to the camera module.
- Returns:
- true if succeeded, false otherwise
Definition at line 123 of file JPEGCamera.cpp.
bool takePicture | ( | char * | filename ) |
Take a picture.
- Parameters:
-
filename filename to store the picture data
- Returns:
- true if succeeded, false otherwise
Definition at line 61 of file JPEGCamera.cpp.
bool takePicture | ( | void | ) |
Send a picture command to the camera module.
- Returns:
- true if succeeded, false otherwise
Definition at line 116 of file JPEGCamera.cpp.
Generated on Sat Jul 16 2022 18:04:22 by
