checker

package
v0.0.0-...-a34aaee Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 23, 2021 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PrepareClient

func PrepareClient(address string) (c *ptp.MgmtClient, cleanup func(), err error)

PrepareClient creates a ptp.MgmtClient with connection to ptp4l over unix socket

Types

type PTPCheckResult

type PTPCheckResult struct {
	OffsetFromMasterNS  float64
	GrandmasterPresent  bool
	StepsRemoved        int
	MeanPathDelayNS     float64
	ClockIdentity       string
	GrandmasterIdentity string
	IngressTimeNS       int64
	PortStatsTX         map[string]uint64
	PortStatsRX         map[string]uint64
}

PTPCheckResult is selected parts of various stats we expose to users, abstracting away protocol implementation

func Run

func Run(c *ptp.MgmtClient) (*PTPCheckResult, error)

Run will talk over conn and return PTPCheckResult

func RunCheck

func RunCheck(address string) (*PTPCheckResult, error)

RunCheck is a simple wrapper to connect to address and run Run()

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL