Documentation ¶
Overview ¶
rtldavis, an rtl-sdr receiver for Davis Instruments weather stations. Copyright (C) 2015 Douglas Hall
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>.
Index ¶
Constants ¶
const IQBYTES_PER_BLOCK = SAMPLES_PER_BLOCK * IQBYTES_PER_SAMPLE
const IQBYTES_PER_SAMPLE = 2
const SAMPLES_PER_BLOCK = 512
Variables ¶
This section is empty.
Functions ¶
func FIR9 ¶
func FIR9(in, out []complex128)
Types ¶
type ByteToCmplxLUT ¶
type ByteToCmplxLUT [256]float64
func NewByteToCmplxLUT ¶
func NewByteToCmplxLUT() (lut ByteToCmplxLUT)
func (*ByteToCmplxLUT) Execute ¶
func (l *ByteToCmplxLUT) Execute(in []byte, out []complex128)
type Demodulator ¶
type Demodulator struct { Cfg *PacketConfig Raw []byte IQ []complex128 Filtered []complex128 Discriminated []float64 Quantized []byte // contains filtered or unexported fields }
func NewDemodulator ¶
func NewDemodulator(cfg *PacketConfig) (d Demodulator)
func (*Demodulator) Demodulate ¶
func (d *Demodulator) Demodulate(input []byte) []Packet
func (*Demodulator) Discriminate ¶
func (d *Demodulator) Discriminate(in []complex128, out []float64)
func (*Demodulator) Pack ¶
func (d *Demodulator) Pack(input []byte)
func (*Demodulator) Reset ¶
func (d *Demodulator) Reset()
func (*Demodulator) Search ¶
func (d *Demodulator) Search() (indexes []int)
func (*Demodulator) Slice ¶
func (d *Demodulator) Slice(indices []int) (pkts []Packet)
type PacketConfig ¶
type PacketConfig struct { SymbolsPerByte int BitRate int SymbolLength int PreambleSymbols, PacketSymbols int Preamble string PreambleBytes []byte PreambleFinder *byteFinder SampleRate int BlockSize, BlockSize2 int PreambleLength, PacketLength int BufferLength int }
PacketConfig specifies packet-specific radio configuration.
func NewPacketConfig ¶
func NewPacketConfig(symbolsPerByte, bitRate, symbolLength, preambleSymbols, packetSymbols int, preamble string) PacketConfig
func (PacketConfig) Log ¶
func (cfg PacketConfig) Log()