AM263Px MCU+ SDK  10.01.00
timeSync_RuntimeVar_t Struct Reference

Detailed Description

Runtime variables for Time Sync implementation.

Data Fields

uint8_t enabled
 
uint8_t stateMachine
 PTP State machine used internally by driver This is a bitmap Bit 0 : Set 1 if First adjustment done Bit 1 : Set 1 if delay has been computed Bit 2 : Set 1 if sync interval has been computed Bit 3 : Set 1 if device is in sync with master if first 3 bits are set then clock adjustment is performed. More...
 
uint16_t pDelReqSequenceID [ICSS_EMAC_MAX_PORTS_PER_INSTANCE]
 
uint16_t delReqSequenceID
 
uint16_t syncSequenceID
 
uint16_t announceSequenceID
 
uint16_t curSyncSeqId [ICSS_EMAC_MAX_PORTS_PER_INSTANCE]
 
uint32_t currSyncInterval
 
uint32_t ltaSyncInterval
 
uint32_t firstSyncInterval
 
int32_t currOffset
 
int32_t prevOffset [2]
 
int32_t prevOffsetValid [2]
 
int32_t initialOffset
 
uint8_t driftStable
 
uint8_t offsetStable
 
uint8_t syncPortNum
 
uint32_t pathDelay [ICSS_EMAC_MAX_PORTS_PER_INSTANCE]
 
int64_t meanPathDelay
 
uint32_t clockDrift
 
int32_t ltaOffset
 
int32_t ltaOffsetValid
 
uint32_t avgCorrectionField
 
uint64_t tickCounter
 
uint32_t syncLastSeenCounter
 
uint32_t syncTimeoutInterval
 
uint8_t forced2step [ICSS_EMAC_MAX_PORTS_PER_INSTANCE]
 
uint8_t bmcaDone
 
TimeSync_master_params_t masterParams
 
TimeSync_parent_params_t parentParams
 

Field Documentation

◆ enabled

uint8_t timeSync_RuntimeVar_t::enabled

Enable/Disable status

◆ stateMachine

uint8_t timeSync_RuntimeVar_t::stateMachine

PTP State machine used internally by driver This is a bitmap Bit 0 : Set 1 if First adjustment done Bit 1 : Set 1 if delay has been computed Bit 2 : Set 1 if sync interval has been computed Bit 3 : Set 1 if device is in sync with master if first 3 bits are set then clock adjustment is performed.

PTP State machine. This is a bitmask

◆ pDelReqSequenceID

uint16_t timeSync_RuntimeVar_t::pDelReqSequenceID[ICSS_EMAC_MAX_PORTS_PER_INSTANCE]

Sequence ID to be sent for Delay Request/Pdelay Request packets

◆ delReqSequenceID

uint16_t timeSync_RuntimeVar_t::delReqSequenceID

Sequence ID used for Delay request frames

◆ syncSequenceID

uint16_t timeSync_RuntimeVar_t::syncSequenceID

Sequence ID used for Sync frames

◆ announceSequenceID

uint16_t timeSync_RuntimeVar_t::announceSequenceID

Sequence ID used for announce frames

◆ curSyncSeqId

uint16_t timeSync_RuntimeVar_t::curSyncSeqId[ICSS_EMAC_MAX_PORTS_PER_INSTANCE]

Current sequence id from Sync frame

◆ currSyncInterval

uint32_t timeSync_RuntimeVar_t::currSyncInterval

Sync interval between last two sync frames

◆ ltaSyncInterval

uint32_t timeSync_RuntimeVar_t::ltaSyncInterval

Long term average calculated using an exponential filter

◆ firstSyncInterval

uint32_t timeSync_RuntimeVar_t::firstSyncInterval

First sync interval value

◆ currOffset

int32_t timeSync_RuntimeVar_t::currOffset

Offset from master : current value

◆ prevOffset

int32_t timeSync_RuntimeVar_t::prevOffset[2]

Offset from master : previous values. prevOffset[0] is the old value of currOffset. prevOffset[1] is the old value of prevOffset[0].

◆ prevOffsetValid

int32_t timeSync_RuntimeVar_t::prevOffsetValid[2]

◆ initialOffset

int32_t timeSync_RuntimeVar_t::initialOffset

Initial offset. Taken when adjustment settles down.

◆ driftStable

uint8_t timeSync_RuntimeVar_t::driftStable

◆ offsetStable

uint8_t timeSync_RuntimeVar_t::offsetStable

◆ syncPortNum

uint8_t timeSync_RuntimeVar_t::syncPortNum

Port number on which master is connected

◆ pathDelay

uint32_t timeSync_RuntimeVar_t::pathDelay[ICSS_EMAC_MAX_PORTS_PER_INSTANCE]

Line delay or Peer Delay for each port

◆ meanPathDelay

int64_t timeSync_RuntimeVar_t::meanPathDelay

◆ clockDrift

uint32_t timeSync_RuntimeVar_t::clockDrift

Difference between current and previous offset

◆ ltaOffset

int32_t timeSync_RuntimeVar_t::ltaOffset

◆ ltaOffsetValid

int32_t timeSync_RuntimeVar_t::ltaOffsetValid

◆ avgCorrectionField

uint32_t timeSync_RuntimeVar_t::avgCorrectionField

Running average of correction field in Sync frame

◆ tickCounter

uint64_t timeSync_RuntimeVar_t::tickCounter

background tick counter, increments inside TimeSync_BackgroundTask()

◆ syncLastSeenCounter

uint32_t timeSync_RuntimeVar_t::syncLastSeenCounter

Ageing counter to detect missed Sync frames

◆ syncTimeoutInterval

uint32_t timeSync_RuntimeVar_t::syncTimeoutInterval

Ageing counter is compared against this value to detect missed sync frames. 1.5x the sync interval

◆ forced2step

uint8_t timeSync_RuntimeVar_t::forced2step[ICSS_EMAC_MAX_PORTS_PER_INSTANCE]

Flag to indicate that forced 2-step mode is active

◆ bmcaDone

uint8_t timeSync_RuntimeVar_t::bmcaDone

◆ masterParams

TimeSync_master_params_t timeSync_RuntimeVar_t::masterParams

Grand master parameters like priority 1, priority 2 etc. Populated in Announce frame

◆ parentParams

TimeSync_parent_params_t timeSync_RuntimeVar_t::parentParams

Parent clock parameters