edisplitter

package module
v0.0.0-...-cc0dc38 Latest Latest
Warning

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

Go to latest
Published: May 29, 2020 License: Apache-2.0 Imports: 9 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

EdiSplitter

Receives AF packets from EdiHttp or other EDI sources and decodes the full DAB Ensemble into single service EDI streams. It also decodes DAB Dynamic Label Plus for segmentation of the linear radio programme for server based timeshift scenarios and DAB MOT SlideShow for visual thumbnails.

Documentation

Overview

edisplitter.go

Index

Constants

This section is empty.

Variables

View Source
var (
	MPendingToggle      = make(map[uint8]*DynamicLabel)
	MPendingToggleMutex = sync.RWMutex{}
)
View Source
var (
	MAfWrapMultiMap      map[uint8]uint16 = make(map[uint8]uint16)
	MAfWrapMultiMapMutex                  = sync.RWMutex{}
)
View Source
var DlPlusContentTypeString = []string{
	"DUMMY",
	"ITEM_TITLE",
	"ITEM_ALBUM",
	"ITEM_TRACKNUMBER",
	"ITEM_ARTIST",
	"ITEM_COMPOSITION",
	"ITEM_MOVEMENT",
	"ITEM_CONDUCTOR",
	"ITEM_COMPOSER",
	"ITEM_BAND",
	"ITEM_COMMENT",
	"ITEM_GENRE",
	"INFO_NEWS",
	"INFO_NEWS_LOCAL",
	"INFO_STOCKMARKET",
	"INFO_SPORT",
	"INFO_LOTTERY",
	"INFO_HOROSCOPE",
	"INFO_DAILY_DIVERSION",
	"INFO_HEALTH",
	"INFO_EVENT",
	"INFO_SCENE",
	"INFO_CINEMA",
	"INFO_TV",
	"INFO_DATE_TIME",
	"INFO_WEATHER",
	"INFO_TRAFFIC",
	"INFO_ALARM",
	"INFO_ADVERTISEMENT",
	"INFO_URL",
	"INFO_OTHER",
	"STATIONNAME_SHORT",
	"STATIONNAME_LONG",
	"PROGRAMME_NOW",
	"PROGRAMME_NEXT",
	"PROGRAMME_PART",
	"PROGRAMME_HOST",
	"PROGRAMME_EDITORIAL_STAFF",
	"PROGRAMME_FREQUENCY",
	"PROGRAMME_HOMEPAGE",
	"PROGRAMME_SUBCHANNEL",
	"PHONE_HOTLINE",
	"PHONE_STUDIO",
	"PHONE_OTHER",
	"SMS_STUDIO",
	"SMS_OTHER",
	"EMAIL_HOTLINE",
	"EMAIL_STUDIO",
	"EMAIL_OTHER",
	"MMS_OTHER",
	"CHAT",
	"CHAT_CENTER",
	"VOTE_QUESTION",
	"VOTE_CENTRE",

	"RFU_1",
	"RFU_2",

	"PRIVATE_CLASS_1",
	"PRIVATE_CLASS_2",
	"PRIVATE_CLASS_3",

	"DESCRIPTOR_PLACE",
	"DESCRIPTOR_APPOINTMENT",
	"DESCRIPTOR_IDENTIFIER",
	"DESCRIPTOR_PURCHASE",
	"DESCRIPTOR_GET_DATA",
}
View Source
var EBU_CHARSET = [16][16]string{

	{"\u0000", "\u0118", "\u012E", "\u0172", "\u0102", "\u0116", "\u010E", "\u0218", "\u021A", "\u010A", "\u0000", "\u0000", "\u0120", "\u0139", "\u017B", "\u0143"},
	{"\u0105", "\u0119", "\u012F", "\u0173", "\u0103", "\u0117", "\u010F", "\u0219", "\u021B", "\u010B", "\u0147", "\u011A", "\u0121", "\u013A", "\u017C", "\u0000"},
	{"\u0020", "\u0021", "\u0022", "\u0023", "\u0142", "\u0025", "\u0026", "\u0027", "\u0028", "\u0029", "\u002A", "\u002B", "\u002C", "\u002D", "\u002E", "\u002F"},
	{"\u0030", "\u0031", "\u0032", "\u0033", "\u0034", "\u0035", "\u0036", "\u0037", "\u0038", "\u0039", "\u003A", "\u003B", "\u003C", "\u003D", "\u003E", "\u003F"},
	{"\u0040", "\u0041", "\u0042", "\u0043", "\u0044", "\u0045", "\u0046", "\u0047", "\u0048", "\u0049", "\u004A", "\u004B", "\u004C", "\u004D", "\u004E", "\u004F"},
	{"\u0050", "\u0051", "\u0052", "\u0053", "\u0054", "\u0055", "\u0056", "\u0057", "\u0058", "\u0059", "\u005A", "\u005B", "\u016E", "\u005D", "\u0141", "\u005F"},
	{"\u0104", "\u0061", "\u0062", "\u0063", "\u0064", "\u0065", "\u0066", "\u0067", "\u0068", "\u0069", "\u006A", "\u006B", "\u006C", "\u006D", "\u006E", "\u006F"},
	{"\u0070", "\u0071", "\u0072", "\u0073", "\u0074", "\u0075", "\u0076", "\u0077", "\u0078", "\u0079", "\u007A", "\u00AB", "\u016F", "\u00BB", "\u013D", "\u0126"},
	{"\u00E1", "\u00E0", "\u00E9", "\u00E8", "\u00ED", "\u00EC", "\u00F3", "\u00F2", "\u00FA", "\u00F9", "\u00D1", "\u00C7", "\u015E", "\u00DF", "\u00A1", "\u0178"},
	{"\u00E2", "\u00E4", "\u00EA", "\u00EB", "\u00EE", "\u00EF", "\u00F4", "\u00F6", "\u00FB", "\u00FC", "\u00F1", "\u00E7", "\u015F", "\u011F", "\u0131", "\u00FF"},
	{"\u0136", "\u0145", "\u00A9", "\u0122", "\u011E", "\u011B", "\u0148", "\u0151", "\u0150", "\u20AC", "\u00A3", "\u0024", "\u0100", "\u0112", "\u012A", "\u016A"},
	{"\u0137", "\u0146", "\u013B", "\u0123", "\u013C", "\u0130", "\u0144", "\u0171", "\u0170", "\u00BF", "\u013E", "\u00B0", "\u0101", "\u0113", "\u012B", "\u016B"},
	{"\u00C1", "\u00C0", "\u00C9", "\u00C8", "\u00CD", "\u00CC", "\u00D3", "\u00D2", "\u00DA", "\u00D9", "\u0158", "\u010C", "\u0160", "\u017D", "\u00D0", "\u013F"},
	{"\u00C2", "\u00C4", "\u00CA", "\u00CB", "\u00CE", "\u00CF", "\u00D4", "\u00D6", "\u00DB", "\u00DC", "\u0159", "\u010D", "\u0161", "\u017E", "\u0111", "\u0140"},
	{"\u00C3", "\u00C5", "\u00C6", "\u0152", "\u0177", "\u00DD", "\u00D5", "\u00D8", "\u00DE", "\u014A", "\u0154", "\u0106", "\u015A", "\u0179", "\u0164", "\u00F0"},
	{"\u00E3", "\u00E5", "\u00E6", "\u0153", "\u0175", "\u00FD", "\u00F5", "\u00F8", "\u00FE", "\u014B", "\u0155", "\u0107", "\u015B", "\u017A", "\u0165", "\u0127"},
}
View Source
var EDI_PTR_TAG_0_0 = []byte{0x2A, 0x70, 0x74, 0x72, 0x00, 0x00, 0x00, 0x40, 0x44, 0x45, 0x54, 0x49, 0x00, 0x00, 0x00, 0x00}

