v_voip_decap
Xilinx SDK Drivers API Documentation
xdecap.h File Reference

Overview

This is the main header file for VoIP Decapsulator core.

VoIP Decapsulator core is used for Incoming Packet Filter, Header Stripping and SDI Video Detection.

The VoIP Decapsulator has 3 main Interface

  • AXI4-Stream Interface for accepting Incoming Ethernet Packet
  • AXI4-Stream Interface for transmitting RTP Packet <RTP Header | Payload>
  • AXI4-Lite interface for processor, controls the VoIP Decapsulator.

VoIP Decapsulator Performs Following Operation

  • Filtering Packet to Channel based on Incoming Ethernet Packet Header
  • Striping Incoming Ethernet Header (MAC,IP & UDP) to form RTP Packet
  • SDI Video Information Extraction and Detection on Ethernet Packet (ST2022)

Software Initialization & Configuration

The application needs to do following steps in order for preparing the VoIP Decapsulator core to be ready.

  • Call XDecap_LookupConfig using a device ID to find the core configuration.
  • Call XDecap_CfgInitialize to initialize the device and the driver instance associated with it.

This driver provides interrupt handlers

  • XDecap_IntrHandler, for handling the interrupts from the VoIP Decapsulator core

Application developer needs to register interrupt handler with the processor, within their examples. Whenever processor calls registered application's interrupt handler associated with interrupt id, application's interrupt handler needs to call appropriate peripheral interrupt handler reading peripherals Status register.

This driver provides XDecap_SetCallback API to register functions with Generic Decap core instance.

Virtual Memory

Threads

Asserts

Building the driver

The VoIP Decapsulator driver is composed of several source files. This allows the user to build and link only those parts of the driver that are necessary.

MODIFICATION HISTORY:
Ver   Who    Date     Changes

1.00 mmo 02/12/16 Initial release.
 

Data Structures

struct  XDecap_MatchSelect
 This typedef contains Incoming IP Header Filtering Enable Information. More...
 
struct  XDecap_Header
 This typedef contains Incoming Packet Header Information. More...
 
struct  XDecap_StreamStatus
 This typedef contains Incoming Packet SDI Video Extraction Information (ST2022-6) More...
 
struct  XDecap_ChannelCfg
 This typedef contains VoIP Decapsulator Channel Information. More...
 
struct  XDecap_Config
 This typedef contains configuration information for the VoIP Decapsulator core. More...
 
struct  XDecap
 The XDecap driver instance data. More...
 

Macros

#define XDECAP_H_
 Prevent circular inclusions by using protection macros. More...
 

Enumerations

Handler Types
enum  XDecap_HandlerType
 These constants specify different types of handler and used to differentiate interrupt requests from peripheral. More...
 
Module Enable/Disable
enum  XDecap_ModuleEnable
 These constants specify specify the VoIP Decapsulator to enable/disable the incoming packet processing. More...
 
SDI Video Bit Rate
enum  XDecap_RXBITRATE
 These constants specify Incoming SDI Packet (SMPTE2022-6) Format whether an Integer/Non-Integer. More...
 
3G-SDI Level
enum  XDecap_3G_LEVEL
 These constants specify Incoming SDI Packet (SMPTE2022-6) 3G Level whether Level A or Level B. More...
 
SDI Mode
enum  XDecap_SDIMode
 These constants specify Incoming SDI Packet (SMPTE2022-6) Mode. More...
 

Match RTP-SSRC

enum  match_ssrc
 These constants specify the RTP-SSRC Field Filtering to be enabled. More...
 
typedef enum match_ssrc XDecap_MatchSSRCReg
 These constants specify the RTP-SSRC Field Filtering to be enabled. More...
 

Match UDP Destination Port

enum  match_udpdest
 These constants specify the UDP Destination Port Filtering to be enabled. More...
 
typedef enum match_udpdest XDecap_MatchUDPDestReg
 These constants specify the UDP Destination Port Filtering to be enabled. More...
 

Match UDP Source Port

enum  match_udpsrc
 These constants specify the UDP Source Port Filtering to be enabled. More...
 
typedef enum match_udpsrc XDecap_MatchUDPSrcReg
 These constants specify the UDP Source Port Filtering to be enabled. More...
 

Match IP Destination Address

enum  match_ipdest
 These constants specify the IP Destination Address Filtering to be enabled. More...
 
typedef enum match_ipdest XDecap_MatchIPDestReg
 These constants specify the IP Destination Address Filtering to be enabled. More...
 

