DVBCore  20.3.0
DVBCore Documentation
stbinit.c
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  *******************************************************************************/
25 //---includes for this file----------------------------------------------------
26 // compiler library header files
27 
28 // third party header files
29 
30 // Ocean Blue Software header files
31 #include <techtype.h>
32 #include <dbgfuncs.h>
33 
34 #include "stbhwfp.h"
35 #include "stbhwini.h"
36 #include "stbgc.h"
37 #include "stbdpc.h"
38 #include "stberc.h"
39 #include "stbheap.h"
40 #include "stbsic.h"
41 
42 #include "stbpvr.h"
43 
44 #include "stbpes.h"
45 #include "stbebutt.h"
46 #include "stbvbi.h"
47 #include "stbds.h"
48 #include "stbresmgr.h"
49 #include "stbhwos.h"
50 
51 #include "stbinit.h"
52 #include "stbvtc.h"
53 
54 #include "ca_glue.h"
55 
56 //---macro definitions for this file-------------------------------------------
57 
58 //---constant definitions for this file----------------------------------------
59 
60 //---local typedef structs for this file---------------------------------------
61 
62 //---local (static) variable declarations for this file------------------------
63 // (internal variables declared static to make them local)
64 
65 //---global variable definitions-----------------------------------------------
66 
67 //---local function prototypes for this file-----------------------------------
68 // (internal functions declared static to make them local)
69 
70 //---local function definitions------------------------------------------------
71 
72 //---global function definitions-----------------------------------------------
73 
85 void STB_Initialise(E_STB_TTXT_SUBT_CONTROL ttxt_subt_cntrl)
86 {
87  BOOLEAN heap_initialised = FALSE;
88 
89  FUNCTION_START(STB_Initialise);
90 
91  switch (ttxt_subt_cntrl)
92  {
93  case EBU_SUBTITLES:
94  STB_HWInitialise(HW_SUBT_EBU);
95  break;
96 
97  case DVB_SUBTITLES:
98  STB_HWInitialise(HW_SUBT_DVB);
99  STB_HeapInitialise();
100  heap_initialised = TRUE;
103  break;
104 
105  case DVB_SUBTITLES_AND_TELETEXT:
106  STB_HWInitialise(HW_SUBT_EBU | HW_SUBT_DVB);
107  STB_HeapInitialise();
108  heap_initialised = TRUE;
112  break;
113 
114  case DECODED_TELETEXT_WITH_VBI:
115  STB_HWInitialise(HW_SUBT_NONE);
116  STB_HeapInitialise();
117  heap_initialised = TRUE;
121  break;
122 
123  case DECODED_TELETEXT_WITHOUT_VBI:
124  STB_HWInitialise(HW_SUBT_NONE);
125  STB_HeapInitialise();
126  heap_initialised = TRUE;
129  break;
130 
131  case VBI_TELETEXT:
132  STB_HWInitialise(HW_SUBT_NONE);
133  STB_HeapInitialise();
134  heap_initialised = TRUE;
137  break;
138 
139  default:
140  STB_HWInitialise(HW_SUBT_NONE);
141  break;
142  }
143 
144  if (heap_initialised == FALSE)
145  {
146  STB_HeapInitialise();
147  }
148 
150 
154 
156 
158 
160 
161  FUNCTION_FINISH(STB_Initialise);
162 }
163 
164 //*****************************************************************************
165 // End of file
166 //*****************************************************************************
167 
void STB_SUBInitialise(void)
Initialises subtitling control.
Definition: stbdsc.c:942
void STB_GCInitialise(void)
Initialises general control.
Definition: stbgc.c:582
BOOLEAN STB_RESInitialise(void)
Creates and initialises control structures for the resources to be managed.
Definition: stbresmgr.c:117
Header file - macros and function prototypes for public use.
Header file - Function prototypes for DVB subtitles.
Header file - macros and function prototypes for public use.
void STB_Initialise(E_STB_TTXT_SUBT_CONTROL ttxt_subt_cntrl)
Initialises STB layer.
Definition: stbinit.c:85
Header file - macros and function prototypes for public use.
Header file - EBU Teletext driver.
BOOLEAN STB_PVRInitialise(void)
Initialises PVR path control.
Definition: stbpvr.c:363
Header file - macros and function prototypes for public use.
Debug functions header file.
Header file - macros and function prototypes for public use.
Header file - Function prototypes for Event Reporting.
Glue layer between DVB and conditional access systems.
Header file - Function prototypes for operating system.
System Wide Global Technical Data Type Definitions.
void STB_VBIInitialise(void)
Initialises VBI insertion, and registers the callback function with PES collection task...
Definition: stbvbi.c:137
STB middleware resource management module header file.
Header file - Function prototype for init function.
BOOLEAN STB_EBUTT_Initialise(void)
This must be called to invoke the EBU TeleText driver module before all other functionality can be ac...
Definition: stbebutt.c:11061
Header file - macros and function prototypes for public use.
Header file - Function prototypes for heap memory.
BOOLEAN STB_CAInitialise(void)
Called once on system startup to allow initialisation of the CA systems.
Definition: ca_glue.c:61
void STB_PesCollectionTaskInitialise(void)
Initialises the PES collection task.
Definition: stbpes.c:416
void STB_DPInitialise(void)
Initialises decode path control and sets up the structures for restricting access to resources...
Definition: stbdpc.c:331
Header file - Function prototypes for PES collection task.
void STB_HWInitialise(E_HW_SUBT_CONTROL_MASK hw_subt)
Initialise the platform layer by calling the platform layer initialisation functions that are appropr...
void STB_VTInitialise(void)
Initialise the VTC module.
Definition: stbvtc.c:84
void STB_SITerrInitialise(void)
Initialises STB layer SI engine - terrestrial version.
Definition: stbsiflt.c:2092
Header file for the function prototypes for registering callback function to process Teletext into th...
Header file - Function prototypes for front panel control.