📄 ixhssacccommon_p.h
字号:
* * @brief The HSS co-processor register bit offset for NUM in HSSCLKCR */#define IX_HSSACC_COM_HSSCLKCR_NUM_OFFSET 12/** * @def IX_HSSACC_COM_HSSCLKCR_DENOM_OFFSET * * @brief The HSS co-processor register bit offset for DENOM in HSSCLKCR */#define IX_HSSACC_COM_HSSCLKCR_DENOM_OFFSET 0 /** * @def IX_HSSACC_COM_HSSFCR_OFFSET_OFFSET * * @brief The HSS co-processor register bit offset for OFFSET in HSSFCR */#define IX_HSSACC_COM_HSSFCR_OFFSET_OFFSET 16/** * @def IX_HSSACC_COM_HSSFCR_OFFSET_MAX * * @brief The HSS co-processor register max value for OFFSET in HSSFCR */#define IX_HSSACC_COM_HSSFCR_OFFSET_MAX 1023/** * @def IX_HSSACC_COM_HSSFCR_SIZE_OFFSET * * @brief The HSS co-processor register bit offset for SIZE in HSSFCR */#define IX_HSSACC_COM_HSSFCR_SIZE_OFFSET 0/** * @def IX_HSSACC_COM_HSSFCR_SIZE_MAX * * @brief The HSS co-processor register max value for SIZE in HSSFCR */#define IX_HSSACC_COM_HSSFCR_SIZE_MAX 1023/** * @def IX_HSSACC_ENUM_INVALID * * @brief Mechanism to validate the upper (MAX) and lower (0) bounds * of a positive enumeration * * @param int [in] VALUE - the integer value to test * @param int [in] MAX - the maximum value to test against * * This macro returns TRUE if the bounds are invalid and FALSE if * they are okay. NOTE: MAX will be an invalid value, so check >= * * @return none */#define IX_HSSACC_ENUM_INVALID(VALUE, MAX) ((((VALUE) < 0) || ((VALUE) >= (MAX))) ? TRUE : FALSE) /** * Prototypes for interface functions. *//** * @fn IX_STATUS ixHssAccComPortInit (IxHssAccHssPort hssPortId, IxHssAccConfigParams *configParams, IxHssAccTdmSlotUsage *tdmMap, IxHssAccLastErrorCallback lastErrorCallback) * * @brief This function takes the client specified parameters, configures * them appropriately and communicates them to NPE-A * * @param IxHssAccHssPort hssPortId (in) - The HSS port Id. There are two * identical ports (0-1). * @param IxHssAccConfigParams *configParams (in) - Pointer to a structure * containing HSS configuration parameters - clock characteristics, data * frame characteristics, number of HDLC ports, total channelised slots * etc. * @param IxHssAccTdmSlotUsage *tdmMap (in) - A pointer to an array of size * IX_HSSACC_TSLOTS_PER_HSS_PORT, defining the slot usage over the HSS port * @param IxHssAccLastErrorCallback lastErrorCallback (in) - Function * pointer to be called back by the NPE Message Handler to pass the last * HSS error to the client. The client will be notified of the total number * of HSS errors through the callbacks registered for the packetised and * channelised services. If the client observes this number increasing, it * may initiate the retrieval of the last error through the * ixHssAccLastErrorRetrievalInitiate interface. This interface will send a * read request to the NPE. When the NPE responds (in a different context), * the NPE Message Handler will pass the data read to the client through * this interface. * * Several configurables need to be written to the NPE. The IxNpeMh is used * to write these values. For each message sent to IxNpeMh, a response is * requested. This response will come back in a different context. This * config function will wait between sends for valid responses. If an * invalid one is received, the config will return an error to the client. * * @return IX_STATUS */IX_STATUS ixHssAccComPortInit (IxHssAccHssPort hssPortId, IxHssAccConfigParams *configParams, IxHssAccTdmSlotUsage *tdmMap, IxHssAccLastErrorCallback lastErrorCallback);/** * @fn IX_STATUS ixHssAccComLastHssErrGet (IxHssAccHssPort hssPortId) * * @brief The service interface calls this function to read the last HSS * error. The last error will be fed back to the client through the client * callback interface in the context of the NPE Message Handler. * * @param IxHssAccHssPort hssPortId (in) - The HSS port Id. There are two * identical ports (0-1). * * @return IX_STATUS */IX_STATUS ixHssAccComLastHssErrGet (IxHssAccHssPort hssPortId);/** * @fn IX_STATUS ixHssAccComNpeCmdMsgSend (IxNpeMhMessage message, BOOL reqResp, unsigned npeMsgId) * * @brief This function sends a command to the NPE through the ixNpeMh. If * reqResp is TRUE, this function will BLOCK until a response is received * back from the NPE via the NpeMh. * * @param IxNpeMhMessage message (in) - The Npe message to send * @param BOOL reqResp (in) - This value specifies whether or not a * response is required * @param unsigned npeMsgId (in) - The Npe message * identifier * * @return IX_STATUS */IX_STATUS ixHssAccComNpeCmdMsgSend (IxNpeMhMessage message, BOOL reqResp, unsigned npeMsgId);/** * @fn void ixHssAccComNpeCmdMsgCreate (unsigned byte0, unsigned byte1, unsigned byte2, unsigned byte3, unsigned data, IxNpeMhMessage *pMessage) * * @brief This function creates an NPE HSS command * * @param unsigned byte0 (in) - Byte value to be assigned byte position 0 * @param unsigned byte1 (in) - Byte value to be assigned byte position 1 * @param unsigned byte2 (in) - Byte value to be assigned byte position 2 * @param unsigned byte3 (in) - Byte value to be assigned byte position 3 * @param unsigned data (in) - Data word to be sent with the command * @param IxNpeMhMessage *pMessage (out) - The Npe message to write to * * @return void */void ixHssAccComNpeCmdMsgCreate (unsigned byte0, unsigned byte1, unsigned byte2, unsigned byte3, unsigned data, IxNpeMhMessage *pMessage);/** * @fn UINT32 ixHssAccComTdmToNpeVoiceChanTranslate (IxHssAccHssPort hssPortId, UINT32 tdmSlotId) * * @brief This function translates a TDM slot (0-127) to NPE voice channel * Id (0-31) on the specified HSS port. This interface performs no error * checking on the tdmSlotId passed in by client. Hence, before this * interface is called, client should ensure that the tdmSlotId passed * in has been configured as a channelised timeslot on the specified HSS * port. * * @param IxHssAccHssPort hssPortId (in) - The HSS port Id. There are two * identical ports (0-1). Only port 0 will be supported. * @param UINT32 tdmSlotId (in) - TDM slot that is configured as * channelised timeslot (0-127) * * @return UINT32 */UINT32 ixHssAccComTdmToNpeVoiceChanTranslate (IxHssAccHssPort hssPortId, UINT32 tdmSlotId); /** * @fn BOOL ixHssAccComIsChanTimeslot (IxHssAccHssPort hssPortId, UINT32 tdmSlotId) * * @brief This function checks whether the TDM slot on the specified HSS * port is a channelised timeslot * * @param IxHssAccHssPort hssPortId (in) - The HSS port Id. There are two * identical ports (0-1). Only port 0 will be supported. * @param UINT32 tdmSlotId (in) - The TDM slot Id (0-127). * * @return * - TRUE The tdmSlotId is a channelised timeslot * - FALSE The tdmSlotId is a not channelised timeslot */BOOL ixHssAccComIsChanTimeslot (IxHssAccHssPort hssPortId, UINT32 tdmSlotId);/** * @fn UINT32 ixHssAccComNumChanTimeslotGet (IxHssAccHssPort hssPortId) * * @brief This function returns number of channelised timeslots * configured for the specified HSS port * * @param IxHssAccHssPort hssPortId (in) - The HSS port Id. There are two * identical ports (0-1). Only port 0 will be supported. * * @return * - UINT32 The number of channelised timeslots the HSS port has */UINT32 ixHssAccComNumChanTimeslotGet (IxHssAccHssPort hssPortId);/** * @fn void ixHssAccComShow (void) * * @brief This function will display the current state of the IxHssAcc Com * module * * @return void */void ixHssAccComShow (void);/** * @fn void ixHssAccComStatsInit (void) * * @brief This function will initialise the stats of the IxHssAcc Com module * * @return void */void ixHssAccComStatsInit (void);/** * @fn IX_STATUS ixHssAccComInit (void) * * @brief This function will initialise the IxHssAcc Com module * * @return * - IX_SUCCESS Function executed successfully * - IX_FAIL Function failed to execute */IX_STATUS ixHssAccComInit (void);/** * @fn IX_STATUS ixHssAccComPortUninit (IxHssAccHssPort hssPortId) * * @brief This function Uninitialises all resources for all descriptor pools * and descriptors contained in these pools. * * @return * - IX_SUCCESS The function executed successfully * - IX_FAIL The function did not execute successfully * - IX_HSSACC_RESOURCE_ERR The function did not execute successfully * due to a resource error */IX_STATUS ixHssAccComPortUninit (IxHssAccHssPort hssPortId);/** * @fn IX_STATUS ixHssAccComUninit () * * @brief This function Uninitialises all resources for all descriptor pools * and descriptors contained in these pools. * * @return * - IX_SUCCESS The function executed successfully * - IX_FAIL The function did not execute successfully * - IX_HSSACC_RESOURCE_ERR The function did not execute successfully * due to a resource error */IX_STATUS ixHssAccComUninit (void);#endif /* IXHSSACCCOMMON_P_H *//** * @} defgroup IxHssAccCommon_p */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -