|
- package rds
-
- // RDSConfig holds configuration data used to build the RDS data stream.
- type RDSConfig struct {
- // Program Identification – 16-bit school identifier for the broadcast.
- PI uint16
-
- // Program Service name (typically 8 ASCII characters).
- PS string
-
- // RadioText (up to 64 characters). Short messages describing the current song or info.
- RT string
-
- // Program Type (0-31 standard RDS PTY values).
- PTY uint8
-
- // Traffic Announcement (TA) flag.
- TA bool
-
- // Traffic Program (TP) flag.
- TP bool
-
- // SampleRate that the encoder will work against. Defaults to 48000 when zero.
- SampleRate float64
- }
-
- // DefaultConfig returns a minimal config with sane defaults.
- func DefaultConfig() RDSConfig {
- return RDSConfig{
- PI: 0x1234,
- PS: "FM-RDS",
- RT: "Go-based MPX",
- PTY: 0,
- TA: false,
- TP: false,
- SampleRate: 48000,
- }
- }
|