Match IP Source Address

enum  match_ipsrc
 These constants specify the IP Source Address Filtering to be enabled. More...
 
typedef enum match_ipsrc XDecap_MatchIPSrcReg
 These constants specify the IP Source Address Filtering to be enabled. More...
 

Match VLAN ID

enum  match_vlanreg
 These constants specify the VLAN Tag ID Filtering to be enabled. More...
 
typedef enum match_vlanreg XDecap_MatchVLANReg
 These constants specify the VLAN Tag ID Filtering to be enabled. More...
 

Match VLAN Packets

enum  vlan_matching
 These constants specify to enable filtering Packet with/without VLAN. More...
 
typedef enum vlan_matching XDecap_VLANMatching
 These constants specify to enable filtering Packet with/without VLAN. More...
 

Channel Enable

enum  channel_control_enable
 These constants specify the operating channel enable/disable. More...
 
typedef enum channel_control_enable XDecap_ChannelEnable
 These constants specify the operating channel enable/disable. More...
 

VoIP Decapsulator Operating Mode

enum  operation_mode
 These constants specify the operating mode of VoIP Decapsulator. More...
 
typedef enum operation_mode XDecap_OperationMode
 These constants specify the operating mode of VoIP Decapsulator. More...
 

VoIP Decapsulator Marker Packet Detection Enable/Disable

enum  m_pkt_det
 These constants specify the Marker Packet Detection Enable/Disable of VoIP Decapsulator. More...
 
typedef enum m_pkt_det XDecap_MPktDetEn
 These constants specify the Marker Packet Detection Enable/Disable of VoIP Decapsulator. More...
 

VoIP Decapsulator Marker Packet Drop Enable

#define XDecap_BusyBit(InstancePtr)
 This macro Check the VoIP Decapsulator Busy Status which indicates the core is still updating the registers. More...
 
#define XDecap_NumSupportedChannel(InstancePtr)
 This macro Check the VoIP Decapsulator Current Supported Channel in the Hardware. More...
 
enum  m_pkt_drop
 These constants specify the Marker Packet Drop Enable/Disable of VoIP Decapsulator. More...
 
typedef enum m_pkt_drop XDecap_MPktDropEn
 These constants specify the Marker Packet Drop Enable/Disable of VoIP Decapsulator. More...
 
typedef void(* XDecap_Callback) (void *CallbackRef)
 Callback type for VoIP Decapsulator event interrupt. More...
 
XDecap_ConfigXDecap_LookupConfig (u16 DeviceId)
 This function returns a reference to an XDecap_Config structure based on the core id, DeviceId. More...
 
int XDecap_CfgInitialize (XDecap *InstancePtr, XDecap_Config *CfgPtr, UINTPTR EffectiveAddr)
 This function initializes the VoIP Decapsulator core. More...
 
void XDecap_CoreChannelConfig (XDecap *InstancePtr)
 This function configures the Operating channel of VoIP Decapsulator and the general setting of VoIP Decapsulator. More...
 
void XDecap_ChannelConfig (XDecap *InstancePtr, u16 Channels)
 This function Configures the VoIP Decapsulator Channels Parameter. More...
 
XDecap_Config XDecap_CoreInfo (XDecap *InstancePtr)
 This function reads the Core Information (Configured by user through GUI), in the VoIP Decapsulator Register. More...
 
XDecap_ChannelCfg XDecap_ChStatus (XDecap *InstancePtr, u16 Channels)
 This function reads the channel configured value of VoIP Decapsulator from register. More...
 
void XDecap_SoftReset (XDecap *InstancePtr)
 This function perform software resets on VoIP Decapsulator, which clears all the registers. More...
 
void XDecap_ChannelUpdate (XDecap *InstancePtr)
 This function send a pulse on VoIP Decapsulator to update the configured channel. More...
 
void XDecap_ChannelAccess (XDecap *InstancePtr, u16 Channels)
 This function accesses the current configuration channel. More...
 
u32 XDecap_RXPacketsCnt (XDecap *InstancePtr)
 This function reads current number of received packet at input interface of VoIP Decapsulator. More...
 
u32 XDecap_DropPacketsCnt (XDecap *InstancePtr)
 
u32 XDecap_ErrorPacketsCnt (XDecap *InstancePtr)
 This function reads the current number of discarded packet due to Error Packet, where received packet has tuser = 0. More...
 
u32 XDecap_MismatchPacketCnt (XDecap *InstancePtr)
 This function send a pulse on Generic Decap Channel Update. More...
 
