Astra. Media Address Format

The square brackets indicates an optional part of the example

Introduction

Media Address describes the location and parameters of the source and destination. Address format:

module://address#options
  • module
  • address — address of the source or destination. Each module has own format of the address
  • options — options could be General and Specific. General options - could be used with any module. Specific options - each module may have the additional options

DVB

DVB module available for Input only.

DVB module supports two formats of address. First is address with DVB identifier:

dvb://dvb-id
  • dvb-id — identifier of the DVB adapter. Defined in the adapter options

The second is an address with all options to tune an adapter. This method could be used in the Astra Femon and in the Astra Analyze. Examples:

  • astra --femon "dvb://#adapter=0&type=S2&tp=11044:v:43200"

Additional options for Input:

UDP/RTP

udp://[interface@]address[:port]
rtp://[interface@]address[:port]
  • interface — IPv4 address or name of the local interface. By the default uses system route table
  • address — IPv4 address of the stream. Multicast or Unicast
  • port — port number. Default value: 1234

Additional options for Input:

  • renew=INTERVAL — renew the multicast subscription after the defined time

Additional options for Output:

  • ttl=TTL — time to live for UDP packet. Default value: 32
  • sync — stream synchronization is a uniform transmission of the stream based on the PCR label. Astra calculates total size of the block between two PCR labels and the actual rate of the block. This option may be needed for some modulators
  • cbr=RATE — append NULL-TS packets into the stream to get constant bitrate. Used in pair with the sync option

Examples:

  • udp://239.255.1.1
  • udp://eth0@239.255.1.1
  • udp://127.0.0.1:10000
  • udp://239.255.1.1:1234#sync&cbr=8

HTTP

http://[login:password@]address[:port][/path]
  • login:password — login and password for http authentication, basic or digest. For Input only
  • address — server IPv4 address or domain. For Output, an address of the local interface or 0 to accept connection from any interface
  • port — port number. Default value: 80
  • path — path to the resource. Default value: /

Additional options for Input:

  • ua=USER-AGENT — custom value for User-Agent header. Default value: Astra
  • timeout=TIMEOUT — timeout, in seconds, for establishing a connection with a server. Default value: 10
  • buffer_size=SIZE — the receiving buffer size, in kilobytes. Default value: 1024
  • sctp — use SCTP instead of TCP

Additional options for Output:

  • buffer_size=SIZE — size, in kilobytes, of the client buffer. Buffer allocated for each connection and prevents data loss on the transmission delays. Default value: 1024
  • buffer_fill=SIZE — minimal data size, in kilobytes, should be collected before transmission to client. Default value: 256
  • sctp — use SCTP instead of TCP
  • auth — access authentication. Read more: auth_request

Examples:

  • http://media.example.com/channels/discovery.m3u8 — receive HLS stream
  • http://192.168.0.1:8000/udp/239.255.1.1:1234 — receive stream from Astra Relay
  • http://0:10000/channel-id/

FAQ:

  • What difference between HTTP and HLS? — HTTP Streaming is like a downloading of one big file without the end. HLS works over HTTP, splits stream to the many small chunks. HLS address should be ended with the .m3u or .m3u8. HLS is more stable for streaming over internet, also allows to distribute resources to different servers. Current versions of Astra supports only HLS-Input, HLS-Output under development

RTSP

RTSP available for Input only.

rtsp://[login:password@]address[:port][/path]
  • login:password — login and password for rtsp authentication, basic or digest
  • address — server IPv4 address or domain
  • port — port number. Default value: 554
  • path — path to the resource. Default value: /

RTSP has no additional options.

MPEG-TS File

file://path
  • path — path to the file

Additional options for Input:

  • loop — start playing from the beginning after the end of file

Additional options for Output:

  • aio — enable asynchronous output

Examples:

  • file:///mnt/raid0/file.ts — absolute path
  • file://./file.ts — relative path
  • file:///mnt/raid0/test-patter.ts#loop

Network Push

Network Push is an HTTP-based media streaming protocol. It works by transmitting data from client to the server. For example, used to transmit streams to the transcoding cloud.

Network Push available for Output only.

np://[login:password@]address[:port][/path]
  • login:password — login and password for http authentication, basic or digest. For Input only
  • address — server IPv4 address or domain
  • port — port number. Default value: 80
  • path — path to the resource. Default value: /

Additional options for Output:

  • sctp — use SCTP instead of TCP

Examples:

  • np://media.example.com/channel-id

General options

General options for any type of Input:

  • pnr=PNR — program number, also known as SID (Service ID). Extract a program with defined number from the stream
  • set_pnr=PNR — set custom PNR
  • set_tsid=TSID — set custom TSID (Transport Stream ID)
  • biss=1122330044556600 — BISS key to descramble a program
  • cam — use DVB-CI to descramble a program
  • cam=CAM-ID — specify the Softcam connection to descramble a program
  • ecm_pid=PID — select the ECM PID (not recommend to use)
  • shift=X — the decryption buffer for incoming stream, in megabits, allow to make a delay before decrypt a stream. This option may be needed for the "Sky" channels. To calculate a shift value need to multiply bitrate of the stream and delay in seconds. For example 10Mbit stream * 3 seconds will be shift=30
  • cas — transmit data for Conditional Access System. Use this option to transmit encoded stream
  • filter=N,... — stream filter, remove data with defined identifiers (PID). Identifiers should be comma separated
  • filter~=N,... — stream filter, remove all data except defined identifiers (PID) and the service data. Identifiers should be comma separated
  • map.SRC=DST — change data identifiers (PID) to the custom value. SRC - is an original identifier or type of the data. Possible types is pmt, video, audio or language descriptor. DST - is a custom PID. Value should be in range from 16 to 8190
  • no_sdt — remove service description: service name, provider name. SDT - Service Description Table
  • pass_sdt — pass SDT without processing. By the default, if pnr is defined Astra transmits information about current stream only
  • no_eit — remove event information: EPG. EIT - Event Information Table
  • pass_eit — pass EIT without processing. By the default, if pnr is defined Astra transmits information about current stream only
  • no_reload — turn off a checking of the changes in the stream
  • cc_limit=N — set the CC-Errors limit. If the number of the CC-Errors will be more than limit then Astra will try to switch to next source. By the default limit is not set. CC (Continuity Counter) is a serial number of the data packets. CC-Error - violation of the packets sequence due to the loss of data
  • bitrate_limit=RATE — set a minimal bitrate for analyzer in Kbit/s. Mark source as corrupted if the stream rate less than the bitrate limit value. Default values: 16 Kbit/s for stream without video data and 128 Kbit/s for stream with video data
Back: Home > Docs
Next: Astra UI