*ptr Tag, MajorVersion 0, MinorVersion 0

View Source
var EDI_PTR_TAG_1_0 = []byte{0x2A, 0x70, 0x74, 0x72, 0x00, 0x00, 0x00, 0x40, 0x44, 0x45, 0x54, 0x49, 0x00, 0x01, 0x00, 0x00}

*ptr Tag, MajorVersion 1, MinorVersion 0

View Source
var FireCodeTable = [256]uint16{}/* 256 elements not displayed */
View Source
var MotContentSubTypeImageMime = []string{
	"image/gif",
	"image/jpeg",
	"image/bmp",
	"image/png",
}
View Source
var SubChannelSizeShortFormTable = map[uint8][3]uint16{
	0:  {16, 5, 32},
	1:  {21, 4, 32},
	2:  {24, 3, 32},
	3:  {29, 2, 32},
	4:  {35, 1, 32},
	5:  {24, 5, 48},
	6:  {29, 4, 48},
	7:  {35, 3, 48},
	8:  {42, 2, 48},
	9:  {52, 1, 48},
	10: {29, 5, 56},
	11: {35, 4, 56},
	12: {42, 3, 56},
	13: {52, 2, 56},
	14: {32, 5, 64},
	15: {42, 4, 64},
	16: {48, 3, 64},
	17: {58, 2, 64},
	18: {70, 1, 64},
	19: {40, 5, 80},
	20: {52, 4, 80},
	21: {58, 3, 80},
	22: {70, 2, 80},
	23: {84, 1, 80},
	24: {48, 5, 96},
	25: {58, 4, 96},
	26: {70, 3, 96},
	27: {84, 2, 96},
	28: {104, 1, 96},
	29: {58, 5, 112},
	30: {70, 4, 112},
	31: {84, 3, 112},
	32: {104, 2, 112},
	33: {64, 5, 128},
	34: {84, 4, 128},
	35: {96, 3, 128},
	36: {116, 2, 128},
	37: {140, 1, 128},
	38: {80, 5, 160},
	39: {104, 4, 160},
	40: {116, 3, 160},
	41: {140, 2, 160},
	42: {168, 1, 160},
	43: {96, 5, 192},
	44: {116, 4, 192},
	45: {140, 3, 192},
	46: {168, 2, 192},
	47: {208, 1, 192},
	48: {116, 5, 224},
	49: {140, 4, 224},
	50: {168, 3, 224},
	51: {208, 2, 224},
	52: {232, 1, 224},
	53: {128, 5, 256},
	54: {168, 4, 256},
	55: {192, 3, 256},
	56: {232, 2, 256},
	57: {280, 1, 256},
	58: {160, 5, 320},
	59: {208, 4, 320},
	60: {280, 2, 320},
	61: {192, 5, 384},
	62: {280, 3, 384},
	63: {416, 1, 384},
}
View Source
var SubchannelCodingRate = map[uint8][]uint8{
	0: {12, 8, 6, 4},
	1: {27, 21, 18, 15},
}
View Source
var XPadSize = [8]uint8{
	4, 6, 8, 12, 16, 24, 32, 48,
}

