Exemplo n.º 1
0
  @Override
  public void unregisterTap(Tap tap) {
    mFSKDecoder.unregisterTap(tap);

    switch (tap.getName()) {
      case INSTRUMENT_BANDPASS_FILTER_TO_FSK2_DEMOD:
        mBandPassFilter.setListener(mFSKDecoder);
        break;
      case INSTRUMENT_FSK2_DECODER_TO_MESSAGE_FRAMER:
        mFSKDecoder.setListener(mTowerMessageFramer);
        break;
    }
  }
Exemplo n.º 2
0
  @Override
  public void registerTap(Tap tap) {
    mFSKDecoder.registerTap(tap);

    switch (tap.getName()) {
      case INSTRUMENT_BANDPASS_FILTER_TO_FSK2_DEMOD:
        FloatBufferTap bpTap = (FloatBufferTap) tap;
        mBandPassFilter.setListener(bpTap);
        bpTap.setListener(mFSKDecoder);
        break;
      case INSTRUMENT_FSK2_DECODER_TO_MESSAGE_FRAMER:
        BinaryTap decoderTap = (BinaryTap) tap;
        mFSKDecoder.setListener(decoderTap);
        decoderTap.setListener(mTowerMessageFramer);
        break;
    }
  }
Exemplo n.º 3
0
  @Override
  public void removeTap(Tap tap) {
    if (mSymbolFilter != null) {
      mSymbolFilter.removeTap(tap);
    }

    if (mCQPSKDemodulator != null) {
      mCQPSKDemodulator.removeTap(tap);
    }

    switch (tap.getName()) {
      case INSTRUMENT_COMPLEX_INPUT:
        removeComplexListener((ComplexTap) tap);
        break;
      case INSTRUMENT_BASEBAND_FILTER_OUTPUT:
        mBasebandFilter.setListener(mAGC);
        break;
      case INSTRUMENT_AGC_OUTPUT:
        mAGC.setListener(mCQPSKDemodulator);
        break;
      case INSTRUMENT_QPSK_DEMODULATOR_OUTPUT:
        mCQPSKDemodulator.setListener(mCQPSKSlicer);
        break;
      case INSTRUMENT_CQPSK_SLICER_OUTPUT:
        mCQPSKSlicer.removeListener((DibitTap) tap);
        break;
      case INSTRUMENT_REAL_INPUT:
        FloatTap inputAGC = (FloatTap) tap;
        removeRealListener(inputAGC);
        addRealSampleListener(mDGC);
        break;
      case INSTRUMENT_DGC_OUTPUT:
        mDGC.setListener(mSymbolFilter);
        break;
      case INSTRUMENT_C4FM_SYMBOL_FILTER_OUTPUT:
        mSymbolFilter.setListener(mC4FMSlicer);
        break;
      case INSTRUMENT_C4FM_SLICER_OUTPUT:
        DibitTap slicerTap = (DibitTap) tap;

        if (mC4FMSlicer != null) {
          mC4FMSlicer.removeListener(slicerTap);
        }
        break;
    }
  }
Exemplo n.º 4
0
 @Override
 public void unregisterTap(Tap tap) {
   if (tap.getName().contentEquals(INSTRUMENT_SYMBOL_SPREAD)) {
     mSymbolSpreadTap = null;
   }
 }
Exemplo n.º 5
0
  @Override
  public void addTap(Tap tap) {
    if (mSymbolFilter != null) {
      mSymbolFilter.addTap(tap);
    }

    if (mCQPSKDemodulator != null) {
      mCQPSKDemodulator.addTap(tap);
    }

    switch (tap.getName()) {
      case INSTRUMENT_COMPLEX_INPUT:
        addComplexListener((ComplexTap) tap);
        break;
      case INSTRUMENT_BASEBAND_FILTER_OUTPUT:
        ComplexTap baseband = (ComplexTap) tap;
        mBasebandFilter.setListener(baseband);
        baseband.setListener(mAGC);
        break;
      case INSTRUMENT_AGC_OUTPUT:
        ComplexTap agcSymbol = (ComplexTap) tap;
        mAGC.setListener(agcSymbol);
        agcSymbol.setListener(mCQPSKDemodulator);
        break;
      case INSTRUMENT_QPSK_DEMODULATOR_OUTPUT:
        QPSKTap qpsk = (QPSKTap) tap;
        mCQPSKDemodulator.setListener(qpsk);
        qpsk.setListener(mCQPSKSlicer);
        break;
      case INSTRUMENT_CQPSK_SLICER_OUTPUT:
        mCQPSKSlicer.addListener((DibitTap) tap);
        break;
      case INSTRUMENT_REAL_INPUT:
        FloatTap inputAGC = (FloatTap) tap;
        removeRealListener(mDGC);
        addRealSampleListener(inputAGC);
        inputAGC.setListener(mDGC);
        break;
      case INSTRUMENT_DGC_OUTPUT:
        FloatTap dgcSymbol = (FloatTap) tap;
        mDGC.setListener(dgcSymbol);
        dgcSymbol.setListener(mSymbolFilter);
        break;
      case INSTRUMENT_C4FM_SYMBOL_FILTER_OUTPUT:
        FloatTap symbolSlicer = (FloatTap) tap;
        mSymbolFilter.setListener(symbolSlicer);
        symbolSlicer.setListener(mC4FMSlicer);
        break;
      case INSTRUMENT_C4FM_SLICER_OUTPUT:
        DibitTap slicer = (DibitTap) tap;

        if (mC4FMSlicer != null) {
          mC4FMSlicer.addListener(slicer);
        }

        if (mCQPSKSlicer != null) {
          mCQPSKSlicer.addListener(slicer);
        }
        break;
    }
  }