1.23.14.7 ICAPx_CaptureBufferRead Function

C

/* x = ICAP instance number */

uint32_t ICAPx_CaptureBufferRead (void)

Summary

This function will return the value contained in the ICAPx peripheral buffer. Based on the selected C32 capture, the return type will be uint16_t for 16 bit mode or uint32_t for 32 bit mode. Refer the generated header file for the actual function signature.

Description

This function will return the value contained in the ICAPx peripheral buffer.

Precondition

ICAPx_Initialize() function must have been called first.

Parameters

None.

Returns

uint32_t - Captured value from ICAPx peripheral buffer.

Example

uint32_t captureBuffer = 0;
ICAP1_Enable();
captureBuffer = ICAP1_CaptureBufferRead();

Remarks

Based on C32 capture select return type will be uint16_t for 16 bit mode.