hi,
i am working on a IR-protocol project where i need to demodulate the ASK ir based Packets before doing any operation on them.can anybody suggest me how to demodulate the ASK using msp430fr4133?
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
hi,
i am working on a IR-protocol project where i need to demodulate the ASK ir based Packets before doing any operation on them.can anybody suggest me how to demodulate the ASK using msp430fr4133?
ANUP Sharma41 said:Most of the IR receivers already includes such so on output you have demodulated, logic level signal.
yes that is true but i am using an simple ir led without inbuilt demodulator , so its going to receive the complete modulated signal.
that's why i wanted to demodulate this.
yes you are right, but again i dont know how to demodulate it. can u explain me the demodulation process in detail?
moreover i am using an ir receiver TSMP77000 in order to receive the ir .
>can u explain me the demodulation process in detail?
Unfortunately DSP is off-topic here. In short - in case microcontroller receives logical level modulated IR signal, you can treat it as modulated OOK signal, thus easiest solution in this case would be to use Goertzel frequency detector.
You better drop idea to use simple IR diode but use IR receiver IC instead.
>how you can use the Timer of any MSP430 to demodulate the IR remote signal
You did mean decoding, right? - Because signal going out of IR receiver is already demodulated.
en.wikipedia.org/.../Consumer_IR
Reception of the modulated commands for RC-5, RC-6, and the NEC protocols is easily accomplished with specialized IR receivers, most readily available from Sharp Corporation and Vishay Intertechnology. These receivers include a photo-diode, an automatic gain control (AGC) circuit, and a demodulator. The demodulated signal is then decoded with a microcontroller.
Ilmars,
You are right, most IR-Receivers used to receive IR-Remote signal do include the demodulator. But, there are exceptions. TSMP77000 (from Vishey) is one of the exceptions. When exposed with IR pulse between 20 and 60 kHz, it produces an active low digital output. This is shown as (1) and (2) respectively in my drawing below.
In the old days, one could use a negative edge triggered retriggerable monostable multivibrator to generate the desired envelop shown as (5) in that drawing.
One could use the Timer of MSP430 to do a similar job. For example, use ~1MHz to clock that Timer and one of the CC channels, CCx, in the capture mode to invoke an ISR. This is shown as (3) in my drawing. This ISR does two things. One is to set (5) Env high. The other is to schedule a different CC channel, (4) CCy, in the compare mode. The count for CCy compare is set to the currently captured count of CCx + a constant Max, which is slightly longer than the period of the IR pulse. In the case of 20 to 60 kHz IR pulse, MAX should be slightly bigger than 50.
Now, if the IR pulses continue to arrive, the CCy setting will be updated to a later count. Thus its ISR is never invoked in the presence of incoming IR pulse. When the incoming IR pulses stop, the ISR will be invoked as show in (4). This ISR will clear the Env in (5).
With some modification, this method can be refined to provide immunity to IR noise and occasional missing Rcv pulse. It could also measure the sub-carrier frequency at the same time.
I do not have the stomach to write sample code, especially when it is urgent. But I think it is next to trivial to do.
-OCY
**Attention** This is a public forum