void XDecap_ClearGeneralStatistic (XDecap *InstancePtr)
 This function clears the general register space statistic registers. More...
 
void XDecap_PacketLockWindow (XDecap *InstancePtr)
 This function sets the Packet Lock Window, where if consecutive Incoming Packet of the Channel has same SDI Video Format (Extracted from ST2022-6 Packet), VoIP Decapsulator will trigger the Packet Lock Interrupt Process. More...
 
void XDecap_PacketUnLockWindow (XDecap *InstancePtr)
 This function sets the Packet Unlock Window, where if consecutive Incoming Packet of the Channel has different SDI Video Format (Extracted from ST2022-6 Packet) from the Packet Lock SDI Video Format, VoIP Decapsulator will trigger the Packet Unlock Interrupt Process. More...
 
u8 XDecap_PeakBufferLv (XDecap *InstancePtr)
 This function reads the Peak Buffer Level of the VoIP Decapsulator. More...
 
void XDecap_ModuleEn (XDecap *InstancePtr)
 This function Enables/Disable the VoIP Decapsulator based on user Input at XDecap Structure. More...
 
u32 XDecap_MediaValidPcktCnt (XDecap *InstancePtr, u16 Channels)
 This function reads current number of valid RTP packet (ST2022-6) per channel of VoIP Decapsulator. More...
 
u32 XDecap_FECValidPcktCnt (XDecap *InstancePtr, u16 Channels)
 This function reads current number of valid FEC packet (ST2022-5) per channel of VoIP Decapsulator. More...
 
u32 XDecap_ReOrderedPcktCnt (XDecap *InstancePtr, u16 Channels)
 This function reads current number of Re-Ordered packet per channel of VoIP Decapsulator. More...
 
u32 XDecap_DropPcktCnt (XDecap *InstancePtr, u16 Channels)
 This function reads current number of Drop packet per channel of VoIP Decapsulator due to Buffer Full (Debug Register) More...
 
void XDecap_SetOperationMode (XDecap *InstancePtr, u16 Channels)
 This function set the Operation Mode of the VoIP Decapsulator based on user Input at XDecap Structure. More...
 
void XDecap_SetIPType (XDecap *InstancePtr, u16 Channels)
 
void XDecap_ControlChannelEn (XDecap *InstancePtr, u16 Channels)
 This function Enable/Disable the Channel. More...
 
void XDecap_ControlMPktDetEn (XDecap *InstancePtr, u16 Channels)
 This function Enable/Disable the Marker Packet Detection. More...
 
void XDecap_ControlMPktDropEn (XDecap *InstancePtr, u16 Channels)
 This function Enable/Disable the Marker Packet Drop. More...
 
void XDecap_ChannelClearStatistic (XDecap *InstancePtr, u16 Channels)
 This function Clears the Channel Statistic registers. More...
 
void XDecap_SetMatchSelect (XDecap *InstancePtr, u16 Channels)
 This function sets the Header Filter Enable Setting. More...
 
void XDecap_MatchIPv4Dest (XDecap *InstancePtr, u16 Channels)
 This function Sets the IP Destination Address of Incoming Packet for Matching/Filtering if the Filter is enabled. More...
 
void XDecap_MatchIPv4Src (XDecap *InstancePtr, u16 Channels)
 This function Sets the IP Source Address of Incoming Packet for Matching/Filtering if the Filter is enabled. More...
 
void XDecap_MatchUDPDest (XDecap *InstancePtr, u16 Channels)
 This function Sets the UDP Destination Port of Incoming Packet for Matching/Filtering if the Filter is enabled. More...
 
void XDecap_MatchUDPSrc (XDecap *InstancePtr, u16 Channels)
 This function Sets the UDP Source Port of Incoming Packet for Matching/Filtering if the Filter is enabled. More...
 
void XDecap_ToMatchVLANID (XDecap *InstancePtr, u16 Channels)
 This function Sets the VLAN Packet Filtering. More...
 
void XDecap_MatchVLANID (XDecap *InstancePtr, u16 Channels)
 This function Sets the VLAN ID (12 Bits) of Incoming Packet for Matching/Filtering if the Filter is enabled. More...
 
void XDecap_MatchSSRC (XDecap *InstancePtr, u16 Channels)
 This function Sets the RTP-SSRC Field of Incoming Packet for Matching/Filtering if the Filter is enabled. More...
 
