Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
linuxdvb satconf: handle correctly LNB power off
  • Loading branch information
perexg committed Dec 19, 2014
1 parent eae66e1 commit 3c5d409
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
11 changes: 10 additions & 1 deletion src/input/mpegts/linuxdvb/linuxdvb_lnb.c
Expand Up @@ -169,7 +169,16 @@ linuxdvb_lnb_bandstack_tune
( linuxdvb_diseqc_t *ld, dvb_mux_t *lm, linuxdvb_satconf_ele_t *ls, int fd )
{
int pol = linuxdvb_lnb_bandstack_pol((linuxdvb_lnb_t*)ld, lm);
return linuxdvb_diseqc_set_volt(fd, pol);

/* en50494 does not use the voltage tune. this is happend in the switch */
if (ls->lse_en50494)
return 0;

if (ls->lse_parent->ls_diseqc_full || ls->lse_parent->ls_last_pol != pol + 1) {
ls->lse_parent->ls_last_pol = pol + 1;
return linuxdvb_diseqc_set_volt(fd, pol);
}
return 0;
}

/* **************************************************************************
Expand Down
4 changes: 3 additions & 1 deletion src/input/mpegts/linuxdvb/linuxdvb_satconf.c
Expand Up @@ -656,9 +656,11 @@ linuxdvb_satconf_post_stop_mux
( linuxdvb_satconf_t *ls )
{
gtimer_disarm(&ls->ls_diseqc_timer);
if (ls->ls_frontend && ls->ls_lnb_poweroff)
if (ls->ls_frontend && ls->ls_lnb_poweroff) {
linuxdvb_diseqc_set_volt(
((linuxdvb_frontend_t *)ls->ls_frontend)->lfe_fe_fd, -1);
linuxdvb_satconf_reset(ls);
}
}

int
Expand Down

0 comments on commit 3c5d409

Please sign in to comment.