Functions

func AssembleFioFrame

func AssembleFioFrame(afFrame []byte) []byte

EDI file assembling

func CheckFireCode

func CheckFireCode(frameData []byte) bool

func CreateDetiAF

func CreateDetiAF(dabSrvPtr *DabSrv) (aFrame []byte)

Creates an Application Frame containing only 'deti' Tags. There may be more than one 'deti' Tag inside the AF if the complete FIC data doesn't fit into the 3*30 bytes of the FIC fields

func CreateDlptTag

func CreateDlptTag(dLabel *DynamicLabel) (dlptTag []byte)

func InsertCustomLiveTag

func InsertCustomLiveTag(afFrame []byte, customTag []byte) (customizedAfFrame []byte)

func MjdToYMD

func MjdToYMD(mjd int) (year int, month int, day int)

func ParseEdiData

func ParseEdiData(ediInputchan chan []byte)

func ParseFib

func ParseFib(fibSlice []byte)

Parses a 32 byte Fast Information Block

func RegisterServicesReadyCallbackNew

func RegisterServicesReadyCallbackNew(callback ServicesReadyCallbackNew)

func RegisterSlideshowCallback

func RegisterSlideshowCallback(callback SlideshowCallback)

func RegisterToggleCallback

func RegisterToggleCallback(callback ToggleCallback)

func SetAfVersion

func SetAfVersion(afVersion int)

func SetVerbosity

func SetVerbosity(verbose bool)

func UnregisterServicesReadyCallbackNew

func UnregisterServicesReadyCallbackNew(callback ServicesReadyCallbackNew)

Types

type DabSrv

type DabSrv struct {
	//ensemble data
	EnsembleId         uint16
	EnsembleEcc        uint8
	EnsembleLabel      string
	EnsembleShortLabel string

	//service data
	ServiceId         uint32 //this 16-bit or 32-bit field shall identify the service
	ServiceLabel      string
	ServiceShortLabel string

	CAId uint8 //this 3-bit field shall identify the Access Control System (ACS) used for the service

	NumSrvComponents     uint8 //this 4-bit field, coded as an unsigned binary number, shall indicate the number of service components (maximum 12 for 16-bit SIds and maximum 11 for 32-bit SIds), associated with the service
	DabServiceComponents []*DabSrvComponent

	IsProgramme bool

	Figs DabSrvFigs

	//EDI data
	DetiFields []byte
	EstData    []byte

	AfFrameOutput chan []byte
	// contains filtered or unexported fields
}

type DabSrvComponent