XDecap_StreamStatus XDecap_StreamStat (XDecap *InstancePtr, u16 Channels)
 This function reads the ST2022-6 Packet Information. More...
 
u8 XDecap_SDIPacketLockStatus (XDecap *InstancePtr, u16 Channels)
 This function <> More...
 
u8 XDecap_VideoLockIntrStatus (XDecap *InstancePtr, u16 Channels)
 This function reads the Packet/Video Lock Interrupt Status. More...
 
u8 XDecap_VideoUnLockIntrStatus (XDecap *InstancePtr, u16 Channels)
 This function reads the Packet/Video Unlock Interrupt Status. More...
 
u8 XDecap_StreamStopIntrStatus (XDecap *InstancePtr, u16 Channels)
 This function reads the Packet Timeout Interrupt Status. More...
 
void XDecap_EnableVideoLockIntr (XDecap *InstancePtr, u16 Channels)
 This function Enables/Un-Mask the Packet/Video Lock Interrupt. More...
 
void XDecap_EnableVideoUnLockIntr (XDecap *InstancePtr, u16 Channels)
 This function Enables/Un-Mask the Packet/Video Un-Lock Interrupt. More...
 
void XDecap_EnablePacketStopIntr (XDecap *InstancePtr, u16 Channels)
 This function Enables/Un-Mask the Packet Timeout Interrupt. More...
 
void XDecap_DisableVideoLockIntr (XDecap *InstancePtr, u16 Channels)
 This function Disable/Mask the Packet Lock Interrupt. More...
 
void XDecap_DisableVideoUnLockIntr (XDecap *InstancePtr, u16 Channels)
 This function Disable/Mask the Packet Un-Lock Interrupt. More...
 
void XDecap_DisablePacketStopIntr (XDecap *InstancePtr, u16 Channels)
 This function Disable/Mask the Packet Timeout Interrupt. More...
 
void XDecap_IntrClear (XDecap *InstancePtr, u16 Channels)
 This function Clears All Active Interrupt Status Bit. More...
 
void XDecap_PacketStopTimer (XDecap *InstancePtr, u16 Channels)
 This function Sets the Timeout Value to trigger Packet Timeout Interrupt, if there are no packet received within the timeout period. More...
 
void XDecap_IntrHandler (void *InstancePtr)
 This function is the interrupt handler for the VoIP Decapsulator driver. More...
 
int XDecap_SetCallback (XDecap *InstancePtr, XDecap_HandlerType HandlerType, void *CallbackFunc, void *CallbackRef)
 This function installs an asynchronous callback function for the given HandlerType: More...
 

Macro Definition Documentation

◆ XDecap_BusyBit

#define XDecap_BusyBit (   InstancePtr)
Value:
XDecap_ReadReg((InstancePtr)->Config.BaseAddress, \
(XDECAP_STATUS_OFFSET)) & (XDECAP_STATUS_UPDATE_BUSY_MASK)
#define XDecap_ReadReg(BaseAddress, RegOffset)
This macro reads a value from a Decap register.
Definition: xdecap_hw.h:299

This macro Check the VoIP Decapsulator Busy Status which indicates the core is still updating the registers.

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
BusyBitStatus.
Note
  void XDecap_BusyBit(XDecap *InstancePtr)

◆ XDECAP_H_

#define XDECAP_H_

Prevent circular inclusions by using protection macros.

◆ XDecap_NumSupportedChannel

#define XDecap_NumSupportedChannel (   InstancePtr)
Value:
XDecap_ReadReg((InstancePtr)->Config.BaseAddress, \
(XDECAP_SYS_CONFIG_OFFSET)) & (XDECAP_SYS_CONFIG_C_CHANNELS_MASK)
#define XDecap_ReadReg(BaseAddress, RegOffset)
This macro reads a value from a Decap register.
Definition: xdecap_hw.h:299

This macro Check the VoIP Decapsulator Current Supported Channel in the Hardware.

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
Current Supported Number of Channel in the Hardware.
Note
  void XDecap_NumSupportedChannel(XDecap *InstancePtr)

Typedef Documentation

◆ XDecap_Callback

typedef void(* XDecap_Callback) (void *CallbackRef)

Callback type for VoIP Decapsulator event interrupt.

Parameters
CallbackRefis a callback reference passed in by the upper layer when setting the callback functions, and passed back to the upper layer when the callback is invoked.
Returns
None.
Note
None.

◆ XDecap_ChannelEnable

These constants specify the operating channel enable/disable.

