Application level CI Host Control functions.
More...
#include <stdio.h>
#include <string.h>
#include "techtype.h"
#include "dbgfuncs.h"
#include "stbhwos.h"
#include "stberc.h"
#include "stbheap.h"
#include "ap_dbdef.h"
#include "ap_cntrl.h"
#include "stbci.h"
#include "stbcicc.h"
#include "ap_ci_int.h"
#include "ap_ci_support.h"
#include "ap_cihc.h"
Go to the source code of this file.
|
#define | DEBUG_HC |
|
#define | DBG_HC(x, ...) STB_SPDebugWrite( "%s:%d " x, __FUNCTION__, __LINE__, ##__VA_ARGS__); |
|
#define | DBG_ERR(x, ...) STB_SPDebugWrite( "ERROR %s:%d" x, __FUNCTION__, __LINE__, ##__VA_ARGS__); |
|
#define | DTAG_DEL_SYS_DVBT 0x5a |
|
#define | DTAG_DEL_SYS_DVBT2 0x04 |
|
#define | DTAG_DEL_SYS_DVBC 0x44 |
|
#define | DTAG_DEL_SYS_DVBC2 0x0d |
|
#define | DTAG_DEL_SYS_DVBS 0x43 |
|
#define | DTAG_DEL_SYS_DVBS2 0x79 |
|
#define | DTAG_EXT_DESC 0x7f |
|
|
void | ACI_HcInitialise (void) |
| Initialise CI Host Control support.
|
|
void | ACI_HcNotifyHostControlSession (U32BIT module) |
| This function is used by the CI stack to notify the host that a session with the host countrol resource has been opened by the module. This signals to the host that the module intends to request that the host tunes to other transport streams / services. Following this notification, the host must call the function STB_CIAskRelease to request that the module closes the session. The function STB_CIAskReleaseReply will be called to let the host know whether the control over the tuner has been released or not. More...
|
|
void | ACI_HcNotifyHostControlSessionClosed (U32BIT module) |
| This function is used by the CI stack to notify the host that a session with the host control resource has been closed by the module. This signals to the host that it has controls over the tuner and it does not need to call STB_CIAskRelease before using it. Following this call, any PIDs that have been replaced by STB_CIReplace should be restored, if possible. More...
|
|
BOOLEAN | ACI_HcAskRelease (U32BIT module) |
| Ask the module to restore replaced PIDs and to close the session with the host control resource. More...
|
|
void | ACI_HcAskReleaseReply (U32BIT module, U8BIT release_reply) |
| This function is called by the CI+ stack to send the reply of a release request to the host. This function is called in response to a call to STB_CIAskRelease. The host must not assume that it has control over the tuner until this function is called. More...
|
|
void | ACI_HcTune (U32BIT module, U16BIT nid, U16BIT onid, U16BIT tsid, U16BIT sid) |
| Handle Tune request from the CAM. More...
|
|
void | ACI_HcTuneBroadcastRequest (U32BIT module, U16BIT service_id, U16BIT desc_loop_len, U8BIT *desc_loop, U8BIT *pmt, E_CIP_TUNE_FLAGS flags) |
| This function is used by the CI+ stack to request that the host tunes to a transport stream using the given parameters. If the service_id is zero, the host should not report a PMT using STB_CIUpdatePmt(). If the PMT is provided, it should be used when selecting elementary streams on the service. The PMT is not provided if service_id is zero. Following the tune operation (whether successful or not), the host must call the function STB_CITuneReply(). More...
|
|
void | ACI_HcTuneService (U32BIT module, void *s_ptr, E_CIP_TUNE_FLAGS flags) |
| Handle tune to service request from the CAM. More...
|
|
BOOLEAN | ACI_HcTuneReply (U32BIT module, E_STB_CI_TUNE_STATUS status) |
| Send status of tune operation to the CAM host control module. More...
|
|
Application level CI Host Control functions.
- Date
- December 2016
- Author
- Adam Sturtridge
Definition in file ap_cihc.c.
◆ ACI_HcAskRelease()
BOOLEAN ACI_HcAskRelease |
( |
U32BIT |
module | ) |
|
Ask the module to restore replaced PIDs and to close the session with the host control resource.
- Parameters
-
module | specifies module required |
- Returns
- TRUE if operation successful, FALSE otherwise
Definition at line 236 of file ap_cihc.c.
◆ ACI_HcAskReleaseReply()
void ACI_HcAskReleaseReply |
( |
U32BIT |
module, |
|
|
U8BIT |
release_reply |
|
) |
| |
This function is called by the CI+ stack to send the reply of a release request to the host. This function is called in response to a call to STB_CIAskRelease. The host must not assume that it has control over the tuner until this function is called.
- Parameters
-
module | specifies module required |
release_reply | the reply to the release request |
Definition at line 278 of file ap_cihc.c.
◆ ACI_HcNotifyHostControlSession()
void ACI_HcNotifyHostControlSession |
( |
U32BIT |
module | ) |
|
This function is used by the CI stack to notify the host that a session with the host countrol resource has been opened by the module. This signals to the host that the module intends to request that the host tunes to other transport streams / services. Following this notification, the host must call the function STB_CIAskRelease to request that the module closes the session. The function STB_CIAskReleaseReply will be called to let the host know whether the control over the tuner has been released or not.
- Parameters
-
module | host control module |
Definition at line 118 of file ap_cihc.c.
◆ ACI_HcNotifyHostControlSessionClosed()
void ACI_HcNotifyHostControlSessionClosed |
( |
U32BIT |
module | ) |
|
This function is used by the CI stack to notify the host that a session with the host control resource has been closed by the module. This signals to the host that it has controls over the tuner and it does not need to call STB_CIAskRelease before using it. Following this call, any PIDs that have been replaced by STB_CIReplace should be restored, if possible.
- Parameters
-
module | - host control module |
Definition at line 184 of file ap_cihc.c.
◆ ACI_HcTune()
void ACI_HcTune |
( |
U32BIT |
module, |
|
|
U16BIT |
nid, |
|
|
U16BIT |
onid, |
|
|
U16BIT |
tsid, |
|
|
U16BIT |
sid |
|
) |
| |
Handle Tune request from the CAM.
- Parameters
-
module | Host control module |
nid | network ID |
onid | original network ID |
tsid | transport stream ID |
sid | service ID |
Definition at line 321 of file ap_cihc.c.
◆ ACI_HcTuneBroadcastRequest()
void ACI_HcTuneBroadcastRequest |
( |
U32BIT |
module, |
|
|
U16BIT |
service_id, |
|
|
U16BIT |
desc_loop_len, |
|
|
U8BIT * |
desc_loop, |
|
|
U8BIT * |
pmt, |
|
|
E_CIP_TUNE_FLAGS |
flags |
|
) |
| |
This function is used by the CI+ stack to request that the host tunes to a transport stream using the given parameters. If the service_id is zero, the host should not report a PMT using STB_CIUpdatePmt(). If the PMT is provided, it should be used when selecting elementary streams on the service. The PMT is not provided if service_id is zero. Following the tune operation (whether successful or not), the host must call the function STB_CITuneReply().
- Parameters
-
module | host control module |
service_id | the service to tune to |
desc_loop_len | length of descriptor loop in bytes |
desc_loop | the descriptor loop |
pmt | the PMT to use (or NULL) |
flags | flags to pass to presentation engine |
Definition at line 396 of file ap_cihc.c.
◆ ACI_HcTuneReply()
BOOLEAN ACI_HcTuneReply |
( |
U32BIT |
module, |
|
|
E_STB_CI_TUNE_STATUS |
status |
|
) |
| |
Send status of tune operation to the CAM host control module.
- Parameters
-
module | host control module |
status | tune operation status |
- Returns
- TRUE if valid module, FALSE otherwise
Definition at line 591 of file ap_cihc.c.
◆ ACI_HcTuneService()
void ACI_HcTuneService |
( |
U32BIT |
module, |
|
|
void * |
s_ptr, |
|
|
E_CIP_TUNE_FLAGS |
flags |
|
) |
| |
Handle tune to service request from the CAM.
- Parameters
-
module | Host control module |
s_ptr | service |
flags | flags to pass to presentation engine |
Definition at line 553 of file ap_cihc.c.