type DabSrvComponent struct {
	ServiceComponentId         uint16 //this 12-bit field shall uniquely identify the service component within the ensemble - Only available for PacketMode Data Services
	ServiceComponentLabel      string
	ServiceComponentShortLabel string
	SCIDs                      uint8 //(Service Component Identifier within the Service. this 4-bit field shall identify the service component within the service. The combination of the SId and the SCIdS provides a globally valid identifier for a service component
	ServiceId                  uint32
	TransportModeId            TransportMechanism    //this 2-bit field shall indicate the transport mechanism used. 0 = MSC Stream Audio. 1 = MSC Stream Data. 2 = RFU. 3 = MSC Packet Mode Data.
	ASCTy                      uint8                 //this 6-bit field shall indicate the type of the audio service component. The interpretation of this field shall be as defined in ETSI TS 101 756, table 2a.
	DSCTy                      uint8                 // this 6-bit field shall indicate the transport protocol used by the data service component. The interpretation of this field shall be as defined in ETSI TS 101 756, table 2b.
	SubChannelId               uint8                 //this 6-bit field shall identify the sub-channel in which the service component is carried.
	IsPrimary                  bool                  //this 1-bit flag shall indicate whether the service component is the primary one. 0: not primary (secondary); 1: primary.
	IsCaProtected              bool                  //this 1-bit field flag shall indicate whether access control applies to the service component. 0: no access control; 1: access control applies to the whole of the service component.
	UserApplications           []*DabUserApplication //User Applications associated with this DabSrvComponent
	//Packet Mode only
	CaOrg          uint16 //this 16-bit field shall contain information about the applied Conditional Access Systems and mode
	DataGroupsUsed bool   //this 1-bit flag shall indicate whether the Conditional Access Organization (CAOrg) field is present, or not. 0: data groups are used to transport the service component; 1: data groups are not used to transport the service component.
	PacketAddress  uint16 //this 10-bit field shall define the address of the packet in which the service component is carried.

	Subchannel *DabSrvSubchannel

	FIG_0_02      []byte
	FIG_0_02_done bool
	FIG_0_08      []byte
	FIG_0_08_done bool

	FIG_1_04      []byte
	FIG_1_04_done bool
	// contains filtered or unexported fields
}

type DabSrvFigs

type DabSrvFigs struct {
	//Ensemble info
	Fig_0_00 []byte

	//Subchannel organisation
	Fig_0_01 []byte
	//Service component information
	Fig_0_02 []byte
	//Service component global definition
	Fig_0_08 []byte
	//Country, LTO and international table
	Fig_0_09      []byte
	Fig_0_09_done bool
	//Date and Time
	Fig_0_10 []byte

	//User applications
	Fig_0_13 []byte
	//Programme Type
	Fig_0_17 []byte

	//Labels
	//Ensemble Label
	Fig_1_00      []byte
	Fig_1_00_done bool
	//Programme Service Label
	Fig_1_01      []byte
	Fig_1_01_done bool
	//Service Component Label
	Fig_1_04 []byte
	//X-PAD user application label
	Fig_1_06 []byte
	//Data Service Label
	Fig_1_05      []byte
	Fig_1_05_done bool
	// contains filtered or unexported fields
}

type DabSrvSubchannel

type DabSrvSubchannel struct {
	SubchannelId      uint8  //this 6-bit field, coded as an unsigned binary number, shall identify a sub-channel.
	StartAddress      uint16 //10-bit field, coded as an unsigned binary number (in the range 0 to 863), shall address the first Capacity Unit (CU) of the sub-channel
	ProtectionLevel   uint8  //this 2-bit field shall indicate the protection level
	SubchannelSize    uint16 //defines the number of Capacity Units occupied by the sub-channel
	SubchannelBitrate uint16 //the bitrate of the subchannel in kbit/s
	FecScheme         uint8  //for packet mode components ONLY. this 2-bit field shall indicate the Forward Error Correction scheme in use

	Fig_0_01      []byte
	Fig_0_01_done bool

	FIG_0_14      []byte
	FIG_0_14_done bool

	MscInput chan MscAf
}

type DabSuperframe

type DabSuperframe struct {
	SamplingRate int
	Channels     int
	Sbr          bool
	Ps           bool
}

type DabUserApplication

