Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewBuffers ¶
func NewBuffers( frameSender arnetworkal.FrameSender, frameReceiver arnetworkal.FrameReceiver, c2dBufCfgs []C2DBufferConfig, d2cBufCfgs []D2CBufferConfig, ) (map[uint8]chan<- Frame, map[uint8]<-chan Frame, error)
NewBuffers returns maps of write-only channels for placing frames onto c2d buffers and read-only channels for receiving frames from d2c buffers. All channels are indexed by buffer ID.
Types ¶
type C2DBufferConfig ¶
type C2DBufferConfig struct { ID uint8 // Buffer ID 0 - 255 FrameType arnetworkal.FrameType // Type of data Size int32 // Size of the internal fifo MaxDataSize int32 // Maximum size of an element in the fifo IsOverwriting bool // What to do when data is received and the fifo is full AckTimeout time.Duration // Time before considering a frame lost MaxRetries int // Number of retries before considering a frame lost }
C2DBufferConfig represents the configuration of a buffer for frames being sent from the client to the device. nolint: lll
type D2CBufferConfig ¶
type D2CBufferConfig struct { ID uint8 // Buffer ID 0 - 255 FrameType arnetworkal.FrameType // Type of data Size int32 // Size of the internal fifo MaxDataSize int32 // Maximum size of an element in the fifo IsOverwriting bool // What to do when data is received and the fifo is full }
D2CBufferConfig represents the configuration of a buffer for frame sent from the device to the client. nolint: lll
Click to show internal directories.
Click to hide internal directories.