input

package
v0.0.0-...-684ac28 Latest Latest
Warning

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

Go to latest
Published: Jun 7, 2019 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// 256kb
	DataLen = 16 * 16384
	// microseconds
	PreambleUs   = 8
	LongMsgBits  = 112
	ShortMsgBits = 56
)
View Source
const (
	TypeModeS uint8 = iota
	TypeModeAC
)

Variables

View Source
var (
	FullLen     = PreambleUs + LongMsgBits
	DataLenComp = DataLen + (FullLen-1)*4

	RtlBadRate  = metrics.GetOrRegisterMeter("Message Rate (RTL Bad)", metrics.DefaultRegistry)
	RtlGoodRate = metrics.GetOrRegisterMeter("Message Rate (RTL Good)", metrics.DefaultRegistry)
)

Functions

func CRC

func CRC(msg []uint8, msgLen int) uint32

Types

type Demod

type Demod struct {
	MessageCh chan Message
	// contains filtered or unexported fields
}

func NewDemod

func NewDemod() *Demod

func (*Demod) Close

func (d *Demod) Close()

func (*Demod) DetectModeAC

func (d *Demod) DetectModeAC()

func (*Demod) DetectModeS

func (d *Demod) DetectModeS(chunk *SourceIQ)

type Message

type Message struct {
	Msg         []uint8
	ICAO        []uint8
	DF          uint8
	Type        uint8
	ReceiptTime time.Time
}

type RtlSdrScanner

type RtlSdrScanner struct {
	// contains filtered or unexported fields
}

func NewRtlSdrScanner

func NewRtlSdrScanner(dataLen int) *RtlSdrScanner

func (*RtlSdrScanner) Close

func (s *RtlSdrScanner) Close()

func (*RtlSdrScanner) Error

func (s *RtlSdrScanner) Error() error

func (*RtlSdrScanner) GetSourceIQCh

func (s *RtlSdrScanner) GetSourceIQCh() <-chan *SourceIQ

func (*RtlSdrScanner) Start

func (s *RtlSdrScanner) Start() error

type SourceIQ

type SourceIQ struct {
	Data        []uint8
	DataLen     int
	ReceiptTime time.Time
	// contains filtered or unexported fields
}

func NewSourceIQ

func NewSourceIQ(data []uint8, dataLen int) *SourceIQ

Jump to

Keyboard shortcuts

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