type DabUserApplication struct {
	ServiceId         uint32 //
	SCIDs             uint8  //(Service Component Identifier within the Service. this 4-bit field shall identify the service component within the service. The combination of the SId and the SCIdS provides a globally valid identifier for a service component
	UAppType          uint16 //this 11-bit field identifies the user application that shall be used to decode the data in the channel identified by SId and SCIdS. The interpretation of this field shall be as defined in ETSI TS 101 756, table 16.
	IsXpadApp         bool   //indicates if this application is carried as X-PAD
	XpadAppType       uint8  //this 5-bit field shall specify the lowest numbered application type used to transport this user application
	XpadAppLabel      string
	XpadAppShortLabel string
	DataGroupsUsed    bool //this 1-bit flag shall indicate whether MSC data groups are used to transport the user application
	DSCTy             uint8
	IsCaProtected     bool   //indicates if this application is protected by conditional access mechanism
	CaOrg             uint16 //this 16-bit field shall contain information about the Conditional Access Systems and mode, if present
	UAppData          []byte //these 8-bit fields may be used to signal application specific information. The interpretation of these fields is determined by the user application identified by the User Application Type.

	FIG_0_13      []byte
	FIG_0_13_done bool

	FIG_1_06      []byte
	FIG_1_06_done bool
}

type DlPlusContentType

type DlPlusContentType uint8
const (
	DLP_CONTENT_TYPE_DUMMY            DlPlusContentType = 0
	DLP_CONTENT_TYPE_ITEM_TITLE       DlPlusContentType = 1
	DLP_CONTENT_TYPE_ITEM_ALBUM       DlPlusContentType = 2
	DLP_CONTENT_TYPE_ITEM_TRACKNUMBER DlPlusContentType = 3
	DLP_CONTENT_TYPE_ITEM_ARTIST      DlPlusContentType = 4
	DLP_CONTENT_TYPE_ITEM_COMPOSITION DlPlusContentType = 5
	DLP_CONTENT_TYPE_ITEM_MOVEMENT    DlPlusContentType = 6
	DLP_CONTENT_TYPE_ITEM_CONDUCTOR   DlPlusContentType = 7
	DLP_CONTENT_TYPE_ITEM_COMPOSER    DlPlusContentType = 8
	DLP_CONTENT_TYPE_ITEM_BAND        DlPlusContentType = 9
	DLP_CONTENT_TYPE_ITEM_COMMENT     DlPlusContentType = 10
	DLP_CONTENT_TYPE_ITEM_GENRE       DlPlusContentType = 11

	DLP_CONTENT_TYPE_INFO_NEWS                 DlPlusContentType = 12
	DLP_CONTENT_TYPE_INFO_NEWS_LOCAL           DlPlusContentType = 13
	DLP_CONTENT_TYPE_INFO_STOCKMARKET          DlPlusContentType = 14
	DLP_CONTENT_TYPE_INFO_SPORT                DlPlusContentType = 15
	DLP_CONTENT_TYPE_INFO_LOTTERY              DlPlusContentType = 16
	DLP_CONTENT_TYPE_INFO_HOROSCOPE            DlPlusContentType = 17
	DLP_CONTENT_TYPE_INFO_DAILY_DIVERSION      DlPlusContentType = 18
	DLP_CONTENT_TYPE_INFO_HEALTH               DlPlusContentType = 19
	DLP_CONTENT_TYPE_INFO_EVENT                DlPlusContentType = 20
	DLP_CONTENT_TYPE_INFO_SCENE                DlPlusContentType = 21
	DLP_CONTENT_TYPE_INFO_CINEMA               DlPlusContentType = 22
	DLP_CONTENT_TYPE_INFO_TV                   DlPlusContentType = 23
	DLP_CONTENT_TYPE_INFO_DATE_TIME            DlPlusContentType = 24
	DLP_CONTENT_TYPE_INFO_WEATHER              DlPlusContentType = 25
	DLP_CONTENT_TYPE_INFO_TRAFFIC              DlPlusContentType = 26
	DLP_CONTENT_TYPE_INFO_ALARM                DlPlusContentType = 27
	DLP_CONTENT_TYPE_INFO_ADVERTISEMENT        DlPlusContentType = 28
	DLP_CONTENT_TYPE_INFO_URL                  DlPlusContentType = 29
	DLP_CONTENT_TYPE_INFO_OTHER                DlPlusContentType = 30
	DLP_CONTENT_TYPE_STATIONNAME_SHORT         DlPlusContentType = 31
	DLP_CONTENT_TYPE_STATIONNAME_LONG          DlPlusContentType = 32
	DLP_CONTENT_TYPE_PROGRAMME_NOW             DlPlusContentType = 33
	DLP_CONTENT_TYPE_PROGRAMME_NEXT            DlPlusContentType = 34
	DLP_CONTENT_TYPE_PROGRAMME_PART            DlPlusContentType = 35
	DLP_CONTENT_TYPE_PROGRAMME_HOST            DlPlusContentType = 36
	DLP_CONTENT_TYPE_PROGRAMME_EDITORIAL_STAFF DlPlusContentType = 37
	DLP_CONTENT_TYPE_PROGRAMME_FREQUENCY       DlPlusContentType = 38
	DLP_CONTENT_TYPE_PROGRAMME_HOMEPAGE        DlPlusContentType = 39
	DLP_CONTENT_TYPE_PROGRAMME_SUBCHANNEL      DlPlusContentType = 40
	DLP_CONTENT_TYPE_PHONE_HOTLINE             DlPlusContentType = 41
	DLP_CONTENT_TYPE_PHONE_STUDIO              DlPlusContentType = 42
	DLP_CONTENT_TYPE_PHONE_OTHER               DlPlusContentType = 43
	DLP_CONTENT_TYPE_SMS_STUDIO                DlPlusContentType = 44
	DLP_CONTENT_TYPE_SMS_OTHER                 DlPlusContentType = 45
	DLP_CONTENT_TYPE_EMAIL_HOTLINE             DlPlusContentType = 46
	DLP_CONTENT_TYPE_EMAIL_STUDIO              DlPlusContentType = 47
	DLP_CONTENT_TYPE_EMAIL_OTHER               DlPlusContentType = 48
	DLP_CONTENT_TYPE_MMS_OTHER                 DlPlusContentType = 49
	DLP_CONTENT_TYPE_CHAT                      DlPlusContentType = 50
	DLP_CONTENT_TYPE_CHAT_CENTER               DlPlusContentType = 51
	DLP_CONTENT_TYPE_VOTE_QUESTION             DlPlusContentType = 52
	DLP_CONTENT_TYPE_VOTE_CENTRE               DlPlusContentType = 53

	DLP_CONTENT_TYPE_RFU_1 DlPlusContentType = 54
	DLP_CONTENT_TYPE_RFU_2 DlPlusContentType = 55

	DLP_CONTENT_TYPE_PRIVATE_CLASS_1 DlPlusContentType = 56
	DLP_CONTENT_TYPE_PRIVATE_CLASS_2 DlPlusContentType = 57
	DLP_CONTENT_TYPE_PRIVATE_CLASS_3 DlPlusContentType = 58

	DLP_CONTENT_TYPE_DESCRIPTOR_PLACE       DlPlusContentType = 59
	DLP_CONTENT_TYPE_DESCRIPTOR_APPOINTMENT DlPlusContentType = 60
	DLP_CONTENT_TYPE_DESCRIPTOR_IDENTIFIER  DlPlusContentType = 61
	DLP_CONTENT_TYPE_DESCRIPTOR_PURCHASE    DlPlusContentType = 62
	DLP_CONTENT_TYPE_DESCRIPTOR_GET_DATA    DlPlusContentType = 63
)

