M480 BSP V3.05.006
The Board Support Package for M480 Series
Macros | Functions

Macros

#define CCAP_IS_STOPPED()
 Is CCAP module Enable. More...
 
#define CCAP_CLR_INT_FLAG(u32IntMask)
 Clear CCAP flag. More...
 
#define CCAP_GET_INT_STS()
 Get CCAP Interrupt status. More...
 

Functions

void CCAP_Open (uint32_t u32InFormat, uint32_t u32OutFormet)
 Open engine clock and sensor clock. More...
 
void CCAP_SetCroppingWindow (uint32_t u32VStart, uint32_t u32HStart, uint32_t u32Height, uint32_t u32Width)
 Set Cropping Window Starting Address and Size. More...
 
void CCAP_SetPacketBuf (uint32_t u32Address)
 Set System Memory Packet Base Address0 Register. More...
 
void CCAP_Close (void)
 Close Camera Capture Interface. More...
 
void CCAP_EnableInt (uint32_t u32IntMask)
 Set CCAP Interrupt. More...
 
void CCAP_DisableInt (uint32_t u32IntMask)
 Disable CCAP Interrupt. More...
 
void CCAP_Start (void)
 Start Camera Capture Interface. More...
 
void CCAP_Stop (uint32_t u32FrameComplete)
 Stop Camera Capture Interface. More...
 
void CCAP_SetPacketScaling (uint32_t u32VNumerator, uint32_t u32VDenominator, uint32_t u32HNumerator, uint32_t u32HDenominator)
 Set Packet Scaling Vertical and Horizontal Factor Register. More...
 
void CCAP_SetPacketStride (uint32_t u32Stride)
 Set Packet Frame Output Pixel Stride Width. More...
 
void CCAP_EnableMono (uint32_t u32Interface)
 Enable Monochrome CMOS Sensor. More...
 
void CCAP_DisableMono (void)
 Disable Monochrome CMOS Sensor. More...
 
void CCAP_EnableLumaYOne (uint32_t u32th)
 Enable Luminance 8-bit Y to 1-bit Y Conversion. More...
 
void CCAP_DisableLumaYOne (void)
 Disable Luminance 8-bit Y to 1-bit Y Conversion. More...
 

Detailed Description

Macro Definition Documentation

◆ CCAP_CLR_INT_FLAG

#define CCAP_CLR_INT_FLAG (   u32IntMask)

Clear CCAP flag.

Parameters
[in]u32IntMaskinterrupt flags settings. It could be
Returns
TRUE(Enable) or FALSE(Disable)

Clear Image Capture Interface interrupt flag

Definition at line 125 of file ccap.h.

◆ CCAP_GET_INT_STS

#define CCAP_GET_INT_STS ( )

Get CCAP Interrupt status.

Returns
TRUE(Enable) or FALSE(Disable)

Get Image Capture Interface interrupt status.

Definition at line 135 of file ccap.h.

◆ CCAP_IS_STOPPED

#define CCAP_IS_STOPPED ( )

Is CCAP module Enable.

Returns
FALSE(Enable) or TRUE(Disable)

Check Camera Capture Interface module Enable or Disable

Definition at line 109 of file ccap.h.

Function Documentation

◆ CCAP_Close()

void CCAP_Close ( void  )

Close Camera Capture Interface.

Returns
None

Definition at line 110 of file ccap.c.

◆ CCAP_DisableInt()

void CCAP_DisableInt ( uint32_t  u32IntMask)

Disable CCAP Interrupt.

Parameters
[in]u32IntMaskInterrupt settings. It could be
Returns
None

Disable Video Frame End Interrupt , System Memory Error Interrupt , Address Match Interrupt and Motion Detection Output Finish Interrupt .

Definition at line 151 of file ccap.c.

◆ CCAP_DisableLumaYOne()

void CCAP_DisableLumaYOne ( void  )

Disable Luminance 8-bit Y to 1-bit Y Conversion.

Returns
None

Definition at line 202 of file ccap.c.

◆ CCAP_DisableMono()

void CCAP_DisableMono ( void  )

Disable Monochrome CMOS Sensor.

Returns
None

Definition at line 177 of file ccap.c.

◆ CCAP_EnableInt()

void CCAP_EnableInt ( uint32_t  u32IntMask)

Set CCAP Interrupt.

Parameters
[in]u32IntMaskInterrupt settings. It could be
Returns
None

