Esempio n. 1
0
static void diseqc_msg(struct satip_vtuner* vt, struct vtuner_message* msg)
{
    char dbg[50];
    struct diseqc_master_cmd* cmd=&msg->body.diseqc_master_cmd;

    if ( cmd->msg[0] == 0xe0 &&
            cmd->msg[1] == 0x10 &&
            cmd->msg[2] == 0x38 &&
            cmd->msg_len == 4 )
    {
        /* committed switch */
        u8 data=cmd->msg[3];

        if ( (data & 0x01) == 0x01 )
        {
            vt->tone = SEC_TONE_ON; /* high band */
            vt->tone_set=1;
        }
        else if ( (data & 0x11) == 0x10 )
        {
            vt->tone = SEC_TONE_OFF; /* low band */
            vt->tone_set=1;
        }

        if ( (data & 0x02) == 0x02 )
            satip_set_polarization(vt->satip_cfg, SATIPCFG_P_HORIZONTAL);
        else if ( (data & 0x22) == 0x20 )
            satip_set_polarization(vt->satip_cfg, SATIPCFG_P_VERTICAL);

        /* some invalid combinations ? */
        satip_set_position(vt->satip_cfg, ( (data & 0x0c) >> 2) + 1 );
    }
Esempio n. 2
0
static void set_voltage(struct satip_vtuner* vt, struct vtuner_message* msg)
{
    if ( msg->body.voltage == SEC_VOLTAGE_13 )
        satip_set_polarization(vt->satip_cfg, SATIPCFG_P_VERTICAL);
    else if (msg->body.voltage == SEC_VOLTAGE_18)
        satip_set_polarization(vt->satip_cfg, SATIPCFG_P_HORIZONTAL);
    else  /*  SEC_VOLTAGE_OFF */
        satip_lnb_off(vt->satip_cfg);

    DEBUG(MSG_MAIN,"MSG_SET_VOLTAGE:  %d\n",msg->body.voltage);
}
Esempio n. 3
0
static void test_sequencer(void* param)
{
  t_satip_config* sc=(t_satip_config*)param;

  cseq++;
  
  switch (cseq)
    {
    case 1:
      satip_set_freq(sc,118360);
      satip_set_modsys(sc, SATIPCFG_MS_DVB_S);
      satip_set_pilots(sc, SATIPCFG_P_OFF);
      satip_set_fecinner(sc, SATIPCFG_F_34);
      satip_set_polarization(sc, SATIPCFG_P_HORIZONTAL);
      satip_set_rolloff(sc, SATIPCFG_R_0_35);
      satip_set_symbol_rate(sc,27500);
      satip_set_modtype(sc, SATIPCFG_MT_QPSK);
      satip_set_position(sc, 1);
      satip_add_pid(sc, 18);
      break;

    case 200:
      //satip_add_pid(sc, 19);
      break;

    case 400:
      break;

    default: 
      break;
      
    }
}