type DlPlusTag

type DlPlusTag struct {
	DlPlusContentType     `json:"type"`
	DlPlusContentTypeDesc string `json:"typeDescription"`
	DlPlusTagText         string `json:"text"`
}

type DlsCommand

type DlsCommand uint8
const (
	DLS_COMMAND_UNKNOWN       DlsCommand = 0
	DLS_COMMAND_CLEAR_DISPLAY DlsCommand = 1
	DLS_COMMAND_DL_PLUS       DlsCommand = 2
)

type DlsDataProcessor

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

type DlsSegmentType

type DlsSegmentType uint8
const (
	DLS_SEGMENT_INTERMEDIATE DlsSegmentType = 0
	DLS_SEGMENT_LAST         DlsSegmentType = 1
	DLS_SEGMENT_FIRST        DlsSegmentType = 2
	DLS_SEGMENT_ONE_AND_ONLY DlsSegmentType = 3
)

type DynamicLabel

type DynamicLabel struct {
	FullLabel        string      `json:"label"`
	Tags             []DlPlusTag `json:"tags"`
	ItemToggleState  bool        `json:"toggleState"`
	ItemRunningState bool        `json:"runningState"`

	//
	SubchanId   uint8  `json:"-"`
	AfSeqNum    uint16 `json:"-"`
	AfMulti     uint16 `json:"-"`
	ReceiveTime int64  `json:"time"`
	ToggleId    int64  `json:"id"`
	SlidePath   string `json:"slidePath"`
	SlideMime   string `json:"slideMime"`
}

type FigExtension

