*****************************************************************************/
+#include "scan.h"
+
/*****************************************************************************
* Devices location
*****************************************************************************/
} demux_handle_t;
typedef struct frontend_t frontend_t;
+typedef struct
+{
+ int i_snr; /**< Signal Noise ratio */
+ int i_ber; /**< Bitrate error ratio */
+ int i_signal_strenth; /**< Signal strength */
+} frontend_statistic_t;
+
+typedef struct
+{
+ bool b_has_signal;
+ bool b_has_carrier;
+ bool b_has_lock;
+} frontend_status_t;
typedef struct en50221_session_t
{
FREENULL( p_object->u.menu.psz_bottom );
for ( i = 0; i < p_object->u.menu.i_choices; i++ )
{
- FREENULL( p_object->u.menu.ppsz_choices[i] );
+ free( p_object->u.menu.ppsz_choices[i] );
}
FREENULL( p_object->u.menu.ppsz_choices );
break;
demux_handle_t p_demux_handles[MAX_DEMUX];
frontend_t *p_frontend;
bool b_budget_mode;
+ bool b_scan_mode;
/* CA management */
int i_ca_handle;
/* */
int i_read_once;
+ int i_stat_counter;
+
#ifdef ENABLE_HTTPD
/* Local HTTP server */
httpd_host_t *p_httpd_host;
vlc_mutex_t httpd_mutex;
vlc_cond_t httpd_cond;
mtime_t i_httpd_timeout;
- bool b_request_frontend_info, b_request_mmi_info;
+ bool b_request_frontend_info, b_request_mmi_info;
char *psz_frontend_info, *psz_mmi_info;
char *psz_request;
#endif
+
+ /* Scan */
+ scan_t scan;
};
#define VIDEO0_TYPE 1
/*****************************************************************************
* Prototypes
*****************************************************************************/
+
int FrontendOpen( access_t * );
void FrontendPoll( access_t *p_access );
int FrontendSet( access_t * );
void FrontendStatus( access_t * );
#endif
+int FrontendGetStatistic( access_t *, frontend_statistic_t * );
+void FrontendGetStatus( access_t *, frontend_status_t * );
+int FrontendGetScanParameter( access_t *, scan_parameter_t * );
+
int DMXSetFilter( access_t *, int i_pid, int * pi_fd, int i_type );
int DMXUnsetFilter( access_t *, int i_fd );
en50221_mmi_object_t *p_object );
void en50221_End( access_t * );
+char *dvbsi_to_utf8( const char *psz_instring, size_t i_length );
+
#ifdef ENABLE_HTTPD
int HTTPOpen( access_t *p_access );
void HTTPClose( access_t *p_access );
-char *HTTPExtractValue( char *psz_uri, const char *psz_name,
- char *psz_value, int i_value_max );
+const char *HTTPExtractValue( const char *psz_uri, const char *psz_name,
+ char *psz_value, int i_value_max );
#endif
+/*****************************************************************************
+ * Hacks
+ *****************************************************************************/
+#define STRINGIFY( z ) UGLY_KLUDGE( z )
+#define UGLY_KLUDGE( z ) #z
+