In the Astra interface, you can manage DVB Adapter configurations and control their status using HTTP API methods.
{
"id": "...",
"name": "...",
"type": "...",
"enable": true,
"adapter": 0,
"device": 0
}
name - adapter name;type - adapter type: S, S2, T, T2, ATSC, ISDB-T, C, C/A, C/B, C/C;enable - true if adapter is enabled;adapter - number of adapter in the system: /dev/dvb/adapter0device - number of the device in the adapter: /dev/dvb/adapter0/frontend0Request: GET /api/adapter-info/{id}
id - unique adapter identifierIn response will be JSON with adapter configuration
Request: POST /control/
{
"cmd": "set-adapter",
"id": "...",
"adapter": {...}
}
id - unique adapter identifieradapter - adapter configurationRequest: POST /control/
{
"cmd": "restart-adapter",
"id": "..."
}
id - unique adapter identifierRequest: POST /control/
{
"cmd": "set-adapter",
"id": "...",
"adapter": {
"remove": true
}
}
id - unique adapter identifierRequest: GET /api/adapter-status/{id}
id - unique adapter identifierOptional query parameters: GET /api/adapter-status/{id}?t={time}
time - default is 1 - statistics for last minute, 0 - statistics for last second (current adapter status)Response:
{
"timestamp": 0,
"instance": "...",
"name": "...",
"lock": true,
"signal": 0,
"signal_db": 0,
"snr": 0,
"snr_db": 0,
"ber": 0,
"unc": 0,
"bitrate": 0
}
timestamp - report time, for t=0 is a current time;instance - instance name if defined in the Settings -> General -> Instance Name;name - stream name;lock - true if tuner has lock and able to receive data;signal - approximate signal level in percent;signal_db - signal level in dBm multiplied by 100;snr - approximate signal to noise ratio in percent;snr_db - signal to noise ratio in dB multiplied by 100;ber - bit errors counter;unc - block errors counter;bitrate - total bitrate in Kbit/s.