◆ XDecap_MatchIPDestReg

These constants specify the IP Destination Address Filtering to be enabled.

◆ XDecap_MatchIPSrcReg

These constants specify the IP Source Address Filtering to be enabled.

◆ XDecap_MatchSSRCReg

These constants specify the RTP-SSRC Field Filtering to be enabled.

◆ XDecap_MatchUDPDestReg

These constants specify the UDP Destination Port Filtering to be enabled.

◆ XDecap_MatchUDPSrcReg

These constants specify the UDP Source Port Filtering to be enabled.

◆ XDecap_MatchVLANReg

These constants specify the VLAN Tag ID Filtering to be enabled.

◆ XDecap_MPktDetEn

These constants specify the Marker Packet Detection Enable/Disable of VoIP Decapsulator.

◆ XDecap_MPktDropEn

These constants specify the Marker Packet Drop Enable/Disable of VoIP Decapsulator.

◆ XDecap_OperationMode

These constants specify the operating mode of VoIP Decapsulator.

◆ XDecap_VLANMatching

These constants specify to enable filtering Packet with/without VLAN.

Enumeration Type Documentation

◆ channel_control_enable

These constants specify the operating channel enable/disable.

◆ m_pkt_det

enum m_pkt_det

These constants specify the Marker Packet Detection Enable/Disable of VoIP Decapsulator.

◆ m_pkt_drop

enum m_pkt_drop

These constants specify the Marker Packet Drop Enable/Disable of VoIP Decapsulator.

◆ match_ipdest

These constants specify the IP Destination Address Filtering to be enabled.

◆ match_ipsrc

These constants specify the IP Source Address Filtering to be enabled.

◆ match_ssrc

enum match_ssrc

These constants specify the RTP-SSRC Field Filtering to be enabled.

◆ match_udpdest

These constants specify the UDP Destination Port Filtering to be enabled.

◆ match_udpsrc

These constants specify the UDP Source Port Filtering to be enabled.

◆ match_vlanreg

These constants specify the VLAN Tag ID Filtering to be enabled.

◆ operation_mode

These constants specify the operating mode of VoIP Decapsulator.

◆ vlan_matching

These constants specify to enable filtering Packet with/without VLAN.

◆ XDecap_3G_LEVEL

These constants specify Incoming SDI Packet (SMPTE2022-6) 3G Level whether Level A or Level B.

◆ XDecap_HandlerType

These constants specify different types of handler and used to differentiate interrupt requests from peripheral.

◆ XDecap_ModuleEnable

These constants specify specify the VoIP Decapsulator to enable/disable the incoming packet processing.

◆ XDecap_RXBITRATE

These constants specify Incoming SDI Packet (SMPTE2022-6) Format whether an Integer/Non-Integer.

◆ XDecap_SDIMode

These constants specify Incoming SDI Packet (SMPTE2022-6) Mode.

Function Documentation

◆ XDecap_CfgInitialize()

int XDecap_CfgInitialize ( XDecap InstancePtr,
XDecap_Config CfgPtr,
UINTPTR  EffectiveAddr 
)

This function initializes the VoIP Decapsulator core.

This function must be called prior to using the VoIP Decapsulator core. Initialization of the VoIP Decapsulator includes setting up the instance data and ensuring the hardware is in a quiescent state.

Parameters
InstancePtris a pointer to the XDecap core instance.
CfgPtrpoints to the configuration structure associated with the VoIP Decapsulator core.
EffectiveAddris the base address of the device. If address translation is being used, then this parameter must reflect the virtual base address. Otherwise, the physical address should be used.
Returns
  • XST_SUCCESS if XDecap_CfgInitialize was successful.
  • XST_FAILURE if Channel Number has mismatched with value reflected on the register, and if the operating channel number is higher tha hardware supported channel number
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, and XDecap::PacketLockCallback.

◆ XDecap_ChannelAccess()

◆ XDecap_ChannelClearStatistic()

void XDecap_ChannelClearStatistic ( XDecap InstancePtr,
u16  Channels 
)

This function Clears the Channel Statistic registers.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_ChannelConfig()

void XDecap_ChannelConfig ( XDecap InstancePtr,
u16  Channels 
)

This function Configures the VoIP Decapsulator Channels Parameter.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_ChannelAccess(), XDecap_ControlChannelEn(), XDecap_ControlMPktDetEn(), XDecap_ControlMPktDropEn(), XDecap_MatchIPv4Dest(), XDecap_MatchIPv4Src(), XDecap_MatchSSRC(), XDecap_MatchUDPDest(), XDecap_MatchUDPSrc(), XDecap_MatchVLANID(), XDecap_PacketStopTimer(), XDecap_SetMatchSelect(), XDecap_SetOperationMode(), and XDecap_ToMatchVLANID().

