libdvbv5  1.11.0
Library to work with Digital TV devices on Linux
dvb-v5-std.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2011-2014 - Mauro Carvalho Chehab
3  *
4  * This program is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU Lesser General Public License as published by
6  * the Free Software Foundation version 2.1 of the License.
7  *
8  * This program is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU Lesser General Public License for more details.
12  *
13  * You should have received a copy of the GNU Lesser General Public License
14  * along with this program; if not, write to the Free Software
15  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
16  * Or, point your browser to http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
17  *
18  * Per-delivery system properties defined at libdvbv5 scope, following
19  * the same model as defined at the Linux DVB media specs:
20  * http://linuxtv.org/downloads/v4l-dvb-apis/FE_GET_SET_PROPERTY.html
21  */
22 #ifndef _DVB_V5_STD_H
23 #define _DVB_V5_STD_H
24 
25 #include <stddef.h>
26 #include "dvb-frontend.h"
27 
39 /*
40  * User DTV codes, for internal usage. There are two sets of
41  * properties. One for DTV properties and another one for statistics
42  */
43 
44 /*
45  * First set: DTV properties that don't belong to Kernelspace
46  *
47  * Those properties contain data that comes from the MPEG-TS
48  * tables, like audio/video/other PIDs, and satellite config
49  */
50 
107 #define DTV_USER_COMMAND_START 256
108 
109 #define DTV_POLARIZATION (DTV_USER_COMMAND_START + 0)
110 #define DTV_VIDEO_PID (DTV_USER_COMMAND_START + 1)
111 #define DTV_AUDIO_PID (DTV_USER_COMMAND_START + 2)
112 #define DTV_SERVICE_ID (DTV_USER_COMMAND_START + 3)
113 #define DTV_CH_NAME (DTV_USER_COMMAND_START + 4)
114 #define DTV_VCHANNEL (DTV_USER_COMMAND_START + 5)
115 #define DTV_SAT_NUMBER (DTV_USER_COMMAND_START + 6)
116 #define DTV_DISEQC_WAIT (DTV_USER_COMMAND_START + 7)
117 #define DTV_DISEQC_LNB (DTV_USER_COMMAND_START + 8)
118 #define DTV_FREQ_BPF (DTV_USER_COMMAND_START + 9)
119 #define DTV_PLS_CODE (DTV_USER_COMMAND_START + 10)
120 #define DTV_PLS_MODE (DTV_USER_COMMAND_START + 11)
121 #define DTV_COUNTRY_CODE (DTV_USER_COMMAND_START + 12)
122 
123 #define DTV_MAX_USER_COMMAND DTV_COUNTRY_CODE
124 
125 #define DTV_USER_NAME_SIZE (1 + DTV_MAX_USER_COMMAND - DTV_USER_COMMAND_START)
126 
144 };
145 
146 /*
147  * Second set: DTV statistics
148  *
149  * Those properties contain statistics measurements that aren't
150  * either provided by the Kernel via property cmd/value pair,
151  * like status (with has its own ioctl), or that are derivated
152  * measures from two or more Kernel reported stats.
153  */
154 
197 #define DTV_STAT_COMMAND_START 512
198 
199 #define DTV_STATUS (DTV_STAT_COMMAND_START + 0)
200 #define DTV_BER (DTV_STAT_COMMAND_START + 1)
201 #define DTV_PER (DTV_STAT_COMMAND_START + 2)
202 #define DTV_QUALITY (DTV_STAT_COMMAND_START + 3)
203 #define DTV_PRE_BER (DTV_STAT_COMMAND_START + 4)
204 
205 #define DTV_MAX_STAT_COMMAND DTV_PRE_BER
206 
207 #define DTV_STAT_NAME_SIZE (1 + DTV_MAX_STAT_COMMAND - DTV_STAT_COMMAND_START)
208 
209 /* There are currently 8 stats provided on Kernelspace */
210 #define DTV_NUM_KERNEL_STATS 8
211 
212 #define DTV_NUM_STATS_PROPS (DTV_NUM_KERNEL_STATS + DTV_STAT_NAME_SIZE)
213 
236 };
237 
238 #ifndef _DOXYGEN
239 
240 /*
241  * Some tables to translate from value to string
242  *
243  * These tables are raw ways to translate from some DTV values into strings.
244  * Please use the API-provided function dvb_cmd_name() and dvb_dvb_attr_names(),
245  * instead of using the tables directly.
246  */
247 
248 extern const unsigned int sys_dvbt_props[];
249 extern const unsigned int sys_dvbt2_props[];
250 extern const unsigned int sys_isdbt_props[];
251 extern const unsigned int sys_atsc_props[];
252 extern const unsigned int sys_atscmh_props[];
253 extern const unsigned int sys_dvbc_annex_ac_props[];
254 extern const unsigned int sys_dvbc_annex_b_props[];
255 extern const unsigned int sys_dvbs_props[];
256 extern const unsigned int sys_dvbs2_props[];
257 extern const unsigned int sys_turbo_props[];
258 extern const unsigned int sys_isdbs_props[];
259 extern const unsigned int *dvb_v5_delivery_system[];
260 extern const char *dvb_sat_pol_name[6];
261 extern const char *dvb_user_name[DTV_USER_NAME_SIZE + 1];
262 extern const char *dvb_stat_name[DTV_STAT_NAME_SIZE + 1];
263 extern const void *dvb_user_attr_names[];
264 
265 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
266 
267 #endif
#define DTV_USER_NAME_SIZE
Number of user commands.
Definition: dvb-v5-std.h:125
#define DTV_STAT_NAME_SIZE
Number of statistics commands.
Definition: dvb-v5-std.h:207
dvb_sat_polarization
Polarization types for Satellite systems.
Definition: dvb-v5-std.h:138
dvb_quality
Provides an estimation about the user's experience while watching to a given MPEG stream...
Definition: dvb-v5-std.h:231