Software Drivers

xdptx_spm.c File Reference


Detailed Description

This file contains the stream policy maker functions for the XDptx driver. These functions set up the DisplayPort TX core's main stream attributes that determine how a video stream will be displayed.

 MODIFICATION HISTORY:

 Ver   Who  Date     Changes
 ----- ---- -------- -----------------------------------------------
 1.00a als  05/17/14 Initial release.
 

#include "xdptx.h"
#include "xdptx_hw.h"
#include "xstatus.h"

Functions

void XDptx_CfgMsaRecalculate (XDptx *InstancePtr)
u32 XDptx_CfgMsaUseStandardVideoMode (XDptx *InstancePtr, XDptx_VideoMode VideoMode)
void XDptx_CfgMsaUseEdidPreferredTiming (XDptx *InstancePtr)
void XDptx_CfgMsaUseCustom (XDptx *InstancePtr, XDptx_MainStreamAttributes *MsaConfigCustom, u8 Recalculate)
u32 XDptx_CfgMsaSetBpc (XDptx *InstancePtr, u8 BitsPerColor)
void XDptx_SetVideoMode (XDptx *InstancePtr)


Function Documentation

void XDptx_CfgMsaRecalculate ( XDptx InstancePtr  ) 

This function calculates the following main stream attributes:

Parameters:
InstancePtr is a pointer to the XDptx instance.
Note:
The MsaConfig structure is modified with the new, calculated values. The main stream attributes that were used to derive the calculated values are untouched in the MsaConfig structure.

u32 XDptx_CfgMsaSetBpc ( XDptx InstancePtr,
u8  BitsPerColor 
)

This function sets the bits per color value of the video stream.

Parameters:
InstancePtr is a pointer to the XDptx instance
BitsPerColor is the new number of bits per color to use.
Note:
The InstancePtr->MsaConfig structure is modified to reflect the new main stream attributes associated with a new bits per color value.
Returns:
  • XST_INVALID_PARAM if the supplied bits per color value is not either 6, 8, 10, 12, or 16.
  • XST_SUCCESS otherwise.

void XDptx_CfgMsaUseCustom ( XDptx InstancePtr,
XDptx_MainStreamAttributes MsaConfigCustom,
u8  Recalculate 
)

This function takes a the main stream attributes from MsaConfigCustom and copies them into InstancePtr->MsaConfig. If desired, given a base set of attributes, the rest of the attributes may be derived. The minimal required main stream attributes that must be contained in the MsaConfigCustom structure are:

Parameters:
InstancePtr is a pointer to the XDptx instance.
MsaConfigCustom is the structure that will be used to copy the main stream attributes from (into InstancePtr->MsaConfig).
Recalculate is a boolean enable that determines whether or not the main stream attributes should be recalculated.
Note:
The InstancePtr-> MsaConfig structure is modified with the new values.

void XDptx_CfgMsaUseEdidPreferredTiming ( XDptx InstancePtr  ) 

This function sets the main stream attribute values in the configuration structure to match the preferred timing of the sink monitor. This preferred timing information is stored in the sink's extended display identification data (EDID).

Parameters:
InstancePtr is a pointer to the XDptx instance
Note:
The InstancePtr->MsaConfig structure is modified to reflect the main stream attribute values associated to the preferred timing of the sink monitor.

u32 XDptx_CfgMsaUseStandardVideoMode ( XDptx InstancePtr,
XDptx_VideoMode  VideoMode 
)

This function sets the main stream attribute values in the configuration structure to match one of the standard display mode timings from the XDptx_DmtModes[] table. THe XDptx_VideoMode enumeration in xdptx.h lists the available video modes.

Parameters:
InstancePtr is a pointer to the XDptx instance.
VideoMode is one of the enumerated standard video modes that is used to determine the main stream attributes to be used.
Returns:
  • XST_INVALID_PARAM if the supplied video mode isn't in the DMT table.
  • XST_SUCCESS otherwise.
Note:
The InstancePtr->MsaConfig structure is modified to reflect the main stream attribute values associated to the specified video mode.

void XDptx_SetVideoMode ( XDptx InstancePtr  ) 

This function clears the main stream attributes registers of the DisplayPort TX core and sets them to the values specified in the main stream attributes configuration structure.

Parameters:
InstancePtr is a pointer to the XDptx instance

Copyright @ 1995-2014 Xilinx, Inc. All rights reserved.