vtc
Vitis Drivers API Documentation
xvtc.h File Reference

Data Structures

struct  XVtc_Config
 This typedef contains configuration information for a VTC core. More...
 
struct  XVtc_Polarity
 This typedef contains Polarity configuration information for a VTC core. More...
 
struct  XVtc_SourceSelect
 This typedef contains Source Selection configuration information for a VTC core. More...
 
struct  XVtc_Signal
 This typedef contains the VTC signal configuration used by the Generator/Detector modules in a VTC device. More...
 
struct  XVtc_HoriOffsets
 This typedef contains Detector/Generator VBlank/VSync Horizontal Offset configuration information for a VTC device. More...
 
struct  XVtc_Timing
 This typedef contains Timing (typically in Display Timing) format configuration information for the VTC core. More...
 
struct  XVtc
 The XVtc driver instance data. More...
 

Macros

#define XVTC_H_
 Prevent circular inclusions by using protection macros. More...
 
#define XVtc_Reset(InstancePtr)
 This function macro resets the VTC core. More...
 
#define XVtc_SyncReset(InstancePtr)
 This function macro resets the VTC core after the next input frame is complete. More...
 
#define XVtc_EnableSync(InstancePtr)
 This function macro enables synchronization of the Generator with the Detector on the given VTC core. More...
 
#define XVtc_RegUpdateEnable(InstancePtr)
 This function macro enables updating timing registers at the end of each Generator frame. More...
 
#define XVtc_RegUpdateDisable(InstancePtr)
 This function macro disables updating timing registers at the end of each Generator frame. More...
 
#define XVtc_DisableSync(InstancePtr)
 This function macro disables synchronization of the Generator with the Detector on the given VTC core. More...
 
#define XVtc_GetDetectionStatus(InstancePtr)   XVtc_ReadReg((InstancePtr)->Config.BaseAddress, (XVTC_DTSTAT_OFFSET))
 This function macro gets the status of the Detector in the VTC core. More...
 
#define XVtc_IntrEnable(InstancePtr, IntrType)
 This function macro enables individual interrupts of the VTC core by updating the IRQ_ENABLE register. More...
 
#define XVtc_IntrDisable(InstancePtr, IntrType)
 This function macro disables individual interrupts of the VTC core by updating the IRQ_ENABLE register. More...
 
#define XVtc_StatusGetPending(InstancePtr)
 This function macro returns the pending interrupt status of the VTC core read from the Status register. More...
 
#define XVtc_IntrGetPending(InstancePtr)
 This function macro returns the pending interrupts of the VTC core for the interrupts that have been enabled. More...
 
#define XVtc_IntrClear(InstancePtr, IntrType)
 This function macro clears/acknowledges pending interrupts of the VTC core in the Status register. More...
 
#define XVtc_Sync_Reset   XVtc_SyncReset
 This function macro resets the VTC core after the next input frame is complete. More...
 
Interrupt Types for setting up Callbacks
#define XVTC_HANDLER_FRAMESYNC   1
 A frame sync event interrupt type. More...
 
#define XVTC_HANDLER_LOCK   2
 A signal lock event interrupt type. More...
 
#define XVTC_HANDLER_DETECTOR   3
 A detector event interrupt type. More...
 
#define XVTC_HANDLER_GENERATOR   4
 A generator event interrupt type. More...
 
#define XVTC_HANDLER_ERROR   5
 An error condition interrupt type. More...
 
Options for enabling VTC modules
#define XVTC_EN_GENERATOR   1
 To enable generator. More...
 
#define XVTC_EN_DETECTOR   2
 To enable detector. More...
 
Address gap between two register next to each other
#define XVTC_REG_ADDRGAP   4
 Register address gap. More...
 
#define XVTC_VMODE_720P   1
 Video mode 720P. More...
 
#define XVTC_VMODE_1080P   2
 Video mode 1080P. More...
 
#define XVTC_VMODE_480P   3
 Video mode 480P. More...
 
#define XVTC_VMODE_576P   4
 Video mode 576P. More...
 
#define XVTC_VMODE_VGA   5
 Video mode VGA. More...
 
#define XVTC_VMODE_SVGA   6
 Video mode SVGA. More...
 
#define XVTC_VMODE_XGA   7
 Video mode XGA. More...
 
#define XVTC_VMODE_SXGA   8
 Video mode SXGA. More...
 
#define XVTC_VMODE_WXGAPLUS   9
 Video mode WXGAPlus. More...
 