type FigExtension uint8
const (
	//FIG 00 Extension 00 - Ensemble information
	ENSEMBLE_INFORMATION FigExtension = 0
	//FIG 00 Extension 01 - Basic sub-channel organization
	BASIC_SUBCHANNEL_ORGANIZATION FigExtension = 1
	//FIG 00 Extension 02 - Basic service and service component definition
	BASIC_SERVICE_COMPONENT_DEFINITION FigExtension = 2
	//FIG 00 Extension 03 - Service component in packet mode with or without Conditional Access
	SERVICE_COMPONENT_PACKET_MODE FigExtension = 3
	//FIG 00 Extension 04 - Service component with Conditional Access in stream mode
	SERVICE_COMPONENT_STREAM_CA FigExtension = 4
	//FIG 00 Extension 05 - Service component language
	SERVICE_COMPONENT_LANGUAGE FigExtension = 5
	//FIG 00 Extension 06 - Service linking information
	SERVICE_LINKING_INFORMATION FigExtension = 6
	//FIG 00 Extension 07 - Configuration information
	CONFIGURATION_INFORMATION FigExtension = 7
	//FIG 00 Extension 08 - Service component global definition
	SERVICE_COMPONENT_GLOBAL_DEFINITION FigExtension = 8
	//FIG 00 Extension 09 - Country, LTO and International table
	COUNTRY_LTO_INTERNATIONAL_TABLE FigExtension = 9
	//FIG 00 Extension 10 - Date and time (d&t)
	DATE_AND_TIME FigExtension = 10
	//FIG 00 Extension 13 - User application information
	USERAPPLICATION_INFORMATION FigExtension = 13
	//FIG 00 Extension 14 - FEC sub-channel organization
	FEC_SUBCHANNEL_ORGANIZATION FigExtension = 14
	//FIG 00 Extension 17 - Programme Type
	PROGRAMME_TYPE FigExtension = 17
	//FIG 00 Extension 18 - Announcement support
	ANNOUNCEMENT_SUPPORT FigExtension = 18
	//FIG 00 Extension 19 - Announcement switching
	ANNOUNCEMENT_SWITCHING FigExtension = 19
	//FIG 00 Extension 20 - Service Component Information
	SERVICE_COMPONENT_INFORMATION FigExtension = 20
	//FIG 00 Extension 21 - Frequency Information
	FREQUENCY_INFORMATION FigExtension = 21
	//FIG 00 Extension 24 - OE Services
	OE_SERVICES FigExtension = 24
	//FIG 00 Extension 25 - OE Announcement support
	OE_ANNOUNCEMENT_SUPPORT FigExtension = 25
	//FIG 00 Extension 26 - OE Announcement switching
	OE_ANNOUNCEMENT_SWITCHING FigExtension = 26

	//FIG 01/02 Extension 00 - Ensemble label
	ENSEMBLE_LABEL FigExtension = 0
	//FIG 01/02 Extension 01 - Programme service label
	PROGRAMME_SERVICE_LABEL FigExtension = 1
	//FIG 01/02 Extension 04 - Service component label
	SERVICE_COMPONENT_LABEL FigExtension = 4
	//FIG 01/02 Extension 05 - Data service label
	DATA_SERVICE_LABEL FigExtension = 5
	//FIG 01/02 Extension 06 - X-PAD user application label
	XPAD_USERAPPLICATION_LABEL FigExtension = 6
)

type FigType

type FigType uint8

FIC

const (
	FIG_TYPE_0 FigType = 0
	FIG_TYPE_1 FigType = 1
)

type MotContentSubTypeImage

type MotContentSubTypeImage uint16

MotContentType == MOT_CONTENT_TYPE_IMAGE

const (
	MOT_CONTENT_SUBTYPE_IMAGE_GIF  MotContentSubTypeImage = 0
	MOT_CONTENT_SUBTYPE_IMAGE_JPEG MotContentSubTypeImage = 1
	MOT_CONTENT_SUBTYPE_IMAGE_BMP  MotContentSubTypeImage = 2
	MOT_CONTENT_SUBTYPE_IMAGE_PNG  MotContentSubTypeImage = 3
)

type MotContentType

type MotContentType uint8
const (
	MOT_CONTENT_TYPE_GENERAL_DATA  MotContentType = 0
	MOT_CONTENT_TYPE_TEXT          MotContentType = 1
	MOT_CONTENT_TYPE_IMAGE         MotContentType = 2
	MOT_CONTENT_TYPE_AUDIO         MotContentType = 3
	MOT_CONTENT_TYPE_VIDEO         MotContentType = 4
	MOT_CONTENT_TYPE_MOT_TRANSPORT MotContentType = 5
	MOT_CONTENT_TYPE_SYSTEM        MotContentType = 6
	MOT_CONTENT_TYPE_APPLICATION   MotContentType = 7
	MOT_CONTENT_TYPE_PROPRIETARY   MotContentType = 8
)

