DVBCore  17.9.0
Open Source DVB Engine
 All Data Structures Files Functions Typedefs Macros Pages
ap_dbdef.h
Go to the documentation of this file.
1 /*******************************************************************************
2  * Copyright © 2014 The DTVKit Open Software Foundation Ltd (www.dtvkit.org)
3  * Copyright © 2004 Ocean Blue Software Ltd
4  *
5  * This file is part of a DTVKit Software Component
6  * You are permitted to copy, modify or distribute this file subject to the terms
7  * of the DTVKit 1.0 Licence which can be found in licence.txt or at www.dtvkit.org
8  *
9  * THIS CODE AND INFORMATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
10  * EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES
11  * OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE.
12  *
13  * If you or your organisation is not a member of DTVKit then you have access
14  * to this source code outside of the terms of the licence agreement
15  * and you are expected to delete this and any associated files immediately.
16  * Further information on DTVKit, membership and terms can be found at www.dtvkit.org
17  *******************************************************************************/
24 #ifndef _AP_DBDEF_H
25 #define _AP_DBDEF_H
26 
27 #include "techtype.h"
28 #include "stbsiflt.h"
29 #include "stbsitab.h"
30 #include "stbllist.h"
31 #include "ap_cfg.h"
32 #include "ap_tmr.h"
33 #include "ap_dbacc.h"
34 
35 //---Constant and macro definitions for public use-----------------------------
36 
37 #define ADB_LANG_CODE_UNDEF 0x756e64
38 #define ADB_LANG_CODE_QAA 0x716161
39 #define ADB_LANG_CODE_NAR 0x6e6172
40 
41 /* DVB SI descriptor tags */
42 #define LINKAGE_DTAG 0x4a
43 #define SHORT_EVENT_DTAG 0x4d
44 #define EXTENDED_EVENT_DTAG 0x4e
45 #define COMPONENT_DTAG 0x50
46 #define CONTENT_DTAG 0x54
47 #define PARENTAL_RATING_DTAG 0x55
48 #define PRIVATE_DATA_SPEC_DTAG 0x5f
49 #define CONT_ID_DESC_DTAG 0x76
50 #define FTA_CONTENT_DESC_DTAG 0x7e
51 #define EXTENSION_DTAG 0x7f
52 #define USER_DEFINED_DTAG_0x85 0x85
53 #define USER_DEFINED_DTAG_0x89 0x89
54 
55 #define LINK_TYPE_EVENT 0x0d
56 #define LINK_TYPE_EXT_EVENT 0x0e
57 
58 #define INVALID_FREESAT_SERV_ID 0x8000
59 
60 /* Content identifier descriptor CRID types */
61 #define TVA_PROGRAMME_CRID 0x01
62 #define TVA_SERIES_CRID 0x02
63 #define TVA_RECOMMENDATION_CRID 0x03
64 
65 #define UK_PROGRAMME_CRID 0x31
66 #define UK_SERIES_CRID 0x32
67 #define UK_RECOMMENDATION_CRID 0x33
68 
69 //---Enumerations for public use-----------------------------------------------
70 typedef enum
71 {
72  STREAM_MATCH_EXACT,
73  STREAM_MATCH_ASPECT,
74  STREAM_MATCH_LANG,
75  STREAM_MATCH_TYPE,
76  STREAM_MATCH_NOT_ZERO,
77  STREAM_MATCH_NONE
78 } E_STREAM_MATCH_TYPE;
79 
80 //---Global type defs for public use-------------------------------------------
81 
82 // Database structures - strings
83 typedef struct adb_string
84 {
85  U32BIT lang_code;
86  U16BIT nbytes;
87  U8BIT *str_ptr;
88 } ADB_STRING;
89 
90 
91 //--------------------------------------------------
92 // Database structures - satellite records
93 typedef struct adb_lnb_rec
94 {
95  LINK_LIST_PTR_BLK ptrs;
96  void *dba_rec;
97 
98  E_STB_DP_LNB_TYPE type;
99  E_STB_DP_LNB_POWER power;
100  BOOLEAN is_22k;
101  BOOLEAN is_12v;
102  BOOLEAN is_pulse_posn;
103  BOOLEAN is_diseqc_posn;
104  E_STB_DP_DISEQC_TONE diseqc_tone;
105  E_STB_DP_DISEQC_CSWITCH c_switch;
106  U8BIT u_switch; // 0 to 16 inclusive
107  BOOLEAN is_smatv;
108  U8BIT diseqc_repeats; // 0 to 3 inclusive
109  U32BIT unicable_if;
110  U8BIT unicable_chan;
111  ADB_STRING *name;
112 } ADB_LNB_REC;
113 
114 typedef struct adb_bat_version_rec
115 {
116  struct adb_bat_version_rec *next;
117  U16BIT bouquet_id;
118  U8BIT version;
120 
121 typedef struct adb_satellite_rec
122 {
123  LINK_LIST_PTR_BLK ptrs;
124  void *dba_rec;
125 
126  ADB_LNB_REC *lnb;
127  ADB_STRING *name;
128  U16BIT dish_pos;
129  U16BIT long_pos; // 0 to 1800 inclusive
130  BOOLEAN east_west; // 0=West,1=East
131 
132  BOOLEAN has_fta_desc;
133  BOOLEAN do_not_scramble;
134  ADB_STRING *def_authority;
135 
136  ADB_BAT_VERSION_REC *bat_version_list;
138 
139 typedef struct adb_lnb_band_rec
140 {
141  LINK_LIST_PTR_BLK ptrs;
142  void *dba_rec;
143 
144  ADB_LNB_REC *lnb;
145  S_STB_DP_LNB_BAND band_params;
147 
148 
149 //--------------------------------------------------
150 // Database structures - network records
151 typedef struct adb_network_rec
152 {
153  LINK_LIST_PTR_BLK ptrs;
154  void *dba_rec;
155 
156  U16BIT net_id;
157  U8BIT nit_version;
158  BOOLEAN nit_version_changed;
159 
160  ADB_STRING *name_str;
161  ADB_STRING *name_array[ACFG_NUM_DB_LANGUAGES];
162  BOOLEAN has_fta_desc;
163  BOOLEAN do_not_scramble;
164  SI_NIT_TARGET_REGION_NAME_DESC *target_region_name_list;
165  SI_TARGET_REGION_DESC *target_region_list;
166  SI_LINKAGE_DESC_ENTRY *last_linkage_entry;
167  SI_LINKAGE_DESC_ENTRY *linkage_desc_list;
168  U16BIT num_linkage_entries;
169  ADB_STRING *def_authority;
170  ADB_SATELLITE_REC *satellite;
171  ADB_PROFILE_TYPE profile_type;
172 
173 #ifdef COMMON_INTERFACE
174  BOOLEAN module_present;
175  U32BIT module;
176  U16BIT cicam_onet_id;
177  U32BIT cicam_identifier;
178  BOOLEAN op_search_required;
179  U16BIT op_search_date;
180  U16BIT op_search_time;
181  ADB_STRING *profile_name;
185  U8BIT fav_list_id;
186 #endif
188 
189 
190 //--------------------------------------------------
191 // Database structures - transport records
192 typedef struct adb_pmt_version_rec
193 {
194  struct adb_pmt_version_rec *next;
195  U16BIT serv_id;
196  U8BIT version;
198 
199 typedef struct adb_transport_rec
200 {
201  LINK_LIST_PTR_BLK ptrs;
202  void *dba_rec;
203 
204  U16BIT tran_id;
205  U16BIT orig_net_id;
206  ADB_STRING *name_str;
207  U32BIT frequency;
208  ADB_NETWORK_REC *network;
209  E_STB_DP_SIGNAL_TYPE sig_type;
210  U8BIT signal_level_at_search;
211 
212  /* The following union is accessed based on sig_type */
213  union
214  {
215  struct _analog_trans_rec
216  {
217  S8BIT freq_offset;
218  E_STB_DP_ANALOG_VIDEO_TYPE vtype;
219  } anal;
220  struct _terr_trans_rec
221  {
222  E_STB_DP_TBWIDTH bwidth;
223  E_STB_DP_TMODE tmode;
224  E_STB_DP_TTYPE terr_type;
225  U8BIT plp_id;
226  S8BIT freq_offset;
227  E_STB_TUNE_TCONST constellation;
228  E_STB_TUNE_THIERARCHY hierarchy;
229  E_STB_TUNE_TCODERATE lp_code_rate;
230  E_STB_TUNE_TCODERATE hp_code_rate;
231  E_STB_TUNE_TGUARDINT guard_int;
232  SI_TARGET_REGION_DESC *target_region_list;
233  } terr;
234  struct _cable_trans_rec
235  {
236  E_STB_DP_CMODE cmode;
237  U16BIT symbol_rate;
238  } cab;
239  struct _sat_trans_rec
240  {
241  U16BIT symbol_rate;
242  E_STB_DP_POLARITY polarity;
243  E_STB_DP_FEC fec_code;
244  E_STB_DP_FEC_TYPE fec_type;
245  BOOLEAN dvb_s2;
246  E_STB_DP_MODULATION modulation;
247  } sat;
248  } u;
249 
250  U8BIT pat_version;
251  U8BIT sdt_version;
252  BOOLEAN sdt_received;
253  BOOLEAN sdt_version_changed;
254  BOOLEAN has_fta_desc;
255  BOOLEAN do_not_scramble;
256  BOOLEAN searched;
257  BOOLEAN available;
258  BOOLEAN was_avail;
259 
260  ADB_PMT_VERSION_REC *pmt_version_list;
261  ADB_STRING *def_authority;
262 
264 
265 //--------------------------------------------------------
266 // Database structures - service, event and stream records
267 
268 typedef struct adb_audio_stream_data
269 {
270  U32BIT lang_code;
271  ADB_AUDIO_TYPE type;
272  E_STB_DP_AUDIO_MODE mode;
274 
276 {
277  U32BIT lang_code;
278  ADB_SUBTITLE_TYPE type;
279  U16BIT composition_page;
280  U16BIT ancillary_page;
282 
283 typedef struct adb_ttext_stream_data
284 {
285  U32BIT lang_code;
286  U8BIT type;
287  U8BIT magazine;
288  U8BIT page;
290 
291 typedef union adb_stream_data
292 {
293  ADB_AUDIO_STREAM_DATA audio;
294  ADB_SUBTITLE_STREAM_DATA subtitle;
295  ADB_TTEXT_STREAM_DATA ttext;
297 
298 typedef struct adb_stream_rec
299 {
300  struct adb_stream_rec *next;
301  ADB_STREAM_TYPE type;
302  U8BIT *tag_array;
303  U8BIT num_tags;
304  U16BIT pid;
305  BOOLEAN in_use;
306  ADB_STREAM_DATA data;
307  BOOLEAN has_ca_descriptor;
309 
310 typedef struct adb_event_desc
311 {
312  U8BIT *desc_data;
313  struct adb_event_desc *next;
315 
316 typedef struct adb_event_rec
317 {
318  struct adb_event_rec *next;
319  void *dba_rec;
320 
321  U16BIT event_id;
322  U32DHMS start;
323  U32DHMS duration;
324  U8BIT running_status;
325  BOOLEAN free_to_air;
326  U8BIT version;
327 
328  /* Keep values parsed from the content management descriptor that are used by DVBCore */
329  BOOLEAN has_content_management_desc;
330  BOOLEAN do_not_scramble;
331 
332  ADB_EVENT_DESC *desc_list_head;
333  ADB_EVENT_DESC *desc_list_tail;
334 } ADB_EVENT_REC;
335 
336 typedef struct adb_alt_serv_rec
337 {
338  struct adb_alt_serv_rec *next;
339  U16BIT onet_id;
340  U16BIT tran_id;
341  U16BIT serv_id;
342  U8BIT link_type;
344 
345 typedef enum
346 {
347  ICON_TYPE_PNG,
348  ICON_TYPE_JPEG
349 } E_ICON_TYPE;
350 
351 typedef struct adb_icon_image
352 {
353  struct adb_icon_image *next;
354  U8BIT icon_id;
355  BOOLEAN position_defined;
356  E_ICON_COORD_SYSTEM coord_system;
357  U16BIT x_pos;
358  U16BIT y_pos;
359  U16BIT width;
360  U16BIT height;
361  E_ICON_TYPE icon_type;
362  E_ICON_TRANSPORT_MODE transport_mode;
363  U8BIT *icon_url;
364  U32BIT data_len;
365  U8BIT *icon_data;
366  void (*destroy_func)(void *);
367  void *dsm_handle;
369 
370 typedef struct adb_rct_link_info
371 {
372  struct adb_rct_link_info *next;
373  BOOLEAN is_group_trailer;
374  U8BIT *uri_string;
375  BOOLEAN can_use_default_icon;
376  U8BIT icon_id;
377  ADB_STRING *promo_text[ACFG_NUM_DB_LANGUAGES];
378  ADB_STRING *event_name;
380 
381 typedef struct
382 {
383  U8BIT type;
384  U8BIT mode;
385  ADB_STRING *text;
387 
388 typedef struct adb_service_rec
389 {
390  LINK_LIST_PTR_BLK ptrs;
391  void *dba_rec;
392 
393  ADB_TRANSPORT_REC *transport;
394  ADB_SERVICE_TYPE serv_type;
395  U16BIT serv_id;
396  U16BIT serv_lcn;
397  U16BIT allocated_lcn;
398  U16BIT old_allocated_lcn;
399  ADB_STRING *name_str;
400  ADB_STRING *provider_str;
401  ADB_STRING *short_name_str;
402  ADB_STRING *short_name_array[ACFG_NUM_DB_LANGUAGES];
403  ADB_STRING *name_array[ACFG_NUM_DB_LANGUAGES][ADB_NUM_SERV_NAME_IDS];
404  ADB_STRING *provider_array[ACFG_NUM_DB_LANGUAGES];
405  ADB_GUIDANCE_DESC guidance[ACFG_NUM_DB_LANGUAGES];
406  ADB_STREAM_REC *stream_list;
407  ADB_ALT_SERV_REC *alt_serv_list;
408  U8BIT fav_groups;
409 
410  BOOLEAN sched_disabled;
411  BOOLEAN now_next_disabled;
412 
413  BOOLEAN eit_now_next_avail;
414  ADB_EVENT_REC *now_event;
415  ADB_EVENT_REC *next_event;
416 
417  BOOLEAN eit_sched_avail;
418  U16BIT num_events_in_schedule;
419  ADB_EVENT_REC *event_schedule;
420 
421  BOOLEAN pmt_received;
422 
423  U16BIT pcr_pid;
424  U16BIT video_pid;
425  U16BIT audio_pid;
426  U16BIT ad_pid;
427  U16BIT ttext_pid;
428  U8BIT ttext_mag;
429  U8BIT ttext_page;
430  U16BIT subtitle_pid;
431  U16BIT subtitle_cpage;
432  U16BIT subtitle_apage;
433  ADB_STREAM_TYPE video_type;
434  ADB_STREAM_TYPE audio_type;
435 
436  BOOLEAN reqd_audio_valid;
437  U32BIT reqd_audio_lang_code;
438  ADB_AUDIO_TYPE reqd_audio_type;
439  ADB_STREAM_TYPE reqd_stream_type;
440  U16BIT reqd_audio_pid;
441  BOOLEAN reqd_subtitle_valid;
442  U32BIT reqd_subtitle_lang_code;
443  ADB_SUBTITLE_TYPE reqd_subtitle_type;
444  BOOLEAN reqd_ttext_valid;
445  U32BIT reqd_ttext_lang_code;
446  ADB_TELETEXT_TYPE reqd_ttext_type;
447 
448  BOOLEAN found; /* Used during service search */
449  U8BIT running_status;
450  BOOLEAN not_running;
451  BOOLEAN unavailable;
452  BOOLEAN new_service;
453  BOOLEAN locked;
454  BOOLEAN hidden;
455  BOOLEAN selectable;
456  BOOLEAN lcn_editable;
457  BOOLEAN scrambled;
458 
459  BOOLEAN has_fta_desc;
460  BOOLEAN do_not_scramble;
461 
462  SI_TARGET_REGION_DESC *target_region_list;
463 
464  ADB_STRING *def_authority;
465 
466  U16BIT rct_pid;
467  ADB_RCT_LINK_INFO *rct_link_list;
468  ADB_IMAGE_ICON *icon_list;
469 
470 #ifdef COMMON_INTERFACE
471  BOOLEAN sdt_received;
472  U8BIT *ci_protection_desc;
473  U32BIT ci_prot_last_update;
474 #endif
475  U8BIT *pmt_data;
476  U16BIT pmt_data_len;
477  U16BIT pmt_pid;
478  SI_LINKAGE_DESC_ENTRY *last_linkage_entry;
479  SI_LINKAGE_DESC_ENTRY *linkage_desc_list;
480  U16BIT num_linkage_entries;
481  SI_LCN_DESC *hd_lcn_desc;
482 
483  BOOLEAN has_ca_descriptor;
484 
485  /* Freesat specific values */
486  U16BIT freesat_id;
487  U16BIT region_id;
488 
489  U16BIT bat_pid;
490  U16BIT eit_pf_pid;
491  U16BIT eit_pf_plus_pid;
492  U16BIT eit_sched_pid;
493  U16BIT nit_pid;
494  U16BIT sdt_pid;
495  U16BIT tdt_pid;
496  U16BIT tot_pid;
497 #ifdef INTEGRATE_HBBTV
498  U16BIT ait_pid;
499 #endif
501 
502 
503 //--------------------------------------------------------
504 // Database structures - crid records
505 
506 typedef struct adb_crid_record
507 {
508  LINK_LIST_PTR_BLK ptrs;
509  void *dba_rec;
510 
511  U16BIT eit_date; /* The date the CRID was last seen in the EITs */
512  BOOLEAN series_flag; /* The CRID represents a series */
513  BOOLEAN recommended_flag; /* The CRID represents a recommended programme or series */
514  BOOLEAN radio_service; /* TRUE if this record represents a CRID from a radio service */
515  U32DHMS date_time; /* Date to be used when searching for a split event */
516  U16BIT serv_id; /* Service to be used when searching for a split event */
517  ADB_STRING *name_str; /* Programme name for series/recommendations */
518  ADB_STRING *crid_str; /* CRID string */
519 } ADB_CRID_REC;
520 
521 
522 //--------------------------------------------------------
523 // Database structures - favourite lists
524 
525 typedef struct adb_favserv_rec
526 {
527  LINK_LIST_PTR_BLK ptrs; /* prev/next service in favourite list */
528  void *dba_rec;
529 
530  ADB_SERVICE_REC *serv_ptr;
531  U8BIT list_id; /* Id of the fav list this service is in */
532  U16BIT index; /* Defines the position of this service in the list */
534 
535 typedef struct adb_favlist_rec
536 {
537  LINK_LIST_PTR_BLK ptrs; /* List of favourite lists */
538  void *dba_rec;
539 
540  U8BIT list_id; /* Unique id for a list */
541  U8BIT index; /* Defines the position of this list in the favourite lists */
542  U32BIT user_data; /* User defined value stored with the list */
543  ADB_STRING *name;
544  LINK_LIST_HEADER serv_list; /* List of service in this favourite list */
546 
547 //--------------------------------------------------------
548 // Database structures - timers
549 
550 typedef struct
551 {
552  BOOLEAN change_service;
553  U16BIT service_id;
554  U16BIT transport_id;
555  U16BIT orig_net_id;
556  BOOLEAN ramp_volume;
557 } ADB_ALARM_REC;
558 
559 typedef struct
560 {
561  U32DHMS duration;
562  BOOLEAN event_triggered;
563  U16BIT event_id;
564  U16BIT service_id;
565  U16BIT transport_id;
566  U16BIT orig_net_id;
567  U8BIT prog_crid[TMR_PVR_CRID_LEN_MAX];
568  U8BIT other_crid[TMR_PVR_CRID_LEN_MAX];
569  U16BIT disk_id;
570  BOOLEAN recommendation;
571  U16BIT notify_time;
572  U8BIT path;
573  U32BIT recording_handle;
574  U8BIT additional_info[TMR_PVR_ADDINFO_LEN_MAX];
575  S32BIT start_padding;
576  S32BIT end_padding;
578 
579 typedef struct
580 {
581  LINK_LIST_PTR_BLK ptrs;
582  void *dba_rec;
583 
584  U32BIT handle;
585  E_TIMER_TYPE type;
586  U32DHMS start_time;
587  U8BIT name[TMR_MAX_NAME_LENGTH];
588  E_TIMER_FREQ frequency;
589 
590  BOOLEAN expired;
591  BOOLEAN starting;
592  BOOLEAN started;
593  BOOLEAN selected;
594  BOOLEAN missed;
595  union
596  {
597  ADB_ALARM_REC alarm;
598  ADB_PVR_RECORD_REC record;
599  } u;
600 } ADB_TIMER_REC;
601 
602 #ifdef COMMON_INTERFACE
603 typedef struct
604 {
605  LINK_LIST_PTR_BLK ptrs;
606  void *dba_rec;
607 
608  U32BIT cicam_identifier;
609  U32BIT timer_handle;
610 } ADB_CICAM_TIMER_REC;
611 #endif
612 
613 /* Internal structure used to pass events to an application.
614  * The application handles these as void* handles */
615 typedef struct s_event
616 {
617  void *serv_ptr;
618  U16BIT event_id;
619 } S_EVENT;
620 
621 
622 //---Global Function prototypes for public use---------------------------------
623 
627 void DBDEF_Initialise(void);
628 
632 void DBDEF_RequestAccess(void);
633 
637 void DBDEF_ReleaseAccess(void);
638 
639 BOOLEAN DBDEF_LoadDatabase(U8BIT *db_pathname);
640 void DBDEF_DeleteAllRecords(void);
641 BOOLEAN DBDEF_SaveDatabase(void);
642 
643 void DBDEF_DeleteRecordsForTunerType(E_STB_DP_SIGNAL_TYPE tuner_type, void *satellite);
644 
650 
652 void DBDEF_DeleteImageIcons(ADB_IMAGE_ICON *icon_list);
653 
657 void DBDEF_SortServicesByLcn(void);
658 
659 BOOLEAN DBDEF_AllocateLcns(E_STB_DP_SIGNAL_TYPE tuner_type, BOOLEAN assign_lcns);
660 BOOLEAN DBDEF_AllocateLcnsDefault(E_STB_DP_SIGNAL_TYPE tuner_type);
661 #ifdef COUNTRY_UK
662 BOOLEAN DBDEF_AllocateLcnsUK(E_STB_DP_SIGNAL_TYPE tuner_type);
663 #endif
664 #ifdef COUNTRY_FINLAND
665 BOOLEAN DBDEF_AllocateLcnsFinland(E_STB_DP_SIGNAL_TYPE tuner_type);
666 #endif
667 
668 
673 U16BIT DBDEF_GetNumLNBs(void);
674 
681 ADB_LNB_REC* DBDEF_AddLNB(E_STB_DP_LNB_TYPE type, ADB_STRING *name);
682 
689 BOOLEAN DBDEF_SetLNBPower(ADB_LNB_REC *lnb, E_STB_DP_LNB_POWER power);
690 
697 BOOLEAN DBDEF_SetLNB22k(ADB_LNB_REC *lnb, BOOLEAN is_22k);
698 
705 BOOLEAN DBDEF_SetLNB12V(ADB_LNB_REC *lnb, BOOLEAN is_12v);
706 
713 BOOLEAN DBDEF_SetLNBPulsePosition(ADB_LNB_REC *lnb, BOOLEAN is_pulse_posn);
714 
721 BOOLEAN DBDEF_SetLNBDiSEqCPosition(ADB_LNB_REC *lnb, BOOLEAN is_diseqc_posn);
722 
729 BOOLEAN DBDEF_SetLNBDiSEqCTone(ADB_LNB_REC *lnb, E_STB_DP_DISEQC_TONE diseqc_tone);
730 
737 BOOLEAN DBDEF_SetLNBCSwitch(ADB_LNB_REC *lnb, E_STB_DP_DISEQC_CSWITCH cswitch);
738 
745 BOOLEAN DBDEF_SetLNBUSwitch(ADB_LNB_REC *lnb, U8BIT uswitch);
746 
753 BOOLEAN DBDEF_SetLNBSmatv(ADB_LNB_REC *lnb, BOOLEAN is_smatv);
754 
761 BOOLEAN DBDEF_SetLNBRepeats(ADB_LNB_REC *lnb, U8BIT repeats);
762 
770 BOOLEAN DBDEF_SetLNBUnicable(ADB_LNB_REC *lnb, U32BIT inter_freq, U8BIT chan);
771 
779 
784 U16BIT DBDEF_GetNumSatellites(void);
785 
795 ADB_SATELLITE_REC* DBDEF_AddSatelliteRec(ADB_STRING *name_str, U16BIT dish_pos, U16BIT long_pos,
796  BOOLEAN east_west, ADB_LNB_REC *associated_lnb);
797 
805 
810 U16BIT DBDEF_GetNumLNBBands(void);
811 
818 ADB_LNB_BAND_REC* DBDEF_AddLNBBandRec(S_STB_DP_LNB_BAND *band_parameters, ADB_LNB_REC *associated_lnb);
819 
827 
833 
838 U16BIT DBDEF_GetNumNetworks(void);
839 
846 ADB_NETWORK_REC* DBDEF_AddNetworkRec(U16BIT net_id, ADB_SATELLITE_REC *satellite);
847 
853 
859 void DBDEF_SetNetworkName(ADB_NETWORK_REC *n_ptr, U8BIT *name);
860 
867 ADB_NETWORK_REC* DBDEF_FindNetworkRec(U16BIT net_id, ADB_SATELLITE_REC *satellite);
868 
876 
881 U16BIT DBDEF_GetNumTransports(void);
882 
890 
898 ADB_TRANSPORT_REC* DBDEF_AddTerrestrialTransportRec(U32BIT freq_hz, U8BIT plp_id,
899  ADB_NETWORK_REC *network);
900 ADB_TRANSPORT_REC* DBDEF_FindTerrestrialTransportRec(U32BIT freq_hz, U8BIT plp_id);
901 
909 ADB_TRANSPORT_REC* DBDEF_AddCableTransportRec(U32BIT freq_hz, U32BIT symbol_rate,
910  ADB_NETWORK_REC *network);
911 ADB_TRANSPORT_REC* DBDEF_FindCableTransportRec(U32BIT freq_hz, U32BIT symbol_rate);
912 
913 void DBDEF_SetCableTransportSymbolRate(ADB_TRANSPORT_REC *t_ptr, U16BIT symbol_rate);
914 void DBDEF_SetCableTransportMode(ADB_TRANSPORT_REC *t_ptr, E_STB_DP_CMODE cmode);
915 
926 ADB_TRANSPORT_REC* DBDEF_AddSatTransportRec(U32BIT freq_hz, U16BIT symbol_rate,
927  E_STB_DP_POLARITY polarity, BOOLEAN dvb_s2, E_STB_DP_MODULATION modulation,
928  ADB_NETWORK_REC *network);
929 
938 ADB_TRANSPORT_REC* DBDEF_FindSatTransportRec(U32BIT freq_hz, U16BIT symbol_rate,
939  E_STB_DP_POLARITY polarity, BOOLEAN dvb_s2, E_STB_DP_MODULATION modulation, void *satellite);
940 
951 void DBDEF_SetSatTransportTuningParams(ADB_TRANSPORT_REC *t_ptr, U32BIT freq_hz,
952  U16BIT symbol_rate, E_STB_DP_POLARITY polarity, BOOLEAN dvb_s2, E_STB_DP_MODULATION modulation,
953  ADB_NETWORK_REC *network);
954 
964  U32BIT onet_id, U32BIT tran_id);
965 
971 void DBDEF_SetTransportTransportId(ADB_TRANSPORT_REC *t_ptr, U16BIT tran_id);
972 
978 void DBDEF_SetTransportOrigNetworkId(ADB_TRANSPORT_REC *t_ptr, U16BIT orig_net_id);
979 
985 
987 
992 U16BIT DBDEF_GetNumServices(void);
993 
1001 
1009 
1018 ADB_SERVICE_REC* DBDEF_NewServiceRec(U16BIT serv_id, ADB_TRANSPORT_REC *t_ptr, BOOLEAN prepend);
1019 
1027 ADB_SERVICE_REC* DBDEF_AddServiceRec(U16BIT serv_id, ADB_TRANSPORT_REC *t_ptr);
1028 
1037 
1045 BOOLEAN DBDEF_SetServiceName(ADB_SERVICE_REC *s_ptr, U8BIT *name);
1046 
1054 BOOLEAN DBDEF_SetServiceShortName(ADB_SERVICE_REC *s_ptr, U8BIT *name);
1055 
1063 BOOLEAN DBDEF_SetServiceProviderName(ADB_SERVICE_REC *s_ptr, U8BIT *name);
1064 
1071 BOOLEAN DBDEF_SetServiceType(ADB_SERVICE_REC *s_ptr, ADB_SERVICE_TYPE serv_type);
1072 
1078 
1086 
1096 ADB_SERVICE_REC* DBDEF_FindServiceRecByIds(ADB_SERVICE_REC *servp, U32BIT net_id, U32BIT onet_id,
1097  U32BIT tran_id, U32BIT serv_id);
1098 
1107 ADB_SERVICE_REC* DBDEF_FindServiceRecByLcn(U16BIT lcn, ADB_TRANSPORT_REC *t_ptr, BOOLEAN allocated_lcn);
1108 
1116 
1117 U16BIT DBDEF_GetReqdAudioPid(ADB_SERVICE_REC *s_ptr, E_STB_DP_AUDIO_MODE *audio_mode, ADB_STREAM_TYPE *audio_type);
1118 U16BIT DBDEF_GetReqdADPid(ADB_SERVICE_REC *s_ptr, E_STB_DP_AUDIO_MODE *ad_mode, ADB_STREAM_TYPE *ad_type,
1119  BOOLEAN *broadcast_mix);
1120 E_STREAM_MATCH_TYPE DBDEF_GetReqdTtextPid(ADB_SERVICE_REC *s_ptr, BOOLEAN for_subtitles, U16BIT *pid_ptr,
1121  U8BIT *magazine, U8BIT *page);
1122 E_STREAM_MATCH_TYPE DBDEF_GetReqdSubtitleParams(ADB_SERVICE_REC *s_ptr, U16BIT *pid_ptr,
1123  U16BIT *cpage_ptr, U16BIT *apage_ptr);
1124 U16BIT DBDEF_GetReqdVideoPid(ADB_SERVICE_REC *s_ptr, ADB_STREAM_TYPE *video_type);
1125 
1134 ADB_STRING* DBDEF_GetServiceName(ADB_SERVICE_REC *s_ptr, BOOLEAN short_name, BOOLEAN pref_name);
1135 
1142 
1143 BOOLEAN DBDEF_AddAnalogService(void);
1144 void DBDEF_SetAnalogServiceName(ADB_SERVICE_REC *s_ptr, U8BIT *new_name, U8BIT new_len);
1145 void DBDEF_SetServicePmtPid(ADB_SERVICE_REC *s_ptr, U16BIT pmt_pid);
1147 
1153 void DBDEF_SetServiceFavGroups(ADB_SERVICE_REC *s_ptr, U8BIT groups);
1154 
1162 
1171 ADB_EVENT_DESC* DBDEF_FindEventDescriptor(ADB_EVENT_DESC *start_desc, U8BIT desc_tag,
1172  U32BIT private_data_specifier);
1173 
1180 U8BIT* DBDEF_GetEventName(ADB_EVENT_REC *e_ptr);
1181 
1189 
1197 
1205 
1217 U8BIT* DBDEF_GetEventGuidance(ADB_EVENT_REC *e_ptr, ADB_SERVICE_REC *s_ptr, U8BIT *type, U8BIT *mode);
1218 
1227 U8BIT* DBDEF_GetServiceGuidanceData(ADB_SERVICE_REC *s_ptr, U8BIT *type, U8BIT *mode);
1228 
1236 
1243 
1250 
1264 BOOLEAN DBDEF_GetEventHDLinkageInfo(ADB_EVENT_REC *e_ptr, BOOLEAN verify_event, BOOLEAN only_simulcast,
1265  ADB_SERVICE_REC **hd_serv_ptr, ADB_EVENT_REC **hd_event_ptr);
1266 
1276 
1283 
1290 ADB_EVENT_CONTENT DBDEF_GetEventGenre(ADB_EVENT_REC *e_ptr, ADB_SERVICE_REC *s_ptr);
1291 
1298 U8BIT* DBDEF_GetEventContentData(ADB_EVENT_REC *e_ptr, U8BIT *p_len);
1299 
1310 U8BIT* DBDEF_GetEventCrid(ADB_SERVICE_REC *serv_ptr, ADB_EVENT_REC *e_ptr, U8BIT crid_type, U8BIT index);
1311 
1319 U8BIT DBDEF_NumberOfCridsOfType(ADB_EVENT_REC *e_ptr, U8BIT crid_type);
1320 
1328 U8BIT* DBDEF_GetFullCrid(ADB_SERVICE_REC *serv_ptr, U8BIT *event_str);
1329 
1337 
1343 
1344 void DBDEF_SetTunedNetwork(U8BIT path, ADB_NETWORK_REC *n_ptr);
1346 
1347 void DBDEF_SetTunedTransport(U8BIT path, ADB_TRANSPORT_REC *t_ptr);
1349 void DBDEF_SetTunedService(U8BIT path, ADB_SERVICE_REC *s_ptr);
1351 
1352 void DBDEF_SetTextLang(U8BIT *lang_ids);
1353 U8BIT* DBDEF_GetTextLang(void);
1354 void DBDEF_SetSecondaryTextLang(U8BIT *lang_ids);
1355 U8BIT* DBDEF_GetSecondaryTextLang(void);
1356 void DBDEF_SetAudioLang(U8BIT *lang_ids);
1357 U8BIT* DBDEF_GetAudioLang(void);
1358 U8BIT* DBDEF_GetSecondaryAudioLang(void);
1359 void DBDEF_SetSecondaryAudioLang(U8BIT *lang_ids);
1360 
1369 void DBDEF_TidyDatabaseAfterSearch(E_STB_DP_SIGNAL_TYPE tuner_type, void *satellite,
1370  BOOLEAN search_completed, BOOLEAN manual);
1371 
1372 void DBDEF_TidyDatabaseNordig(E_STB_DP_SIGNAL_TYPE tuner_type, BOOLEAN search_completed, BOOLEAN manual);
1373 void DBDEF_TidyDatabaseUK(E_STB_DP_SIGNAL_TYPE tuner_type, BOOLEAN search_completed, BOOLEAN manual);
1374 void DBDEF_TidyDatabaseSatUK(E_STB_DP_SIGNAL_TYPE tuner_type, BOOLEAN search_completed, BOOLEAN manual);
1375 void DBDEF_TidyDatabaseDefault(E_STB_DP_SIGNAL_TYPE tuner_type, BOOLEAN search_completed, BOOLEAN manual);
1376 
1384 void DBDEF_RemoveEmptyTransports(E_STB_DP_SIGNAL_TYPE tuner_type, void *satellite);
1385 
1386 void DBDEF_DeleteLinkageDescripterArray(SI_LINKAGE_DESC_ENTRY *list_ptr);
1387 
1396 ADB_CRID_REC* DBDEF_AddCridRecord(U8BIT *crid, BOOLEAN series, BOOLEAN recommended,
1397  BOOLEAN radio_service);
1398 
1404 void DBDEF_SetCridDateTime(ADB_CRID_REC *c_ptr, U32DHMS date_time);
1405 
1411 void DBDEF_SetCridService(ADB_CRID_REC *c_ptr, U16BIT serv_id);
1412 
1418 void DBDEF_SetCridProgrammeName(ADB_CRID_REC *c_ptr, U8BIT *prog_name);
1419 
1425 
1431 
1436 U16BIT DBDEF_GetNumCridRecords(void);
1437 
1445 
1451 BOOLEAN DBDEF_IsValidCridRecord(ADB_CRID_REC *c_ptr);
1452 
1457 U16BIT DBDEF_GetNumFavouriteLists(void);
1458 
1472 ADB_FAVLIST_REC* DBDEF_AddFavouriteList(U8BIT list_id, U8BIT *name, U32BIT user_data, S16BIT index);
1473 
1480 
1487 
1493 void DBDEF_SetFavouriteListUserData(ADB_FAVLIST_REC *fav_list, U32BIT user_data);
1494 
1502 void DBDEF_MoveFavouriteListTo(ADB_FAVLIST_REC *fav_list, S16BIT index);
1503 
1509 
1516 
1526  ADB_SERVICE_REC *serv_ptr, S16BIT index);
1527 
1535 
1543  ADB_FAVSERV_REC *fav_serv);
1544 
1552  ADB_FAVSERV_REC *fav_serv);
1553 
1563  S16BIT index);
1564 
1571 
1577 
1584 void DBDEF_SetFavouriteListName(ADB_FAVLIST_REC *f_ptr, U8BIT *name);
1585 
1596 BOOLEAN DBDEF_ServiceForTunerType(ADB_SERVICE_REC *s_ptr, E_STB_DP_SIGNAL_TYPE tuner_type, void *satellite);
1597 
1608 BOOLEAN DBDEF_TransportForTunerType(ADB_TRANSPORT_REC *t_ptr, E_STB_DP_SIGNAL_TYPE tuner_type, void *satellite);
1609 
1615 ADB_TIMER_REC* DBDEF_AddTimerRec(BOOLEAN store_in_nvm);
1616 
1622 ADB_TIMER_REC* DBDEF_FindTimerRec(U32BIT handle);
1623 
1631 
1636 void DBDEF_SortTimers(BOOLEAN date_time_order);
1637 
1642 void DBDEF_DeleteTimerRec(ADB_TIMER_REC *timer);
1643 
1647 U16BIT DBDEF_GetNumProfiles(void);
1648 
1656 U16BIT DBDEF_GetProfileList(void ***profile_list, U16BIT *active_profile);
1657 
1663 void DBDEF_ReleaseProfileList(void **profile_list, U16BIT num_profiles);
1664 
1670 BOOLEAN DBDEF_IsActiveProfile(ADB_NETWORK_REC *profile);
1671 
1676 ADB_PROFILE_TYPE DBDEF_GetCurrentProfileType(void);
1677 
1682 void DBDEF_SelectBroadcastProfile(void);
1683 
1689 void DBDEF_PushBroadcastProfile(void);
1690 
1691 #ifdef COMMON_INTERFACE
1692 
1699 void DBDEF_SelectCIPlusProfile(U16BIT onet_id, U32BIT cicam_id);
1700 
1707 void DBDEF_PushCIPlusProfile(U16BIT onet_id, U32BIT cicam_id);
1708 #endif
1709 
1713 void DBDEF_PopProfile(void);
1714 
1721 BOOLEAN DBDEF_ServiceInProfile(ADB_SERVICE_REC *s_ptr);
1722 
1730 
1737 BOOLEAN DBDEF_NetworkInProfile(ADB_NETWORK_REC *n_ptr);
1738 
1739 #ifdef COMMON_INTERFACE
1740 ADB_NETWORK_REC* DBDEF_FindNetworkForCIPlusProfile(U16BIT cicam_onet_id, U32BIT cicam_identifier);
1741 ADB_NETWORK_REC* DBDEF_FindNetworkForCIPlusModule(U32BIT module);
1742 
1747 ADB_NETWORK_REC *DBDEF_GetCurrentCIPlusProfile(void);
1748 
1755 ADB_CICAM_TIMER_REC* DBDEF_AddCicamTimer(U32BIT cicam_id, U32BIT timer_handle);
1756 
1761 void DBDEF_DeleteCicamTimerRec(ADB_CICAM_TIMER_REC *cicam_timer_ptr);
1762 
1769 ADB_CICAM_TIMER_REC* DBDEF_GetNextCicamTimerRec(ADB_CICAM_TIMER_REC *cicam_timer_ptr);
1770 
1776 ADB_CICAM_TIMER_REC* DBDEF_FindCicamTimer(U32BIT cicam_id);
1777 
1783 ADB_CICAM_TIMER_REC* DBDEF_FindCicamTimerByHandle(U32BIT handle);
1784 
1785 #endif
1786 
1793 
1794 #ifdef DEBUG_PRINT_DATABASE
1795 void DBDEF_PrintAllRecords(void);
1796 #endif
1797 
1806 ADB_STRING* DBDEF_MakeString(U32BIT lang_code, U8BIT *str_ptr, U16BIT nbytes);
1807 
1814 
1824 
1829 void DBDEF_ReleaseString(ADB_STRING *string);
1830 
1831 #endif // _AP_DBDEF_H
1832 
1833 //*****************************************************************************
1834 // End of file
1835 //*****************************************************************************
1836 
Definition: ap_dbacc.h:243
ADB_STRING * DBDEF_GetServiceName(ADB_SERVICE_REC *s_ptr, BOOLEAN short_name, BOOLEAN pref_name)
Returns a pointer to the service name, taking into account perferred names and short names...
Definition: ap_dbdef.c:6470
U8BIT * DBDEF_GetEventGuidance(ADB_EVENT_REC *e_ptr, ADB_SERVICE_REC *s_ptr, U8BIT *type, U8BIT *mode)
Returns the guidance text for an event, either from the event itself or the event's service...
Definition: ap_dbdef.c:2701
void DBDEF_SetAudioLang(U8BIT *lang_ids)
sets current audio lang
Definition: ap_dbdef.c:7703
U16BIT DBDEF_GetNumServices(void)
Returns the total number of services.
Definition: ap_dbdef.c:5431
void DBDEF_SetTunedNetwork(U8BIT path, ADB_NETWORK_REC *n_ptr)
sets the currently tuned network
Definition: ap_dbdef.c:7512
ADB_EVENT_CONTENT DBDEF_GetEventGenre(ADB_EVENT_REC *e_ptr, ADB_SERVICE_REC *s_ptr)
Returns the genre of an event.
Definition: ap_dbdef.c:3411
Definition: ap_dbdef.h:535
BOOLEAN DBDEF_NetworkInProfile(ADB_NETWORK_REC *n_ptr)
Checks whether the given network is valid for the current profile. There may be multiple CI+ profiles...
Definition: ap_dbdef.c:9844
Definition: ap_dbdef.h:283
ADB_STRING * DBDEF_ConcatSIString(ADB_STRING *str1, SI_STRING_DESC *str2)
Concatenates an SI_STRING_DESC string to the end of an ADB_STRING string, removing any terminating '\...
Definition: ap_dbdef.c:3903
U16BIT DBDEF_GetNumProfiles(void)
Returns the number of network profiles.
Definition: ap_dbdef.c:9484
BOOLEAN DBDEF_IsValidCridRecord(ADB_CRID_REC *c_ptr)
Checks whether the given crid record is in the list of valid crid records.
Definition: ap_dbdef.c:8503
Definition: stbdpc.h:296
Definition: ap_dbdef.h:298
void DBDEF_SortTimers(BOOLEAN date_time_order)
Sorts timer list into date/time or alphabetical order.
Definition: ap_dbdef.c:9442
void DBDEF_SetNetworkName(ADB_NETWORK_REC *n_ptr, U8BIT *name)
Set or change the name of the given network.
Definition: ap_dbdef.c:4663
BOOLEAN DBDEF_SetLNBUnicable(ADB_LNB_REC *lnb, U32BIT inter_freq, U8BIT chan)
Sets the LNB Unicable settings.
Definition: ap_dbdef.c:4266
void DBDEF_ReleaseProfileList(void **profile_list, U16BIT num_profiles)
Frees a profile list returned by DBDEF_GetProfileList.
Definition: ap_dbdef.c:9600
ADB_SERVICE_REC * DBDEF_GetNextServiceOnTransport(ADB_SERVICE_REC *s_ptr, ADB_TRANSPORT_REC *t_ptr)
Find the next service following the given service that's on the given transport.
Definition: ap_dbdef.c:5991
void DBDEF_DeleteNetworkRec(ADB_NETWORK_REC *n_ptr)
Deletes specified network record.
Definition: ap_dbdef.c:4651
U8BIT * DBDEF_GetEventContentData(ADB_EVENT_REC *e_ptr, U8BIT *p_len)
Returns the level 1 and 2 values for all content identifiers for the given event. ...
Definition: ap_dbdef.c:3377
U8BIT * DBDEF_GetSecondaryTextLang(void)
returns array of secondary text langs
Definition: ap_dbdef.c:7685
void DBDEF_UpdateCridEitDate(ADB_CRID_REC *c_ptr)
Updates the stored EIT date of this CRID with the current GMT date.
Definition: ap_dbdef.c:8416
ADB_NETWORK_REC * DBDEF_GetTunedNetwork(U8BIT path)
gets the currently tuned network
Definition: ap_dbdef.c:7531
void DBDEF_SetServicePmtPid(ADB_SERVICE_REC *s_ptr, U16BIT pmt_pid)
Updates the pmt pid.
Definition: ap_dbdef.c:6746
U8BIT * DBDEF_GetAudioLang(void)
returns current audio lang
Definition: ap_dbdef.c:7739
Definition: ap_dbdef.h:579
void DBDEF_SetTextLang(U8BIT *lang_ids)
sets current text lang
Definition: ap_dbdef.c:7631
ADB_TRANSPORT_REC * DBDEF_GetTunedTransport(U8BIT path)
gets the currently tuned transport
Definition: ap_dbdef.c:7569
ADB_TIMER_REC * DBDEF_GetNextTimerRec(ADB_TIMER_REC *timer_ptr)
Returns the next timer record after the one given. If the argument is NULL then the first record is r...
Definition: ap_dbdef.c:9418
E_STREAM_MATCH_TYPE DBDEF_GetReqdTtextPid(ADB_SERVICE_REC *s_ptr, BOOLEAN for_subtitles, U16BIT *pid_ptr, U8BIT *magazine, U8BIT *page)
Gets the appropriate teletext pid - looks first for the params matching exactly the required teletext...
Definition: ap_dbdef.c:6284
Definition: ap_dbdef.h:291
BOOLEAN DBDEF_TransportInProfile(ADB_TRANSPORT_REC *t_ptr)
Checks whether the given transport is valid for the current profile. There may be multiple CI+ profil...
Definition: ap_dbdef.c:9808
BOOLEAN DBDEF_SetLNB12V(ADB_LNB_REC *lnb, BOOLEAN is_12v)
Sets the LNB 12V setting.
Definition: ap_dbdef.c:4065
Definition: stbsitab.h:403
Definition: stbsitab.h:135
U8BIT * DBDEF_GetServiceGuidance(ADB_SERVICE_REC *s_ptr)
Returns the guidance text for the service, as a UTF-8 string. The returned string should be freed usi...
Definition: ap_dbdef.c:2887
void DBDEF_SetSatTransportTuningParams(ADB_TRANSPORT_REC *t_ptr, U32BIT freq_hz, U16BIT symbol_rate, E_STB_DP_POLARITY polarity, BOOLEAN dvb_s2, E_STB_DP_MODULATION modulation, ADB_NETWORK_REC *network)
Sets the tuning parameters for an existing satellite transport.
Definition: ap_dbdef.c:5210
Application configuration.
Definition: ap_dbdef.h:559
ADB_TIMER_REC * DBDEF_AddTimerRec(BOOLEAN store_in_nvm)
Creates a new timer record in the database, assigning it a unique handle.
Definition: ap_dbdef.c:9329
ADB_SERVICE_REC * DBDEF_AddServiceRec(U16BIT serv_id, ADB_TRANSPORT_REC *t_ptr)
Adds a new service record to the service database with the given service ID and parent transport...
Definition: ap_dbdef.c:5563
Definition: ap_dbdef.h:192
ADB_TIMER_REC * DBDEF_FindTimerRec(U32BIT handle)
Returns the timer record with the given timer handle.
Definition: ap_dbdef.c:9395
void DBDEF_RequestAccess(void)
Requests access to the app's database.
Definition: ap_dbdef.c:220
ADB_SERVICE_REC * DBDEF_GetPrevServiceRec(ADB_SERVICE_REC *s_ptr)
Returns the service before the one given. If NULL is passed then the last service in the list is retu...
Definition: ap_dbdef.c:5470
U8BIT * DBDEF_GetEventName(ADB_EVENT_REC *e_ptr)
Returns the name of the event as a UTF-8 string in the currently selected language. The returned string should be freed using STB_ReleaseUnicodeString.
Definition: ap_dbdef.c:2024
void DBDEF_DeleteRCTLinks(ADB_RCT_LINK_INFO *links)
Frees the given list of RCT links.
Definition: ap_dbdef.c:3770
Definition: ap_dbdef.h:151
BOOLEAN DBDEF_LoadDatabase(U8BIT *db_pathname)
Loads the service database from non-volatile storage and creates the RAM version of this data that wi...
Definition: ap_dbdef.c:244
ADB_LNB_BAND_REC * DBDEF_GetNextLNBBandRec(ADB_LNB_BAND_REC *band_ptr)
Returns the next LNB band record after the one given. If the argument is NULL then the first record i...
Definition: ap_dbdef.c:4542
void DBDEF_PushBroadcastProfile(void)
Saves the current profile and any related data so that it can restored using DBDEF_PopProfile(), and sets the broadcast profile type for for all network, transport and service record accesses.
Definition: ap_dbdef.c:9682
void DBDEF_SetCridService(ADB_CRID_REC *c_ptr, U16BIT serv_id)
Sets the service ID in the crid record.
Definition: ap_dbdef.c:8377
Structure representing the component information as found in the EIT component_descriptor.
Definition: ap_dbacc.h:235
Definition: ap_dbdef.h:506
ADB_FAVSERV_REC * DBDEF_GetNextServiceFromFavouriteList(ADB_FAVLIST_REC *fav_list, ADB_FAVSERV_REC *fav_serv)
Returns the next favourite list service record.
Definition: ap_dbdef.c:9025
BOOLEAN DBDEF_SetLNBSmatv(ADB_LNB_REC *lnb, BOOLEAN is_smatv)
Sets the LNB SMATV setting.
Definition: ap_dbdef.c:4215
BOOLEAN DBDEF_ServiceInProfile(ADB_SERVICE_REC *s_ptr)
Checks whether the given service is valid for the current profile. There may be multiple CI+ profiles...
Definition: ap_dbdef.c:9772
U16BIT DBDEF_GetReqdVideoPid(ADB_SERVICE_REC *s_ptr, ADB_STREAM_TYPE *video_type)
Returns the video pid and type that should be used for the given service from the list of video strea...
Definition: ap_dbdef.c:6415
BOOLEAN DBDEF_TransportForTunerType(ADB_TRANSPORT_REC *t_ptr, E_STB_DP_SIGNAL_TYPE tuner_type, void *satellite)
Checks whether the given transport is a terrestrial, cable or satellite transport, and optionally check whether it's on a particular satellite.
Definition: ap_dbdef.c:9301
BOOLEAN DBDEF_ServiceForTunerType(ADB_SERVICE_REC *s_ptr, E_STB_DP_SIGNAL_TYPE tuner_type, void *satellite)
Checks whether the given service is a terrestrial, cable or satellite service, and optionally check w...
Definition: ap_dbdef.c:9271
BOOLEAN DBDEF_AddAnalogService(void)
Adds an analogue service, transport and, if necessary, network to the database based on the current t...
Definition: ap_dbdef.c:6612
U8BIT * DBDEF_GetServiceDefaultAuthority(ADB_SERVICE_REC *s_ptr)
Returns a copy of the default authority CRID string for the given service. This string will be return...
Definition: ap_dbdef.c:3655
void DBDEF_DeleteServiceFromFavouriteList(ADB_FAVLIST_REC *fav_list, ADB_FAVSERV_REC *fav_serv)
Delete the given service from the given favourite list.
Definition: ap_dbdef.c:9135
void DBDEF_DeleteAllServicesFromFavouriteList(ADB_FAVLIST_REC *fav_list)
Delete the all services from the given favourite list.
Definition: ap_dbdef.c:9169
ADB_SATELLITE_REC * DBDEF_GetNextSatelliteRec(ADB_SATELLITE_REC *sat_ptr)
Returns the next satellite record after the one given. If the argument is NULL then the first record ...
Definition: ap_dbdef.c:4424
ADB_SATELLITE_REC * DBDEF_AddSatelliteRec(ADB_STRING *name_str, U16BIT dish_pos, U16BIT long_pos, BOOLEAN east_west, ADB_LNB_REC *associated_lnb)
Add a satellite record to the database.
Definition: ap_dbdef.c:4333
U8BIT * DBDEF_GetTextLang(void)
returns array of current text langs
Definition: ap_dbdef.c:7649
ADB_FAVSERV_REC * DBDEF_FindServiceInFavouriteList(ADB_FAVLIST_REC *fav_list, void *serv_ptr)
Returns the ADB_FAVSERV_REC from the given favourite list for the given service.
Definition: ap_dbdef.c:8997
Definition: ap_dbdef.h:268
void DBDEF_ClearTableVersionHistory(ADB_TRANSPORT_REC *t_ptr)
Clears the version histories stored in the transport records.
Definition: ap_dbdef.c:5404
U16BIT DBDEF_GetNumSatellites(void)
Returns the number of satellite records in the database.
Definition: ap_dbdef.c:4317
ADB_NETWORK_REC * DBDEF_FindOrAddPrivateNetwork(void *satellite)
Find or add a private network, assigning an unused private network ID.
Definition: ap_dbdef.c:10099
ADB_SERVICE_REC * DBDEF_GetNextServiceRec(ADB_SERVICE_REC *s_ptr)
Returns the service after the one given. If NULL is passed then the first service in the list is retu...
Definition: ap_dbdef.c:5444
ADB_TRANSPORT_REC * DBDEF_FindCableTransportRec(U32BIT freq_hz, U32BIT symbol_rate)
Find the cable transport record in the database matching the given params.
Definition: ap_dbdef.c:5023
ADB_EVENT_DESC * DBDEF_FindEventDescriptor(ADB_EVENT_DESC *start_desc, U8BIT desc_tag, U32BIT private_data_specifier)
Searches a descriptor list for the first descriptor with the given descriptor tag.
Definition: ap_dbdef.c:1972
Application timer functions and defines.
U16BIT DBDEF_GetNumTransports(void)
Returns the number of transports in ther service database.
Definition: ap_dbdef.c:4784
void DBDEF_SetCridDateTime(ADB_CRID_REC *c_ptr, U32DHMS date_time)
Sets the date and time fields in the crid record.
Definition: ap_dbdef.c:8359
void DBDEF_DeleteLNBBandRec(ADB_LNB_BAND_REC *band_ptr)
Deletes an LNB band record from the database.
Definition: ap_dbdef.c:4566
void DBDEF_SetFavouriteListUserData(ADB_FAVLIST_REC *fav_list, U32BIT user_data)
Saves the given user data with a favourite list.
Definition: ap_dbdef.c:8759
ADB_TRANSPORT_REC * DBDEF_FindSatTransportRec(U32BIT freq_hz, U16BIT symbol_rate, E_STB_DP_POLARITY polarity, BOOLEAN dvb_s2, E_STB_DP_MODULATION modulation, void *satellite)
Find the satellite transport record in the database matching the given params.
Definition: ap_dbdef.c:5167
Definition: ap_dbdef.h:316
void DBDEF_TidyDatabaseNordig(E_STB_DP_SIGNAL_TYPE tuner_type, BOOLEAN search_completed, BOOLEAN manual)
Iterates through all the services following a search search to see whether any need to be deleted bas...
Definition: ap_dbdef.c:7848
BOOLEAN DBDEF_SetLNBDiSEqCPosition(ADB_LNB_REC *lnb, BOOLEAN is_diseqc_posn)
Sets the LNB DiSEqC position setting.
Definition: ap_dbdef.c:4115
ADB_NETWORK_REC * DBDEF_GetNextNetworkRec(ADB_NETWORK_REC *n_ptr)
Returns the network following the one given. If the argument is NULL then the first network will be r...
Definition: ap_dbdef.c:4755
void DBDEF_SetSecondaryAudioLang(U8BIT *lang_ids)
sets the secondary audio lang
Definition: ap_dbdef.c:7721
U8BIT * DBDEF_GetEventExtendedDescription(ADB_EVENT_REC *e_ptr)
Returns the extended event description text of the event as a UTF-8 string. The returned string shoul...
Definition: ap_dbdef.c:2271
void DBDEF_DeleteStreamList(ADB_STREAM_REC *slist)
Deletes all records in a service stream list.
Definition: ap_dbdef.c:1910
U16BIT DBDEF_GetNumLNBBands(void)
Returns the number of LNB band records in the database.
Definition: ap_dbdef.c:4448
BOOLEAN DBDEF_SetServiceProviderName(ADB_SERVICE_REC *s_ptr, U8BIT *name)
Set or change the name of a service's provider.
Definition: ap_dbdef.c:5820
E_STREAM_MATCH_TYPE DBDEF_GetReqdSubtitleParams(ADB_SERVICE_REC *s_ptr, U16BIT *pid_ptr, U16BIT *cpage_ptr, U16BIT *apage_ptr)
Gets the appropriate subtitle pid and page ids - looks first for the params matching exactly the requ...
Definition: ap_dbdef.c:6355
void DBDEF_SetFavouriteListName(ADB_FAVLIST_REC *f_ptr, U8BIT *name)
Set or change the name of the given favourite list.
Definition: ap_dbdef.c:9202
void DBDEF_TidyDatabaseDefault(E_STB_DP_SIGNAL_TYPE tuner_type, BOOLEAN search_completed, BOOLEAN manual)
Iterates through all the services following a search search to see whether any need to be deleted bas...
Definition: ap_dbdef.c:8168
U8BIT * DBDEF_GetServiceGuidanceData(ADB_SERVICE_REC *s_ptr, U8BIT *type, U8BIT *mode)
Returns the guidance text for the service, as a UTF-8 string. The returned string should be freed usi...
Definition: ap_dbdef.c:2848
void DBDEF_MoveFavouriteListTo(ADB_FAVLIST_REC *fav_list, S16BIT index)
Changes the order of the favourite lists by moving the given list to the given position.
Definition: ap_dbdef.c:8779
U8BIT DBDEF_GetEventParentalAge(ADB_EVENT_REC *e_ptr)
Returns the parental age value for the given event.
Definition: ap_dbdef.c:2907
BOOLEAN DBDEF_GetEventSubtitlesAvailFlag(ADB_EVENT_REC *e_ptr)
Returns whether DVB subtitles are signalled as being available for the given event.
Definition: ap_dbdef.c:3334
U8BIT DBDEF_NumberOfCridsOfType(ADB_EVENT_REC *e_ptr, U8BIT crid_type)
Returns the number of CRIDs of the given type for the event.
Definition: ap_dbdef.c:3550
Definition: ap_dbdef.h:310
Definition: ap_dbdef.h:139
void DBDEF_SetTransportTransportId(ADB_TRANSPORT_REC *t_ptr, U16BIT tran_id)
Sets the transport ID of the given transport.
Definition: ap_dbdef.c:5318
ADB_SERVICE_REC * DBDEF_NewServiceRec(U16BIT serv_id, ADB_TRANSPORT_REC *t_ptr, BOOLEAN prepend)
Adds a new service record to the service database with the given service ID and parent transport...
Definition: ap_dbdef.c:5498
ADB_CRID_REC * DBDEF_AddCridRecord(U8BIT *crid, BOOLEAN series, BOOLEAN recommended, BOOLEAN radio_service)
Creates a CRID record and adds it to the database.
Definition: ap_dbdef.c:8304
Definition: ap_dbdef.h:275
void DBDEF_TidyDatabaseSatUK(E_STB_DP_SIGNAL_TYPE tuner_type, BOOLEAN search_completed, BOOLEAN manual)
Iterates through all the services following a search search to see whether any need to be deleted bas...
Definition: ap_dbdef.c:8076
U16BIT DBDEF_GetServicePmtPid(ADB_SERVICE_REC *s_ptr)
gets the PMT PID associated with the service
Definition: ap_dbdef.c:6767
BOOLEAN DBDEF_SetServiceName(ADB_SERVICE_REC *s_ptr, U8BIT *name)
Set or change the name of a service.
Definition: ap_dbdef.c:5693
Definition: ap_dbdef.h:550
ADB_TRANSPORT_REC * DBDEF_AddSatTransportRec(U32BIT freq_hz, U16BIT symbol_rate, E_STB_DP_POLARITY polarity, BOOLEAN dvb_s2, E_STB_DP_MODULATION modulation, ADB_NETWORK_REC *network)
Adds a satellite transport record with the given frequency, symbol rate and polarity.
Definition: ap_dbdef.c:5085
Definition: ap_dbdef.h:351
void DBDEF_DeleteRecordsForTunerType(E_STB_DP_SIGNAL_TYPE tuner_type, void *satellite)
Deletes all network, transport and services records for the given tuner type.
Definition: ap_dbdef.c:1564
Definition: ap_dbdef.h:381
ADB_FAVLIST_REC * DBDEF_AddFavouriteList(U8BIT list_id, U8BIT *name, U32BIT user_data, S16BIT index)
Creates a new favourite list and adds it to the list of favourite lists. Creation of the new list wil...
Definition: ap_dbdef.c:8557
BOOLEAN DBDEF_SetLNB22k(ADB_LNB_REC *lnb, BOOLEAN is_22k)
Sets the LNB 22k setting.
Definition: ap_dbdef.c:4040
ADB_CRID_REC * DBDEF_GetNextCridRecord(ADB_CRID_REC *c_ptr)
Returns the next CRID record after the one specified. If the record specified is NULL then the first ...
Definition: ap_dbdef.c:8478
void DBDEF_MoveFavouriteListServiceTo(ADB_FAVLIST_REC *fav_list, ADB_FAVSERV_REC *fav_serv, S16BIT index)
Changes the order of the services in the favourite list by moving the given service to the given posi...
Definition: ap_dbdef.c:9077
void DBDEF_ReleaseString(ADB_STRING *string)
Releases an ADB_STRING.
Definition: ap_dbdef.c:3938
Header file - Function prototypes for linked lists.
Header file - macros and function prototypes for public use.
U8BIT * DBDEF_GetFullCrid(ADB_SERVICE_REC *serv_ptr, U8BIT *event_str)
Returns the full CRID for the given CRID string The returned string should be freed using STB_AppFree...
Definition: ap_dbdef.c:3604
ADB_EVENT_REC * DBDEF_FindScheduleEventById(ADB_SERVICE_REC *s_ptr, U16BIT event_id)
Find an event for a service from its event_id.
Definition: ap_dbdef.c:1936
ADB_SERVICE_REC * DBDEF_GetTunedService(U8BIT path)
Returns the currently tuned service on the given path.
Definition: ap_dbdef.c:7600
Definition: ap_dbdef.h:388
U8BIT * DBDEF_GetEventCrid(ADB_SERVICE_REC *serv_ptr, ADB_EVENT_REC *e_ptr, U8BIT crid_type, U8BIT index)
Returns the full CRID of the type given for the given event.
Definition: ap_dbdef.c:3486
void DBDEF_SortServicesByLcn(void)
Sort the full service list into ascending logical channel number order.
Definition: ap_dbdef.c:6804
ADB_LNB_REC * DBDEF_GetNextLNBRec(ADB_LNB_REC *lnb_ptr)
Returns the next LNB record after the one given. If the argument is NULL then the first record is ret...
Definition: ap_dbdef.c:4293
U8BIT DBDEF_GetEventComponentList(ADB_EVENT_REC *e_ptr, ADB_EVENT_COMPONENT_INFO **component_list)
Retrieves a list of components associated with the specified event, as described by component descrip...
Definition: ap_dbdef.c:3269
void DBDEF_DeleteImageIcons(ADB_IMAGE_ICON *icon_list)
Frees given list of image icons and any associated memory.
Definition: ap_dbdef.c:3804
U16BIT DBDEF_GetReqdAudioPid(ADB_SERVICE_REC *s_ptr, E_STB_DP_AUDIO_MODE *audio_mode, ADB_STREAM_TYPE *audio_type)
Gets the appropriate audio pid - looks first for the pid matching exactly the required audio settings...
Definition: ap_dbdef.c:6178
BOOLEAN DBDEF_SetLNBPulsePosition(ADB_LNB_REC *lnb, BOOLEAN is_pulse_posn)
Sets the LNB pulse position setting.
Definition: ap_dbdef.c:4090
void DBDEF_RemoveEmptyTransports(E_STB_DP_SIGNAL_TYPE tuner_type, void *satellite)
Delete all transport records that don't have any services.
Definition: ap_dbdef.c:8255
ADB_TRANSPORT_REC * DBDEF_FindTransportRecByIds(ADB_TRANSPORT_REC *transp, U32BIT net_id, U32BIT onet_id, U32BIT tran_id)
Find a transport record matching the given set of IDs, starting from the given transport.
Definition: ap_dbdef.c:5264
BOOLEAN DBDEF_AllocateLcns(E_STB_DP_SIGNAL_TYPE tuner_type, BOOLEAN assign_lcns)
allocates lcns - expects allocated lcn for all services to be 0
Definition: ap_dbdef.c:6825
BOOLEAN DBDEF_GetEventAudioDescriptionFlag(ADB_EVENT_REC *e_ptr)
Returns whether audio description is signalled as being available for the given event.
Definition: ap_dbdef.c:2953
BOOLEAN DBDEF_SetLNBPower(ADB_LNB_REC *lnb, E_STB_DP_LNB_POWER power)
Sets the LNB power setting.
Definition: ap_dbdef.c:4015
void DBDEF_DeleteTimerRec(ADB_TIMER_REC *timer)
Deletes the given timer from the database.
Definition: ap_dbdef.c:9462
ADB_STRING * DBDEF_MakeString(U32BIT lang_code, U8BIT *str_ptr, U16BIT nbytes)
Creates an ADB_STRING, copying the given data into it. If the string passed in is NULL or the number ...
Definition: ap_dbdef.c:3845
void DBDEF_DeleteEventList(ADB_EVENT_REC *elist)
Deletes all events in the given list.
Definition: ap_dbdef.c:3709
void DBDEF_Initialise(void)
Initialises the database, preparing for it to be accessed.
Definition: ap_dbdef.c:189
void DBDEF_PopProfile(void)
Restores a previously pushed profile.
Definition: ap_dbdef.c:9749
Definition: stbsitab.h:177
Definition: ap_dbdef.h:121
Definition: stbsitab.h:141
ADB_STREAM_REC * DBDEF_CopyStreamList(ADB_STREAM_REC *slist)
Creates a copy of a stream list, allocating new memory as required.
Definition: ap_dbdef.c:1850
U16BIT DBDEF_GetNumLNBs(void)
Returns the number of LNB records in the database.
Definition: ap_dbdef.c:3954
System Wide Global Technical Data Type Definitions.
ADB_PROFILE_TYPE DBDEF_GetCurrentProfileType(void)
Returns the current profile type.
Definition: ap_dbdef.c:9659
ADB_EVENT_ITEMIZED_INFO * DBDEF_GetEventItemizedDescription(ADB_EVENT_REC *e_ptr, U16BIT *num_items_ptr)
Returns the items of extended event descriptor as item descriptor and item itself.
Definition: ap_dbdef.c:2472
ADB_TRANSPORT_REC * DBDEF_AddTerrestrialTransportRec(U32BIT freq_hz, U8BIT plp_id, ADB_NETWORK_REC *network)
Adds a terrestrial transport record with the given frequency and PLP id.
Definition: ap_dbdef.c:4829
Definition: ap_dbdef.h:93
U16BIT DBDEF_NumStreamsInList(ADB_STREAM_REC *slist)
Returns the number of stream records in the given list.
Definition: ap_dbdef.c:1829
Definition: ap_dbdef.h:525
void DBDEF_DeleteAltServList(ADB_ALT_SERV_REC *aslist)
Deletes all records in a service alternate service list.
Definition: ap_dbdef.c:3752
BOOLEAN DBDEF_SetLNBRepeats(ADB_LNB_REC *lnb, U8BIT repeats)
Sets the LNB message repeat setting in the range 0 to 3.
Definition: ap_dbdef.c:4240
ADB_SERVICE_REC * DBDEF_FindServiceRecByLcn(U16BIT lcn, ADB_TRANSPORT_REC *t_ptr, BOOLEAN allocated_lcn)
Find the service with the given LCN, and optionally on the given transport.
Definition: ap_dbdef.c:6098
void DBDEF_ReleaseAccess(void)
Releases access to the app's database.
Definition: ap_dbdef.c:230
U16BIT DBDEF_GetNumCridRecords(void)
Returns the number of CRID records in the database.
Definition: ap_dbdef.c:8465
ADB_NETWORK_REC * DBDEF_AddNetworkRec(U16BIT net_id, ADB_SATELLITE_REC *satellite)
Adds a new network record to the database with the given network ID.
Definition: ap_dbdef.c:4599
U16BIT DBDEF_GetProfileList(void ***profile_list, U16BIT *active_profile)
Gets a list of the available network profiles.
Definition: ap_dbdef.c:9527
ADB_TRANSPORT_REC * DBDEF_AddCableTransportRec(U32BIT freq_hz, U32BIT symbol_rate, ADB_NETWORK_REC *network)
Adds a cable transport record with the given frequency and symbol rate.
Definition: ap_dbdef.c:4951
ADB_TRANSPORT_REC * DBDEF_FindTerrestrialTransportRec(U32BIT freq_hz, U8BIT plp_id)
Find the terrestrial transport record in the database matching the given params.
Definition: ap_dbdef.c:4921
BOOLEAN DBDEF_SetLNBCSwitch(ADB_LNB_REC *lnb, E_STB_DP_DISEQC_CSWITCH cswitch)
Sets the LNB committed switch setting.
Definition: ap_dbdef.c:4165
void DBDEF_SetCridProgrammeName(ADB_CRID_REC *c_ptr, U8BIT *prog_name)
Sets the programme name field of the given CRID record.
Definition: ap_dbdef.c:8395
ADB_LNB_REC * DBDEF_AddLNB(E_STB_DP_LNB_TYPE type, ADB_STRING *name)
Add an LNB record to the database.
Definition: ap_dbdef.c:3967
void DBDEF_TidyDatabaseAfterSearch(E_STB_DP_SIGNAL_TYPE tuner_type, void *satellite, BOOLEAN search_completed, BOOLEAN manual)
Calls any country and tuner type specific function to tidy up the database following a search...
Definition: ap_dbdef.c:7772
void DBDEF_SetAnalogServiceName(ADB_SERVICE_REC *s_ptr, U8BIT *new_name, U8BIT new_len)
Updates analog service names - ASSUMES NORMAL ASCII CODED.
Definition: ap_dbdef.c:6690
ADB_FAVSERV_REC * DBDEF_GetPrevServiceFromFavouriteList(ADB_FAVLIST_REC *fav_list, ADB_FAVSERV_REC *fav_serv)
Returns the previous favourite list service record.
Definition: ap_dbdef.c:9050
void DBDEF_SetTunedTransport(U8BIT path, ADB_TRANSPORT_REC *t_ptr)
sets the currently tuned transport
Definition: ap_dbdef.c:7550
void DBDEF_DeleteCridRecord(ADB_CRID_REC *c_ptr)
Deletes the given CRID record from the database.
Definition: ap_dbdef.c:8435
Definition: ap_dbdef.h:83
ADB_STRING * DBDEF_GetServiceProviderName(ADB_SERVICE_REC *s_ptr)
Returns a pointer to the service provider name.
Definition: ap_dbdef.c:6566
void DBDEF_SetServiceFavGroups(ADB_SERVICE_REC *s_ptr, U8BIT groups)
Sets the favourite groups for a service.
Definition: ap_dbdef.c:6788
U16BIT DBDEF_GetNumServicesInFavouriteList(ADB_FAVLIST_REC *fav_list)
Returns the number of services in the given favourite list.
Definition: ap_dbdef.c:8885
U16BIT DBDEF_GetReqdADPid(ADB_SERVICE_REC *s_ptr, E_STB_DP_AUDIO_MODE *ad_mode, ADB_STREAM_TYPE *ad_type, BOOLEAN *broadcast_mix)
Gets the appropriate audio description pid - looks first for the pid matching exactly the required au...
Definition: ap_dbdef.c:6232
void DBDEF_SetSecondaryTextLang(U8BIT *lang_ids)
sets secondary text lang
Definition: ap_dbdef.c:7667
Definition: ap_dbdef.h:114
ADB_TRANSPORT_REC * DBDEF_GetNextTransportRec(ADB_TRANSPORT_REC *t_ptr)
Returns the transport following the one given. If the argument is NULL then the first transport will ...
Definition: ap_dbdef.c:4797
ADB_NETWORK_REC * DBDEF_FindNetworkRec(U16BIT net_id, ADB_SATELLITE_REC *satellite)
Finds the network with the given network ID.
Definition: ap_dbdef.c:4727
void DBDEF_DeleteFavouriteList(ADB_FAVLIST_REC *fav_list)
Deletes the given favourite list.
Definition: ap_dbdef.c:8835
ADB_LNB_BAND_REC * DBDEF_AddLNBBandRec(S_STB_DP_LNB_BAND *band_parameters, ADB_LNB_REC *associated_lnb)
Add an LNB band record to the database.
Definition: ap_dbdef.c:4461
void DBDEF_DeleteTransportRec(ADB_TRANSPORT_REC *t_ptr)
Deletes the given transport from the service database.
Definition: ap_dbdef.c:5356
ADB_STRING * DBDEF_CopyString(ADB_STRING *src_str)
Creates a copy of the given ADB_STRING.
Definition: ap_dbdef.c:3877
Definition: ap_dbdef.h:336
void DBDEF_SaveServiceEventSchedule(ADB_SERVICE_REC *s_ptr)
Saves the event schedule of a service to the service database.
Definition: ap_dbdef.c:5904
U16BIT DBDEF_GetNumFavouriteLists(void)
Returns the number of favourite lists.
Definition: ap_dbdef.c:8537
ADB_SERVICE_REC * DBDEF_FindServiceRecByFreesatId(ADB_SERVICE_REC *servp, U16BIT freesat_id)
Search for a service with the given Freesat ID.
Definition: ap_dbdef.c:6132
void DBDEF_SelectBroadcastProfile(void)
Sets the broadcast profile type for for all network, transport and service record accesses...
Definition: ap_dbdef.c:9670
Definition: stbsitab.h:511
void DBDEF_TidyDatabaseUK(E_STB_DP_SIGNAL_TYPE tuner_type, BOOLEAN search_completed, BOOLEAN manual)
Iterates through all the services following a search search to see whether any need to be deleted bas...
Definition: ap_dbdef.c:7990
ADB_FAVSERV_REC * DBDEF_AddServiceToFavouriteList(ADB_FAVLIST_REC *fav_list, ADB_SERVICE_REC *serv_ptr, S16BIT index)
Adds a new service to the given favourite list at the given position.
Definition: ap_dbdef.c:8900
void DBDEF_SetTransportOrigNetworkId(ADB_TRANSPORT_REC *t_ptr, U16BIT orig_net_id)
Sets the original network ID of the given transport.
Definition: ap_dbdef.c:5337
void DBDEF_DeleteAllRecords(void)
Deletes all records in the database.
Definition: ap_dbdef.c:1462
BOOLEAN DBDEF_GetEventHDLinkageInfo(ADB_EVENT_REC *e_ptr, BOOLEAN verify_event, BOOLEAN only_simulcast, ADB_SERVICE_REC **hd_serv_ptr, ADB_EVENT_REC **hd_event_ptr)
Returns whether there's an HD event linked to the SD event and returns the info for it...
Definition: ap_dbdef.c:3011
BOOLEAN DBDEF_IsActiveProfile(ADB_NETWORK_REC *profile)
Is the given profile the currently active profile?
Definition: ap_dbdef.c:9618
Definition: stbllist.h:45
BOOLEAN DBDEF_SetServiceType(ADB_SERVICE_REC *s_ptr, ADB_SERVICE_TYPE serv_type)
Sets the service type for the given service record.
Definition: ap_dbdef.c:5879
ADB_SERVICE_REC * DBDEF_CopyServiceRec(ADB_SERVICE_REC *orig_serv)
Creates a copy of the given service, copying the service's attributes, e.g. service name...
Definition: ap_dbdef.c:5576
BOOLEAN DBDEF_SetLNBUSwitch(ADB_LNB_REC *lnb, U8BIT uswitch)
Sets the LNB uncommitted switch setting.
Definition: ap_dbdef.c:4190
Application database access functions.
Definition: ap_dbdef.h:615
void DBDEF_DeleteServiceRec(ADB_SERVICE_REC *s_ptr)
Deletes specified service record.
Definition: ap_dbdef.c:1730
ADB_FAVLIST_REC * DBDEF_FindFavouriteList(U8BIT list_id)
Return the favourite list with the given list id.
Definition: ap_dbdef.c:8733
BOOLEAN DBDEF_SetServiceShortName(ADB_SERVICE_REC *s_ptr, U8BIT *name)
Set or change the short name of a service.
Definition: ap_dbdef.c:5760
void DBDEF_SetTunedService(U8BIT path, ADB_SERVICE_REC *s_ptr)
Sets the currently tuned service.
Definition: ap_dbdef.c:7582
U8BIT * DBDEF_GetEventDescription(ADB_EVENT_REC *e_ptr)
Returns the short event description text of the event as a UTF-8 string. The returned string should b...
Definition: ap_dbdef.c:2144
ADB_FAVLIST_REC * DBDEF_GetNextFavouriteList(ADB_FAVLIST_REC *fav_list)
Returns the favourite list following the given item.
Definition: ap_dbdef.c:8708
Definition: stbllist.h:38
Definition: ap_dbdef.h:199
BOOLEAN DBDEF_SetLNBDiSEqCTone(ADB_LNB_REC *lnb, E_STB_DP_DISEQC_TONE diseqc_tone)
Sets the LNB DiSEqC tone setting.
Definition: ap_dbdef.c:4140
Header file - macros and function prototypes for public use.
ADB_SERVICE_REC * DBDEF_FindServiceRecByIds(ADB_SERVICE_REC *servp, U32BIT net_id, U32BIT onet_id, U32BIT tran_id, U32BIT serv_id)
Search for a service with the given IDs.
Definition: ap_dbdef.c:6030
U16BIT DBDEF_GetNumNetworks(void)
Returns the number of networks in ther service database.
Definition: ap_dbdef.c:4586
U8BIT * DBDEF_GetSecondaryAudioLang(void)
returns current secondary audio lang
Definition: ap_dbdef.c:7757