#define XVTC_VMODE_WSXGAPLUS   10
 Video mode WSXGAPlus. More...
 
#define XVTC_VMODE_1080I   100
 Video mode 1080I. More...
 
#define XVTC_VMODE_NTSC   101
 Video mode NTSC. More...
 
#define XVTC_VMODE_PAL   102
 Video mode PAL. More...
 
Compatibility Macros
#define XVtc_RegUpdate   XVtc_RegUpdateEnable
 

Typedefs

typedef void(* XVtc_CallBack )(void *CallBackRef, u32 Mask)
 Callback type for all interrupts except error interrupt. More...
 
typedef void(* XVtc_ErrorCallBack )(void *CallBackRef, u32 ErrorMask)
 Callback type for Error interrupt. More...
 

Functions

int XVtc_CfgInitialize (XVtc *InstancePtr, XVtc_Config *CfgPtr, UINTPTR EffectiveAddr)
 This function initializes the VTC core. More...
 
void XVtc_EnableGenerator (XVtc *InstancePtr)
 This function enables the VTC Generator core. More...
 
void XVtc_EnableDetector (XVtc *InstancePtr)
 This function enables the VTC Detector core. More...
 
void XVtc_Enable (XVtc *InstancePtr)
 This function enables the Detector and Generator at same time of the VTC core. More...
 
void XVtc_DisableGenerator (XVtc *InstancePtr)
 This function disables the VTC Generator core. More...
 
void XVtc_DisableDetector (XVtc *InstancePtr)
 This function disables the VTC Detector core. More...
 
void XVtc_Disable (XVtc *InstancePtr)
 This function disables the Detector and Generator at same time of the VTC core. More...
 
void XVtc_ConvVideoMode2Timing (XVtc *InstancePtr, u16 Mode, XVtc_Timing *TimingPtr)
 This function converts the video mode integer into the video timing information stored within the XVtc_Timing pointer. More...
 
void XVtc_ConvTiming2Signal (XVtc *InstancePtr, XVtc_Timing *TimingPtr, XVtc_Signal *SignalCfgPtr, XVtc_HoriOffsets *HOffPtr, XVtc_Polarity *PolarityPtr)
 This function converts the video timing structure into the VTC signal configuration structure, horizontal offsets structure and the polarity structure. More...
 
void XVtc_ConvSignal2Timing (XVtc *InstancePtr, XVtc_Signal *SignalCfgPtr, XVtc_HoriOffsets *HOffPtr, XVtc_Polarity *PolarityPtr, XVtc_Timing *TimingPtr)
 This function converts the VTC signal structure, horizontal offsets structure and the polarity structure into the Video Timing structure. More...
 
u16 XVtc_ConvTiming2VideoMode (XVtc *InstancePtr, XVtc_Timing *TimingPtr)
 This function converts the video timing structure into predefined video mode values returned as a short integer. More...
 
void XVtc_SetGeneratorTiming (XVtc *InstancePtr, XVtc_Timing *TimingPtr)
 This function sets up the generator (Polarity, H/V values and horizontal offsets) by reading the configuration from a video timing structure. More...
 
void XVtc_SetGeneratorVideoMode (XVtc *InstancePtr, u16 Mode)
 This function sets up the generator (Polarity, H/V values and horizontal offsets) by reading the configuration from a video mode short integer. More...
 
void XVtc_GetGeneratorTiming (XVtc *InstancePtr, XVtc_Timing *TimingPtr)
 This function gets the video timing structure settings currently used by generator in the VTC core. More...
 
u16 XVtc_GetGeneratorVideoMode (XVtc *InstancePtr)
 This function gets the video mode currently used by the generator in the VTC core. More...
 
void XVtc_GetDetectorTiming (XVtc *InstancePtr, XVtc_Timing *TimingPtr)
 This function gets the video timing structure settings currently reported by the detector in the VTC core. More...
 
u16 XVtc_GetDetectorVideoMode (XVtc *InstancePtr)
 This function gets the video mode currently reported by the detector in the VTC core. More...
 
void XVtc_SetPolarity (XVtc *InstancePtr, XVtc_Polarity *PolarityPtr)
 This function sets up the output polarity of the VTC core. More...
 
void XVtc_GetPolarity (XVtc *InstancePtr, XVtc_Polarity *PolarityPtr)
 This function gets the output polarity setting used by the VTC core. More...
 
void XVtc_GetDetectorPolarity (XVtc *InstancePtr, XVtc_Polarity *PolarityPtr)
 This function gets the input polarity setting used by the VTC core. More...
 
