ConsumerIrManager.transmit broken in Lollipop?

I updated my Samsung Galaxy S4 from the latest KitKat to Lollipop (5.0.1) and my IR remote app that I have been using for several months has stopped working.

Since I was using a late copy of KitKat ConsumerIrManager, the send () function was sending the number of pulses using the code below. It worked really well.

private void irSend(int freqHz, int[] pulseTrainInMicroS) {
  int [] pulseCounts = new int [pulseTrainInMicroS.length];

  for (int i=0; i<pulseTrainInMicroS.length; i++) {
    long iValue = pulseTrainInMicroS[i] * freqHz / 1000000;
    pulseCounts[i] = (int) iValue;
  } 

  m_IRService.transmit(freqHz, pulseCounts);
}

      

when he stopped working yesterday, I began to look at him closely.

I noticed that the transmitted waveform has nothing to do with the requested pulse train. even the code below is not working correctly! exist

private void TestSend() {
  int [] pulseCounts = {100, 100, 100};

  m_IRService.transmit(38000, pulseCounts);
}

      

the resulting waveforms had many problems and are therefore completely useless.

  • the waveforms were completely wrong
  • the frequency was incorrect and the interval between pulses was not regular.
  • they were not repeated.

looking at the demodulated waveform: if my 100, 100, 100 were displayed correctly, I should have seen two 2.6ms pulses (up to 4.4.3 (?) 100 us). instead I got (see attached) "[demodulated] non-repeatable 1.BMP" and "[demodulated] non-repeatable 2.BMP". note that the waveform is not 2 pulses ... in fact, it doesn't even repeat itself.

as shown below, signal drops when IR signal is detected.

wrong and not repeatable

wrong and not repeatable

we should have seen that the two pulses below are 2.6ms and 2.6ms in between (see green line below).

enter image description here

I also tried shorter pulses using 50, 50, 50 and observed that the first pulse was also not correct (see below).

enter image description here

looking at the modulated signal: the frequency was wrong; instead, it was around 18 kHz and irregular.

wrong frequency and irregular

I am quite experienced with this and have a formal education in electronics.

I think there is a bug in ConsumerIrManager.transmit () ...

Curiously, the "WatchOn" app that comes with the phone is still working.

Thank you for any ideas you can give.

Test Equipment: Tektronix TDS-2014B, 100 MHz, used in peak detection mode.

+3


source to share


1 answer


As @IvanTellez points out, there has been a change regarding this feature in Android. Oddly enough, when I was outputting simple IR signals (for troubleshooting), the function behaves as shown above (chaotic, wrong carrier frequency, etc.). When I eventually went back to normal types of IR signals, it worked correctly.



0


source







All Articles