mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-31 09:21:09 +02:00
Multistreamfix for BCM45308X (thx Janus for testing, thx Tangocash)
Origin commit data
------------------
Branch: ni/coolstream
Commit: bc55856454
Author: BPanther <bpanther_ts@hotmail.com>
Date: 2020-10-21 (Wed, 21 Oct 2020)
------------------
No further description and justification available within origin commit message!
------------------
This commit was generated by Migit
This commit is contained in:
@@ -159,7 +159,7 @@ class CFrontend
|
|||||||
//uint32_t numDeliverySystems;
|
//uint32_t numDeliverySystems;
|
||||||
t_channel_id channel_id;
|
t_channel_id channel_id;
|
||||||
|
|
||||||
bool buildProperties(const FrontendParameters*, struct dtv_properties &);
|
bool buildProperties(const FrontendParameters*, struct dtv_properties &, bool useMultistream);
|
||||||
|
|
||||||
FrontendParameters getFrontend(void) const;
|
FrontendParameters getFrontend(void) const;
|
||||||
void secSetTone(const fe_sec_tone_mode_t mode, const uint32_t ms);
|
void secSetTone(const fe_sec_tone_mode_t mode, const uint32_t ms);
|
||||||
|
@@ -80,8 +80,8 @@ extern int zapit_debug;
|
|||||||
|
|
||||||
#define FE_COMMON_PROPS 2
|
#define FE_COMMON_PROPS 2
|
||||||
#define FE_DVBS_PROPS 6
|
#define FE_DVBS_PROPS 6
|
||||||
#define FE_DVBS2_PROPS 8
|
#define FE_DVBS2_PROPS 10
|
||||||
#define FE_DVBS2X_PROPS 9
|
#define FE_DVBS2X_PROPS 10
|
||||||
#define FE_DVBC_PROPS 6
|
#define FE_DVBC_PROPS 6
|
||||||
#define FE_DVBT_PROPS 10
|
#define FE_DVBT_PROPS 10
|
||||||
#define FE_DVBT2_PROPS 11
|
#define FE_DVBT2_PROPS 11
|
||||||
@@ -89,13 +89,13 @@ extern int zapit_debug;
|
|||||||
/* stolen from dvb.c from vlc */
|
/* stolen from dvb.c from vlc */
|
||||||
static const struct dtv_property dvbs_cmdargs[] = {
|
static const struct dtv_property dvbs_cmdargs[] = {
|
||||||
{ DTV_CLEAR, {0,0,0}, { 0 }, 0 },
|
{ DTV_CLEAR, {0,0,0}, { 0 }, 0 },
|
||||||
{ DTV_FREQUENCY, {0,0,0}, { 0 }, 0 },
|
{ DTV_FREQUENCY, {} , { 0 }, 0 },
|
||||||
{ DTV_MODULATION, {0,0,0}, { QPSK }, 0 },
|
{ DTV_MODULATION, {} , { QPSK }, 0 },
|
||||||
{ DTV_INVERSION, {0,0,0}, { INVERSION_AUTO }, 0 },
|
{ DTV_INVERSION, {} , { INVERSION_AUTO }, 0 },
|
||||||
{ DTV_SYMBOL_RATE, {0,0,0}, { 27500000 }, 0 },
|
{ DTV_SYMBOL_RATE, {} , { 27500000 }, 0 },
|
||||||
{ DTV_DELIVERY_SYSTEM, {0,0,0}, { SYS_DVBS }, 0 },
|
{ DTV_DELIVERY_SYSTEM, {} , { SYS_DVBS }, 0 },
|
||||||
{ DTV_INNER_FEC, {0,0,0}, { FEC_AUTO }, 0 },
|
{ DTV_INNER_FEC, {} , { FEC_AUTO }, 0 },
|
||||||
{ DTV_TUNE, {0,0,0}, { 0 }, 0 }
|
{ DTV_TUNE, {} , { 0 }, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
static const struct dtv_property dvbs2_cmdargs[] = {
|
static const struct dtv_property dvbs2_cmdargs[] = {
|
||||||
@@ -108,6 +108,8 @@ static const struct dtv_property dvbs2_cmdargs[] = {
|
|||||||
{ DTV_INNER_FEC, {} , { FEC_AUTO }, 0 },
|
{ DTV_INNER_FEC, {} , { FEC_AUTO }, 0 },
|
||||||
{ DTV_PILOT, {} , { PILOT_AUTO }, 0 },
|
{ DTV_PILOT, {} , { PILOT_AUTO }, 0 },
|
||||||
{ DTV_ROLLOFF, {} , { ROLLOFF_AUTO }, 0 },
|
{ DTV_ROLLOFF, {} , { ROLLOFF_AUTO }, 0 },
|
||||||
|
{ DTV_STREAM_ID, {} , { NO_STREAM_ID_FILTER }, 0 },
|
||||||
|
{ DTV_STREAM_ID, {} , { NO_STREAM_ID_FILTER }, 0 }, // twice for BCM45308X
|
||||||
{ DTV_TUNE, {} , { 0 }, 0 }
|
{ DTV_TUNE, {} , { 0 }, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -122,6 +124,7 @@ static const struct dtv_property dvbs2x_cmdargs[] = {
|
|||||||
{ DTV_PILOT, {} , { PILOT_AUTO }, 0 },
|
{ DTV_PILOT, {} , { PILOT_AUTO }, 0 },
|
||||||
{ DTV_ROLLOFF, {} , { ROLLOFF_AUTO }, 0 },
|
{ DTV_ROLLOFF, {} , { ROLLOFF_AUTO }, 0 },
|
||||||
{ DTV_STREAM_ID, {} , { NO_STREAM_ID_FILTER }, 0 },
|
{ DTV_STREAM_ID, {} , { NO_STREAM_ID_FILTER }, 0 },
|
||||||
|
{ DTV_STREAM_ID, {} , { NO_STREAM_ID_FILTER }, 0 }, // twice for BCM45308X
|
||||||
{ DTV_TUNE, {} , { 0 }, 0 }
|
{ DTV_TUNE, {} , { 0 }, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -1455,7 +1458,7 @@ void CFrontend::setName(const char* _name)
|
|||||||
snprintf(info.name, sizeof(info.name)-1, "%s", _name);
|
snprintf(info.name, sizeof(info.name)-1, "%s", _name);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool CFrontend::buildProperties(const FrontendParameters *feparams, struct dtv_properties& cmdseq)
|
bool CFrontend::buildProperties(const FrontendParameters *feparams, struct dtv_properties& cmdseq, bool useMultistream)
|
||||||
{
|
{
|
||||||
fe_pilot_t pilot = PILOT_OFF;
|
fe_pilot_t pilot = PILOT_OFF;
|
||||||
int fec;
|
int fec;
|
||||||
@@ -1606,16 +1609,24 @@ bool CFrontend::buildProperties(const FrontendParameters *feparams, struct dtv_p
|
|||||||
case DVB_S:
|
case DVB_S:
|
||||||
case DVB_S2:
|
case DVB_S2:
|
||||||
if (feparams->delsys == DVB_S2) {
|
if (feparams->delsys == DVB_S2) {
|
||||||
|
if (useMultistream) {
|
||||||
|
nrOfProps = FE_DVBS2X_PROPS;
|
||||||
|
memcpy(cmdseq.props, dvbs2x_cmdargs, sizeof(dvbs2x_cmdargs));
|
||||||
|
cmdseq.props[MIS].u.data = feparams->plp_id | (feparams->pls_code << 8) | (feparams->pls_mode << 26);
|
||||||
|
} else {
|
||||||
nrOfProps = FE_DVBS2_PROPS;
|
nrOfProps = FE_DVBS2_PROPS;
|
||||||
memcpy(cmdseq.props, dvbs2_cmdargs, sizeof(dvbs2_cmdargs));
|
memcpy(cmdseq.props, dvbs2_cmdargs, sizeof(dvbs2_cmdargs));
|
||||||
|
}
|
||||||
|
|
||||||
cmdseq.props[MODULATION].u.data = feparams->modulation;
|
cmdseq.props[MODULATION].u.data = feparams->modulation;
|
||||||
cmdseq.props[ROLLOFF].u.data = feparams->rolloff;
|
cmdseq.props[ROLLOFF].u.data = feparams->rolloff;
|
||||||
cmdseq.props[PILOTS].u.data = pilot;
|
cmdseq.props[PILOTS].u.data = pilot;
|
||||||
#if ! HAVE_CST_HARDWARE
|
|
||||||
cmdseq.props[MIS].u.data = feparams->plp_id | (feparams->pls_code << 8) | (feparams->pls_mode << 26);
|
|
||||||
#endif
|
|
||||||
if (zapit_debug)
|
if (zapit_debug)
|
||||||
printf("[fe%d/%d] tuner pilot %d (feparams %d) streamid (%d/%d/%d)\n", adapter, fenumber, pilot, feparams->pilot, feparams->plp_id, feparams->pls_code, feparams->pls_mode);
|
if (useMultistream)
|
||||||
|
printf("[fe%d/%d] tuner pilot %d (feparams %d) streamid (%d/%d/%d)\n", adapter, fenumber, pilot, feparams->pilot, feparams->plp_id, feparams->pls_code, feparams->pls_mode );
|
||||||
|
else
|
||||||
|
printf("[fe%d/%d] tuner pilot %d (feparams %d)\n", adapter, fenumber, pilot, feparams->pilot);
|
||||||
} else {
|
} else {
|
||||||
memcpy(cmdseq.props, dvbs_cmdargs, sizeof(dvbs_cmdargs));
|
memcpy(cmdseq.props, dvbs_cmdargs, sizeof(dvbs_cmdargs));
|
||||||
nrOfProps = FE_DVBS_PROPS;
|
nrOfProps = FE_DVBS_PROPS;
|
||||||
@@ -1722,7 +1733,7 @@ int CFrontend::setFrontend(const FrontendParameters *feparams, bool nowait)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!buildProperties(feparams, cmdseq))
|
if (!buildProperties(feparams, cmdseq, isMultistream))
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user