Need help in IR remote transmitter using PIC24F controller

Thread Starter

namratha_r

Joined Jan 27, 2015
23
Hi..,

I need help in how to control the appliances at-least using IR transmitter with pic controller. Have gone through the IR remote Hex codes but clearly not understanding. Right now i have generated 38Khz PWM frequency with 50% duty cycle.
 

Thread Starter

namratha_r

Joined Jan 27, 2015
23
Actually from IR learner I learnt IR remote hex value
Code:
0000 0070 0000 0032 0080 003E 0011 000D 0011 002E 0011 000E 0011 000D 0011 000D 0011 000D 0011 000D 0011 000D 0011 000D 0010 000F 0011 000D 0011 000D 0011 000D 0011 002E 0011 000D 0011 000D 0011 000D 0011 000D 0011 000D 0011 000D 0011 000D 0011 000D 0011 000D 0011 002E 0011 000D 0011 000D 0011 000D 0011 000D 0011 000D 0010 000D 0011 000D 0011 000D 0011 002E 0011 000D 0011 002E 0011 002E 0011 002E 0011 002E 0011 000D 0011 000F 0011 002E 0011 000D 0011 002E 0011 002F 0011 002E 0011 002E 0011 000D 0011 002E 0011 0AB5
This is the ir hex code learnt (Panasonic power button hex value) . So, keeping constant 38khz carrier frequency am not getting how to vary the time period and calculation for that because for each hex code different period is there. This part is very confusing
 

jpanhalt

Joined Jan 18, 2008
11,087
Let's see if this helps:
upload_2015-4-2_8-43-58.png

That image is from a Vishay TSOP38xx datasheet. I believe almost any Vishay datasheet will have the same data. View that output as a series of 1's and 0's. Your 38 KHz "carrier" is turned on and off. When it is on for approximately 600 uS, the output drops to zero; when it is off for approximately 600 uS, the output goes high. You get your code of 1's and 0's by changing the periods for which the 38 KHz carrier is on or off.

That is explained in much more detail here, along with some coding schemes: http://www.vishay.com/docs/80071/dataform.pdf

One problem that you will encounter is that the on and off periods are not very constant. Thus, some method that looks at the transitions is often used to avoid dependency on that time. The Vishay document linked to above explains that too.

John
 

Papabravo

Joined Feb 24, 2006
21,225
In the Vishay document, the section on the NEC code is the one I am most familiar with. They all depend on the ability of the transmitter to turn the 38 kHz. carrier on and off in a predictable way to encode the 1's and 0's. The transmitter and receiver must agree on what the protocol is for modulating the 38 kHz. carrier. In the NEC code, note the usage of redundant complement bytes as a method of error detection and to make the transmission of all messages the same length regardless of the pattern of 1's and 0's.
 
Top