void XVtc_SetSource (XVtc *InstancePtr, XVtc_SourceSelect *SourcePtr)
 This function sets up the source selecting of the VTC core. More...
 
void XVtc_GetSource (XVtc *InstancePtr, XVtc_SourceSelect *SourcePtr)
 This function gets the source select setting used by the VTC core. More...
 
void XVtc_SetSkipLine (XVtc *InstancePtr, int GeneratorChromaSkip)
 This function sets up the line skip setting of the Generator in the VTC core. More...
 
void XVtc_GetSkipLine (XVtc *InstancePtr, int *GeneratorChromaSkipPtr)
 This function gets the line skip setting used by the Generator in the VTC core. More...
 
void XVtc_SetSkipPixel (XVtc *InstancePtr, int GeneratorChromaSkip)
 This function sets up the pixel skip setting of the Generator in the VTC core. More...
 
void XVtc_GetSkipPixel (XVtc *InstancePtr, int *GeneratorChromaSkipPtr)
 This function gets the pixel skip setting used by the Generator in the VTC core. More...
 
void XVtc_SetGenerator (XVtc *InstancePtr, XVtc_Signal *SignalCfgPtr)
 This function sets up VTC signal to be used by the Generator module in the VTC core. More...
 
void XVtc_GetGenerator (XVtc *InstancePtr, XVtc_Signal *SignalCfgPtr)
 This function gets the VTC signal setting used by the Generator module in the VTC core. More...
 
void XVtc_GetDetector (XVtc *InstancePtr, XVtc_Signal *SignalCfgPtr)
 This function gets the VTC signal setting used by the Detector module in the VTC core. More...
 
void XVtc_SetDelay (XVtc *InstancePtr, int VertDelay, int HoriDelay)
 This function sets up the Generator delay setting of the VTC core. More...
 
void XVtc_GetDelay (XVtc *InstancePtr, int *VertDelayPtr, int *HoriDelayPtr)
 This function gets the Generator delay setting used by the VTC core. More...
 
void XVtc_SetFSync (XVtc *InstancePtr, u16 FrameSyncIndex, u16 VertStart, u16 HoriStart)
 This function sets up the SYNC setting of a frame sync used by the VTC core. More...
 
void XVtc_GetFSync (XVtc *InstancePtr, u16 FrameSyncIndex, u16 *VertStartPtr, u16 *HoriStartPtr)
 This function gets the SYNC setting of a frame sync used by the VTC core. More...
 
void XVtc_SetGeneratorHoriOffset (XVtc *InstancePtr, XVtc_HoriOffsets *HoriOffsets)
 This function sets the VBlank/VSync Horizontal Offsets for the Generator in a VTC device. More...
 
void XVtc_GetGeneratorHoriOffset (XVtc *InstancePtr, XVtc_HoriOffsets *HoriOffsets)
 This function gets the VBlank/VSync Horizontal Offsets currently used by the Generator in the VTC core. More...
 
void XVtc_GetDetectorHoriOffset (XVtc *InstancePtr, XVtc_HoriOffsets *HoriOffsets)
 This function gets the VBlank/VSync Horizontal Offsets detected by the Detector in the VTC core. More...
 
u32 XVtc_GetVersion (XVtc *InstancePtr)
 This function facilitates software identification of exact version of the VTC hardware (h/w). More...
 
XVtc_ConfigXVtc_LookupConfig (u16 DeviceId)
 This function returns a reference to an XVtc_Config structure based on the core id, DeviceId. More...
 
void XVtc_IntrHandler (void *InstancePtr)
 This function is the interrupt handler for the VTC core. More...
 
int XVtc_SetCallBack (XVtc *InstancePtr, u32 HandlerType, void *CallBackFunc, void *CallBackRef)
 This routine installs an asynchronous callback function for the given HandlerType: More...
 
int XVtc_SelfTest (XVtc *InstancePtr)
 This function reads version register of the VTC core and compares with zero as part of self test. More...
 
void XVtc_SetAdaptiveSyncMode (XVtc *InstancePtr, XVtc_AdaptiveSyncMode Mode)
 This function sets the vertical front porch stretch mechanism in VTC core to support Adaptive-Sync feature. More...
 
void XVtc_DisableAdaptiveSync (XVtc *InstancePtr)
 This function disable Adaptive-Sync in VTC core. More...
 
void XVtc_SetVfpStretchLimit (XVtc *InstancePtr, u32 StretchLimit)
 This function sets vertical front porch stretch limit. More...