Referenced by XDecap_CoreChannelConfig().

◆ XDecap_ChannelUpdate()

void XDecap_ChannelUpdate ( XDecap InstancePtr)

This function send a pulse on VoIP Decapsulator to update the configured channel.

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
None.
Note
None.

References XDecap_ReadReg.

Referenced by XDecap_CoreChannelConfig().

◆ XDecap_ChStatus()

XDecap_ChannelCfg XDecap_ChStatus ( XDecap InstancePtr,
u16  Channels 
)

This function reads the channel configured value of VoIP Decapsulator from register.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
XDecap_ChannelCfg_RegValue, which contains the channel configuration component
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_ClearGeneralStatistic()

void XDecap_ClearGeneralStatistic ( XDecap InstancePtr)

This function clears the general register space statistic registers.

It's a self clear register.

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, and XDecap_WriteReg.

◆ XDecap_ControlChannelEn()

void XDecap_ControlChannelEn ( XDecap InstancePtr,
u16  Channels 
)

This function Enable/Disable the Channel.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_ControlMPktDetEn()

void XDecap_ControlMPktDetEn ( XDecap InstancePtr,
u16  Channels 
)

This function Enable/Disable the Marker Packet Detection.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_ControlMPktDropEn()

void XDecap_ControlMPktDropEn ( XDecap InstancePtr,
u16  Channels 
)

This function Enable/Disable the Marker Packet Drop.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_CoreChannelConfig()

void XDecap_CoreChannelConfig ( XDecap InstancePtr)

This function configures the Operating channel of VoIP Decapsulator and the general setting of VoIP Decapsulator.

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
None.
Note
None.

References XDecap_ChannelConfig(), XDecap_ChannelUpdate(), XDecap_ModuleEn(), XDecap_PacketLockWindow(), and XDecap_PacketUnLockWindow().

◆ XDecap_CoreInfo()

XDecap_Config XDecap_CoreInfo ( XDecap InstancePtr)

This function reads the Core Information (Configured by user through GUI), in the VoIP Decapsulator Register.

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
XDecap_Config of the HW Channel Number.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_Config::HWChannelNumber, and XDecap_ReadReg.

◆ XDecap_DisablePacketStopIntr()

void XDecap_DisablePacketStopIntr ( XDecap InstancePtr,
u16  Channels 
)

This function Disable/Mask the Packet Timeout Interrupt.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_DisableVideoLockIntr()

void XDecap_DisableVideoLockIntr ( XDecap InstancePtr,
u16  Channels 
)

This function Disable/Mask the Packet Lock Interrupt.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_DisableVideoUnLockIntr()

void XDecap_DisableVideoUnLockIntr ( XDecap InstancePtr,
u16  Channels 
)

This function Disable/Mask the Packet Un-Lock Interrupt.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_DropPcktCnt()

u32 XDecap_DropPcktCnt ( XDecap InstancePtr,
u16  Channels 
)

This function reads current number of Drop packet per channel of VoIP Decapsulator due to Buffer Full (Debug Register)

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_EnablePacketStopIntr()

void XDecap_EnablePacketStopIntr ( XDecap InstancePtr,
u16  Channels 
)

This function Enables/Un-Mask the Packet Timeout Interrupt.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_EnableVideoLockIntr()

void XDecap_EnableVideoLockIntr ( XDecap InstancePtr,
u16  Channels 
)

This function Enables/Un-Mask the Packet/Video Lock Interrupt.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_EnableVideoUnLockIntr()

void XDecap_EnableVideoUnLockIntr ( XDecap InstancePtr,
u16  Channels 
)

This function Enables/Un-Mask the Packet/Video Un-Lock Interrupt.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_ErrorPacketsCnt()

u32 XDecap_ErrorPacketsCnt ( XDecap InstancePtr)

This function reads the current number of discarded packet due to Error Packet, where received packet has tuser = 0.

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
Number of Error Packet.
Note
None.

References XDecap_ReadReg.

◆ XDecap_FECValidPcktCnt()

u32 XDecap_FECValidPcktCnt ( XDecap InstancePtr,
u16  Channels 
)

This function reads current number of valid FEC packet (ST2022-5) per channel of VoIP Decapsulator.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_IntrClear()