Set Video Frame End Interrupt Enable, System Memory Error Interrupt Enable, Address Match Interrupt Enable, Motion Detection Output Finish Interrupt Enable.

Definition at line 130 of file ccap.c.

◆ CCAP_EnableLumaYOne()

void CCAP_EnableLumaYOne ( uint32_t  u32th)

Enable Luminance 8-bit Y to 1-bit Y Conversion.

Parameters
[in]u32thLuminance Y8 to Y1 Threshold Value, It should be 0 ~ 255.
Returns
None

Definition at line 190 of file ccap.c.

◆ CCAP_EnableMono()

void CCAP_EnableMono ( uint32_t  u32Interface)

Enable Monochrome CMOS Sensor.

Parameters
[in]u32InterfaceI/O interface settings. It could be
Returns
None

Definition at line 166 of file ccap.c.

◆ CCAP_Open()

void CCAP_Open ( uint32_t  u32InFormat,
uint32_t  u32OutFormet 
)

Open engine clock and sensor clock.

Parameters
[in]u32InFormatThe bits corresponding VSP, HSP, PCLK, INFMT, SNRTYPE, OUTFMT, PDORD and PNFMT configurations.
[in]u32OutFormetCapture output format, should be one of following setting
Returns
None

Initialize the Image Capture Interface. Register a call back for driver internal using

Definition at line 59 of file ccap.c.

◆ CCAP_SetCroppingWindow()

void CCAP_SetCroppingWindow ( uint32_t  u32VStart,
uint32_t  u32HStart,
uint32_t  u32Height,
uint32_t  u32Width 
)

Set Cropping Window Starting Address and Size.

Parameters
[in]u32VStartCropping Window Vertical Starting Address. It should be 0 ~ 0x7FF.
[in]u32HStartCropping Window Horizontal Starting Address. It should be 0 ~ 0x7FF.
[in]u32HeightCropping Window Height . It should be 0 ~ 0x7FF.
[in]u32WidthCropping Window Width. It should be 0 ~ 0x7FF.
Returns
None

Set Cropping Window Starting Address Register

Definition at line 80 of file ccap.c.

◆ CCAP_SetPacketBuf()

void CCAP_SetPacketBuf ( uint32_t  u32Address)

Set System Memory Packet Base Address0 Register.

Parameters
[in]u32Address: set PKTBA0 register, It should be 0x0 ~ 0xFFFFFFFF
Returns
None

Set System Memory Packet Base Address Register

Definition at line 99 of file ccap.c.

◆ CCAP_SetPacketScaling()

void CCAP_SetPacketScaling ( uint32_t  u32VNumerator,
uint32_t  u32VDenominator,
uint32_t  u32HNumerator,
uint32_t  u32HDenominator 
)

Set Packet Scaling Vertical and Horizontal Factor Register.

Parameters
[in]u32VNumeratorPacket Scaling Vertical Factor N. It should be 0 ~ FFFF.
[in]u32VDenominatorPacket Scaling Vertical Factor M. It should be 0 ~ FFFF.
[in]u32HNumeratorPacket Scaling Vertical Factor N. It should be 0 ~ FFFF.
[in]u32HDenominatorPacket Scaling Vertical Factor M. It should be 0 ~ FFFF.
Returns
None

Definition at line 264 of file ccap.c.

◆ CCAP_SetPacketStride()

void CCAP_SetPacketStride ( uint32_t  u32Stride)

Set Packet Frame Output Pixel Stride Width.

Parameters
[in]u32Stride: set PKTSTRIDE register, It should be 0x0 ~ 0x3FFF
Returns
None

Set Packet Frame Output Pixel Stride Width

Definition at line 297 of file ccap.c.

◆ CCAP_Start()

void CCAP_Start ( void  )

Start Camera Capture Interface.

Returns
None

Definition at line 212 of file ccap.c.

◆ CCAP_Stop()

void CCAP_Stop ( uint32_t  u32FrameComplete)

Stop Camera Capture Interface.

Parameters
[in]u32FrameComplete: TRUE: Capture module automatically disable the CCAP module after a frame had been captured FALSE: Stop Capture module now
Returns
None

if u32FrameComplete is set to TRUE then get a new frame and disable CCAP module.

Note
This function sets g_CCAP_i32ErrCode to CCAP_TIMEOUT_ERR if the CCAP_IS_STOPPED() longer than expected.

Definition at line 229 of file ccap.c.