AM64x INDUSTRIAL COMMUNICATIONS SDK  2025.00.00

Introduction

Functions

int32_t PN_MRP_setPortState (PN_Handle pnHandle, uint8_t portNumber, uint8_t pState)
 API to set the MRP state for a port. More...
 
int32_t PN_MRP_getPortState (PRUICSS_HwAttrs const *pruicssHwAttrs, uint8_t portNumber, uint8_t *pState)
 Returns the MRP state of a port. More...
 
uint32_t PN_enterFlushMode (PN_Handle pnHandle)
 Used to signal topology change to MRP state machine. More...
 
uint32_t PN_allCpmKnown (PN_Handle pnHandle)
 
void PN_resetCpmPorts (PN_Handle pnHandle)
 
void PN_setCpmPort (PN_Handle pnHandle, t_rtcPacket *pID)
 

Enumerations

enum  tMrpStates {
  MRPREADY, MRPENTER, MRPWAIT, MRPCHECK,
  MRPEXIT
}
 

Macros

#define DISABLED   0
 
#define BLOCKING   1
 
#define FORWARDING   2
 

Macro Definition Documentation

◆ DISABLED

#define DISABLED   0

MRP Port disabled state

◆ BLOCKING

#define BLOCKING   1

MRP Port blocking state

◆ FORWARDING

#define FORWARDING   2

MRP Port forwarding state

Enumeration Type Documentation

◆ tMrpStates

enum tMrpStates
Enumerator
MRPREADY 

MRP module initiliazed. Idle state, do nothing

MRPENTER 

MRP flush mode entered. Break in network detected, flush FDB

MRPWAIT 

Waiting for CPM received. Sleep and goto MRPCHECK

MRPCHECK 

Check if all CPM received. Check by PN_allCpmKnown

MRPEXIT 

Exit MRP flush mode, back to normal op i.e., to MRPREADY

Function Documentation

◆ PN_MRP_setPortState()

int32_t PN_MRP_setPortState ( PN_Handle  pnHandle,
uint8_t  portNumber,
uint8_t  pState 
)

API to set the MRP state for a port.

Parameters
[in]pnHandleProfinet Handle
[in]portNumberPort for which MRP state has to be configured
ICSS_EMAC_PORT_1 (1)
ICSS_EMAC_PORT_2 (2)
[in]pStateThere are three valid values of the MRP port state
DISABLED
BLOCKING
FORWARDING
Return values
0on success

◆ PN_MRP_getPortState()

int32_t PN_MRP_getPortState ( PRUICSS_HwAttrs const *  pruicssHwAttrs,
uint8_t  portNumber,
uint8_t *  pState 
)

Returns the MRP state of a port.

Parameters
[in]pruicssHwAttrsPRUICSS HW Attributes for base addresses
[in]portNumberPort number whose MRP port state has to be returned
ICSS_EMAC_PORT_1 (1)
ICSS_EMAC_PORT_2 (2)
[in]pStateReference to the MRP port state of the port
Return values
0on success

◆ PN_enterFlushMode()

uint32_t PN_enterFlushMode ( PN_Handle  pnHandle)

Used to signal topology change to MRP state machine.

Parameters
pnHandleProfinet Handle
Returns
0 if we went to MRPENTER state
1 if already in flush operation
Precondition
MRP_SUPPORT defined

◆ PN_allCpmKnown()

uint32_t PN_allCpmKnown ( PN_Handle  pnHandle)

◆ PN_resetCpmPorts()

void PN_resetCpmPorts ( PN_Handle  pnHandle)

◆ PN_setCpmPort()

void PN_setCpmPort ( PN_Handle  pnHandle,
t_rtcPacket pID 
)