void XDecap_IntrClear ( XDecap InstancePtr,
u16  Channels 
)

This function Clears All Active Interrupt Status Bit.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_WriteReg.

◆ XDecap_IntrHandler()

void XDecap_IntrHandler ( void *  InstancePtr)

This function is the interrupt handler for the VoIP Decapsulator driver.

This handler reads the pending interrupt from VoIP Decapsulator, determines the source of the interrupts, clears the interrupts and calls callbacks accordingly.

The application is responsible for connecting this function to the interrupt system. Application beyond this driver is also responsible for providing callbacks to handle interrupts and installing the callbacks using XDecap_SetCallback() during initialization phase. An example delivered with this driver demonstrates how this could be done.

Parameters
InstancePtris a pointer to the XDecap instance that just interrupted.
Returns
None.
Note
None.

References XDecap::IsReady.

◆ XDecap_LookupConfig()

XDecap_Config* XDecap_LookupConfig ( u16  DeviceId)

This function returns a reference to an XDecap_Config structure based on the core id, DeviceId.

The return value will refer to an entry in the device configuration table defined in the xdecap_g.c file.

Parameters
DeviceIdis the unique core ID of the VoIP Decapsulator core for the lookup operation.
Returns
XDecap_LookupConfig returns a reference to a config record in the configuration table (in xdecap_g.c) corresponding to DeviceId, or NULL if no match is found.
Note
None.

◆ XDecap_MatchIPv4Dest()

void XDecap_MatchIPv4Dest ( XDecap InstancePtr,
u16  Channels 
)

This function Sets the IP Destination Address of Incoming Packet for Matching/Filtering if the Filter is enabled.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_WriteReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_MatchIPv4Src()

void XDecap_MatchIPv4Src ( XDecap InstancePtr,
u16  Channels 
)

This function Sets the IP Source Address of Incoming Packet for Matching/Filtering if the Filter is enabled.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_WriteReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_MatchSSRC()

void XDecap_MatchSSRC ( XDecap InstancePtr,
u16  Channels 
)

This function Sets the RTP-SSRC Field of Incoming Packet for Matching/Filtering if the Filter is enabled.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_WriteReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_MatchUDPDest()

void XDecap_MatchUDPDest ( XDecap InstancePtr,
u16  Channels 
)

This function Sets the UDP Destination Port of Incoming Packet for Matching/Filtering if the Filter is enabled.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_MatchUDPSrc()

void XDecap_MatchUDPSrc ( XDecap InstancePtr,
u16  Channels 
)

This function Sets the UDP Source Port of Incoming Packet for Matching/Filtering if the Filter is enabled.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_MatchVLANID()

void XDecap_MatchVLANID ( XDecap InstancePtr,
u16  Channels 
)

This function Sets the VLAN ID (12 Bits) of Incoming Packet for Matching/Filtering if the Filter is enabled.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_MediaValidPcktCnt()

u32 XDecap_MediaValidPcktCnt ( XDecap InstancePtr,
u16  Channels 
)

This function reads current number of valid RTP packet (ST2022-6) per channel of VoIP Decapsulator.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_MismatchPacketCnt()

u32 XDecap_MismatchPacketCnt ( XDecap InstancePtr)

This function send a pulse on Generic Decap Channel Update.

Parameters
InstancePtris a pointer to the XGeneric_Decap core instance.
Returns
None.
Note
None.

References XDecap_ReadReg.

◆ XDecap_ModuleEn()

void XDecap_ModuleEn ( XDecap InstancePtr)

This function Enables/Disable the VoIP Decapsulator based on user Input at XDecap Structure.

XDecap->ModuleEnable

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, and XDecap_ReadReg.

Referenced by XDecap_CoreChannelConfig().

◆ XDecap_PacketLockWindow()

void XDecap_PacketLockWindow ( XDecap InstancePtr)

This function sets the Packet Lock Window, where if consecutive Incoming Packet of the Channel has same SDI Video Format (Extracted from ST2022-6 Packet), VoIP Decapsulator will trigger the Packet Lock Interrupt Process.

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, and XDecap_ReadReg.

Referenced by XDecap_CoreChannelConfig().

◆ XDecap_PacketStopTimer()

void XDecap_PacketStopTimer ( XDecap InstancePtr,
u16  Channels 
)

This function Sets the Timeout Value to trigger Packet Timeout Interrupt, if there are no packet received within the timeout period.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_WriteReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_PacketUnLockWindow()

void XDecap_PacketUnLockWindow ( XDecap InstancePtr)

This function sets the Packet Unlock Window, where if consecutive Incoming Packet of the Channel has different SDI Video Format (Extracted from ST2022-6 Packet) from the Packet Lock SDI Video Format, VoIP Decapsulator will trigger the Packet Unlock Interrupt Process.

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, and XDecap_ReadReg.

Referenced by XDecap_CoreChannelConfig().

◆ XDecap_PeakBufferLv()

u8 XDecap_PeakBufferLv ( XDecap InstancePtr)

This function reads the Peak Buffer Level of the VoIP Decapsulator.

(Debug Register)

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
Peak Buffer Level.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, and XDecap_ReadReg.

◆ XDecap_ReOrderedPcktCnt()

u32 XDecap_ReOrderedPcktCnt ( XDecap InstancePtr,
u16  Channels 
)

This function reads current number of Re-Ordered packet per channel of VoIP Decapsulator.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_RXPacketsCnt()

u32 XDecap_RXPacketsCnt ( XDecap InstancePtr)

This function reads current number of received packet at input interface of VoIP Decapsulator.

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
Number of Received Packet
Note
None.

References XDecap_ReadReg.

◆ XDecap_SDIPacketLockStatus()

u8 XDecap_SDIPacketLockStatus ( XDecap InstancePtr,
u16  Channels 
)

This function <>

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_SetCallback()

int XDecap_SetCallback ( XDecap InstancePtr,
XDecap_HandlerType  HandlerType,
void *  CallbackFunc,
void *  CallbackRef 
)

This function installs an asynchronous callback function for the given HandlerType:

HandlerType                 Callback Function Type
-------------------------   -----------------------------------------------
Parameters
InstancePtris a pointer to the VoIP Decapsulator core instance.
HandlerTypespecifies the type of handler.
CallbackFuncis the address of the callback function.
CallbackRefis a user data item that will be passed to the callback function when it is invoked.
Returns
  • XST_SUCCESS if callback function installed successfully.
  • XST_INVALID_PARAM when HandlerType is invalid.
Note
Invoking this function for a handler that already has been installed replaces it with the new handler.

◆ XDecap_SetMatchSelect()

void XDecap_SetMatchSelect ( XDecap InstancePtr,
u16  Channels 
)

This function sets the Header Filter Enable Setting.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_SetOperationMode()

void XDecap_SetOperationMode ( XDecap InstancePtr,
u16  Channels 
)

This function set the Operation Mode of the VoIP Decapsulator based on user Input at XDecap Structure.

Normal Mode: VoIP Decapsulator doesn't have any information of incoming packet before operation Lossless Mode: VoIP Decapsulator have configured with Incoming Packet Information before operation.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_SoftReset()

void XDecap_SoftReset ( XDecap InstancePtr)

This function perform software resets on VoIP Decapsulator, which clears all the registers.

Parameters
InstancePtris a pointer to the XDecap core instance.
Returns
None.
Note
None.

References XDecap_ReadReg.

◆ XDecap_StreamStat()

XDecap_StreamStatus XDecap_StreamStat ( XDecap InstancePtr,
u16  Channels 
)

This function reads the ST2022-6 Packet Information.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_StreamStopIntrStatus()

u8 XDecap_StreamStopIntrStatus ( XDecap InstancePtr,
u16  Channels 
)

This function reads the Packet Timeout Interrupt Status.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_ToMatchVLANID()

void XDecap_ToMatchVLANID ( XDecap InstancePtr,
u16  Channels 
)

This function Sets the VLAN Packet Filtering.

This function is valid if the VLAN Match Select is Enabled.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, and XDecap_ReadReg.

Referenced by XDecap_ChannelConfig().

◆ XDecap_VideoLockIntrStatus()

u8 XDecap_VideoLockIntrStatus ( XDecap InstancePtr,
u16  Channels 
)

This function reads the Packet/Video Lock Interrupt Status.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.

◆ XDecap_VideoUnLockIntrStatus()

u8 XDecap_VideoUnLockIntrStatus ( XDecap InstancePtr,
u16  Channels 
)

This function reads the Packet/Video Unlock Interrupt Status.

Parameters
InstancePtris a pointer to the XDecap core instance.
Channelsis current configured channel
Returns
None.
Note
None.

References XDecap_Config::BaseAddress, XDecap::Config, XDecap_ChannelAccess(), and XDecap_ReadReg.