type MotDatagroupBuilder

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

type MotDatagroupType

type MotDatagroupType uint8
const (
	MOT_DG_TYPE_GENERAL_DATA           MotDatagroupType = 0
	MOT_DG_TYPE_CA_MESSAGE             MotDatagroupType = 1
	MOT_DG_TYPE_HEADER                 MotDatagroupType = 3
	MOT_DG_TYPE_BODY_UNSCRAMBLED       MotDatagroupType = 4
	MOT_DG_TYPE_BODY_SCRAMBLED         MotDatagroupType = 5
	MOT_DG_TYPE_DIRECTORY_UNCOMPRESSED MotDatagroupType = 6
	MOT_DG_TYPE_DIRECTORY_COMPRESSED   MotDatagroupType = 7
)

type MotObject

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

type MotSlideshow

type MotSlideshow struct {
	SubchannelId uint8
	MotContentType
	MotContentSubTypeImage
	ContentName   string
	TriggerTime   time.Time
	ReceiveTime   time.Time
	ContentMime   string
	CategoryId    uint8
	CategoryTitle string
	SlideId       uint8
	ImageData     []byte
}

type MotSlideshowHeaderParam

type MotSlideshowHeaderParam uint8
const (
	MOT_SLS_HEADER_PARAM_EXPIRE_TIME       MotSlideshowHeaderParam = 0x04
	MOT_SLS_HEADER_PARAM_TRIGGER_TIME      MotSlideshowHeaderParam = 0x05
	MOT_SLS_HEADER_PARAM_CONTENT_NAME      MotSlideshowHeaderParam = 0x0C
	MOT_SLS_HEADER_PARAM_CAT_SLIDE_ID      MotSlideshowHeaderParam = 0x25
	MOT_SLS_HEADER_PARAM_CAT_TITLE         MotSlideshowHeaderParam = 0x26
	MOT_SLS_HEADER_PARAM_CLICK_THROUGH_URL MotSlideshowHeaderParam = 0x27
	MOT_SLS_HEADER_PARAM_ALT_LOCATION_URL  MotSlideshowHeaderParam = 0x28
	MOT_SLS_HEADER_PARAM_ALERT             MotSlideshowHeaderParam = 0x29
)

type MscAf

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

type PadApplicationType

type PadApplicationType uint8
const (
	PAD_APP_END_MARKER                  PadApplicationType = 0
	PAD_APP_DATA_GROUP_LENGTH_INDICATOR PadApplicationType = 1
	PAD_APP_DLS_DATAGROUP_START         PadApplicationType = 2
	PAD_APP_DLS_DATAGROUP_CONTINUATION  PadApplicationType = 3
	//4-11 user defined
	PAD_APP_MOT_DATAGROUP_START         PadApplicationType = 12
	PAD_APP_MOT_DATAGROUP_CONTINUATION  PadApplicationType = 13
	PAD_APP_MOT_CA_MESSAGE_START        PadApplicationType = 14
	PAD_APP_MOT_CA_MESSAGE_CONTINUATION PadApplicationType = 15
	//16 - 31 user defined
	PAD_APP_NOT_USED PadApplicationType = 31
)

type PadDataProcessor

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

type ServicesReadyCallbackNew

type ServicesReadyCallbackNew func(dabServices []*DabSrv)

TODO try callback channel

type SlideshowCallback

type SlideshowCallback func(sls MotSlideshow)

type ToggleCallback

type ToggleCallback func(dLabel DynamicLabel)

type TransportMechanism

type TransportMechanism uint8
const (
	MSC_STREAM_MODE_AUDIO TransportMechanism = 0
	MSC_STREAM_MODE_DATA  TransportMechanism = 1
	MSC_TMID_MODE_UNKNOWN TransportMechanism = 2
	MSC_PACKET_MODE_DATA  TransportMechanism = 3
)

type XPadIndicator

type XPadIndicator uint8
const (
	//ENSEMBLE_INFORMATION FigExtension = 0
	No_Xpad       XPadIndicator = 0
	Short_Xpad    XPadIndicator = 1
	Variable_Xpad XPadIndicator = 2
	RFU_XPad      XPadIndicator = 3
)

Jump to

Keyboard shortcuts

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