Home

C329-SPI User Manual

image

Contents

1. 128x96 OAh 128x128 OBh 160x128 C329 SPI CO UM EN 20141014 RH TecSys GmbH e Karl Theodor Str 55 e D 80803 M nchen e Tel 49 89 321 990 0 e www tecsys de GET PIC FFFFFFO4h Picture Type Picture Type Description Oih Snapshot Picture 02h Preview Picture 03h Serial Flash Picture 05h Compression Preview Picture 06h Playback Picture SNAPSHOT FFFFFFO5h The host sends this command to ask OV529 to capture a still image Snapshot Type must be 0 in order to be compatible with OV528 RESET FFFFFFO8h Reset All means a reset of the whole system including registers and state machines uC will be rebooted Reset State Machine means a reset of some state machines only When the last byte of Reset command is FFh the OV529 must stop the current job and perform this Reset command immediately Reset Type Reset Type Description 00h Reset All Oih Reset State Machine POWER OFF FFFFFFO9h The host sends this command to suspend OV529 DATA FFFFFFOAh The C329 sends this command to pass the length of the stored image The following kinds of data must be preceded by Data command to provide the data length information Length byte 0 is Least Significant Byte LSB and Length byte 2 is Most Significant byte MSB Data Type Data Type Description 00h Register Data Oth Snapshot Picture 02h RGB YUV Preview Picture 04h Compression Preview Picture 05h Pla
2. 0 e www tecsys de Program EEPROM A Serial EEPROM provides the program code that gives the OV529 it s interface and command set Board Layout Top View Bottom View Figure 2 C329 SPI board Layout and Serial Interface SPI Interface Timing Options and CLK The SPI interface consists of MOSI Master Out Slave In MISO Master In Slave Out CLK and CS In the OV529 there is the addition of HOLD which when H indicates to the Master that the OV529 isn t ready and should hold off the next transaction The CS signal allows multiple devices to be attached to the SPI bus When CS is L the OV529 is selected Data on MISO will be clocked out on the falling edge of CLK and data on MOSI will be clocked in on the rising edge of CLK It is possible to select both clock edges this will require a hardware change that must be ordered specifically It is recommended to use the above scenario if at all possible C329 SPI CO UM EN 20141014 RH TecSys GmbH e Karl Theodor Str 55 e D 80803 M nchen e Tel 49 89 321 990 0 e www tecsys de ka Le cs e o E si _ on LI CE EEN i mso f f jf mur YO Bits KT og A A mm KT pe LH Wm ax Hu BR H 1 MOSI A KEKE A x Bit M7 a PA x Bit af A E Bits XO X E Bit K SS BD unit ne Min Typ Max Description ti 200 Chip enable setup time D 10 12 MISO hold time D 12 Chip enable hold time
3. C329 SPI User Manual Release Note V1 0 27 September 2010First release V1 1 12 January 2012 Second release C329 SPI CO UM EN 20141014 RH TecSys GmbH e Karl Theodor Str 55 e D 80803 M nchen e Tel 49 89 321 990 0 e www tecsys de General Description The C329 is a colour VGA camera module which performs JPEG compression and can be attached to a host via an SPl interface Users can send a Snapshot command from the host in order to capture an image The image is then compressed by the host and stored in and internal buffer and transferred to the host through the SPI port EEPROM C329 Camera Module Program Figure 1 System Block Diagram Features Small Size 20x28mm Adjustable resolution resolution Max VGA 3 3V operation Low Power consumption 64mA active SPI Interface with Hold Power Saving Mode Multiple lens options Multiple interface options UART version available System Configuration Camera Sensor The C329 uses a 1 4 OmniVision VGA sensor with an 8 bit YcbCr interface and 3 8 V Lux Sec sensitivity OV529 Serial Bridge The OV529 Serial bridge contains an Embedded JPEC CODEC and controller chip that can compress and transfer image data from the Camera Sensor to an external device The OV529 performs all imaging functions like white balance downsizing and compressed image storage C329 SPI CO UM EN 20141014 RH TecSys GmbH e Karl Theodor Str 55 e D 80803 M nchen e Tel 49 89 321 990
4. H 12 Mosi setup Time 6 12 MOOSI hold time Figure 3 SPI Timing Command Set The C329 SPI module supports the following commands Command CmdToken Parameter 1 Parameter 2 Parameter 3 Parameter 4 INITIAL FFFFFFO1h 00h Colour Type Preview Res Compres Res GET PIC FFFFFFO4h Pic Type 00h 00h 00h SNAPSHOT FFFFFFO5h Snapshot Type 00h 00h 00h RESET FFFFFFO8h Reset Type 00h 00h 00 FFh POWER OFF FFFFFFO9h 00h 00h 00h 00h DATA FFFFFFOAh Data Type Length Byte 0 Length Byte 1 Length Byte 2 SYNC FFFFFFODh 00h 00h 00h 00h ACK FFFFFFOEh Cmd Token ACK counter 00h 00h NAK FFFFFFOFh 00h NAK counter Err Number 00h QUALITY FFFFFF10h Quality Level 00h 00h 00h C329 SPI CO UM EN 20141014 RH TecSys GmbH e Karl Theodor Str 55 e D 80803 M nchen e Tel 49 89 321 990 0 e www tecsys de INITIAL FFFFFF01h Colour Type Colour Type Description 02h Y4 03h Y8 05h RGB12 06h RGB16 08h RGB24 09h YUV16 07h Compression Preview Resolution Preview Resolution Description oih 80x60 02h 88x72 03h 160x120 04h 176x144 05h 320x240 06h 352x288 07h 640x480 08h 80x64 09h 128x96 OAh 128x128 OBh 160x128 Compression Resolution Compression Resolution Description oih 80x60 02h 88x72 03h 160x120 04h 176x144 05h 320x240 06h 352x288 87h 640x480 08h 80x64 09h
5. an embedded system Establish communication as above Send command INIT FFFFFF0100870107h GET ACK FFFFFFOE01nn0000h Send command SELECT IMAGE QUALITY FFFFFF1000000000h GET ACK FFFFFFOE10nn0000h Send command GET PICTURE FFFFFF0405000000h GET ACK FFFFFFOE04nn0000h GET ACK FFFFFFOAnnLOL1L2h GET Image Data C329 SPI CO UM EN 20141014 RH TecSys GmbH e Karl Theodor Str 55 e D 80803 M nchen e Tel 49 89 321 990 0 e www tecsys de
6. uires around 1 2 second for firmware load from EEPROM and system wake up SYNC The Remote System sends a SYNC command and awaits and ACK the C329 then sends out it s own SYNC and the Remote system is expected to respond with an ACK as shown below GJE Commands The Follovving commands respond vvith ACK INITIAL RESET SNAPSHOT POVVER OFF and SELECT IMAGE QUALITY as shown below C329 SPI CO UM EN 20141014 RH TecSys GmbH e Karl Theodor Str 55 e D 80803 M nchen e Tel 49 89 321 990 0 e www tecsys de COMMAND C329 SPI CO UM EN 20141014 RH TecSys GmbH e Karl Theodor Str 55 e D 80803 M nchen e Tel 49 89 321 990 0 e www tecsys de GET PICTURE Send Image Data C329 SPI CO UM EN 20141014 RH TecSys GmbH e Karl Theodor Str 55 e D 80803 M nchen e Tel 49 89 321 990 0 e www tecsys de Code Implementation Here is an example of how to SYNC with the C329 e Send Get SYNC command FFFFFFODO0000000h Wait 25ms Did we get ACK FFFFFFOEODnn0000h If NO repeat above command up to 60 times Did we get SYNC If NO repeat above Send ACK command Here is an example of how to establish communication with the C329 for the first time e Set Remote Baud Rate to 14 400 bps e Get SYNC e Change C329 Baud Rate with command FFFFFF0100870107h e Set Remote Baud Rate to new BAUD 921 600 in this example e Get SYNC Here is an example of the commands required to quickly capture and transfer an image form the C329 to
7. yback Picture C329 SPI CO UM EN 20141014 RH TecSys GmbH e Karl Theodor Str 55 e D 80803 M nchen e Tel 49 89 321 990 0 e www tecsys de Length Image Length len 0 Len 1 100h Len 2 10000h SYNC FFFFFFODh The host sends this command to start a synchronization sequence ACK FFFFFFOEh This command is a handshake command to indicate that previous transaction was succeeded Command ID The received command ID ACK Counter The host and OV529 maintain their own ACK counters After transmitting an ACK command this counter will be increased by 1 NAK FFFFFFOFh This command is a handshake command which indicates corrupted transmissions or unsupported features NAK Counter The host and OV529 maintain their own NAK counters After transmitting an NAK command this counter will be increased by 1 Error Number The error condition number QUALITY FFFFFF10h The host sends this command to select image quality level Image quality level only effects Compression related images No influence on image of bypass mode Quality Level Quality Level Description 00h Best Oih Better 02h Normal C329 SPI CO UM EN 20141014 RH TecSys GmbH e Karl Theodor Str 55 e D 80803 M nchen e Tel 49 89 321 990 0 e www tecsys de Command Implementation Power On amp Power Off OV529 camera system requires around 1 second from power off to next power on After power on the camera req

Download Pdf Manuals

image

Related Search

Related Contents

Copyright © All rights reserved.
Failed to retrieve file