Can not decode properly IR remote code.


Closed Thread
Results 1 to 11 of 11

Hybrid View

  1. #1
    Join Date
    Feb 2013
    Posts
    1,124


    Did you find this post helpful? Yes | No

    Default Re: Can not decode properly IR remote code.

    Thanks, but your code lacks some commands as I can see, like:

    OSCCON = %01110111

    to set OSC clock to 8mhz

  2. #2
    Join Date
    Feb 2013
    Posts
    1,124


    Did you find this post helpful? Yes | No

    Default Re: Can not decode properly IR remote code.

    And it is quite interesting, if it's possible to decode air conditioner remote codes? they are very long and very weird

  3. #3
    Join Date
    Aug 2008
    Location
    Portugal
    Posts
    240


    Did you find this post helpful? Yes | No

    Default Re: Can not decode properly IR remote code.

    Quote Originally Posted by CuriousOne View Post
    Thanks, but your code lacks some commands as I can see, like:

    OSCCON = %01110111

    to set OSC clock to 8mhz
    You cannot assume that just by see "DEFINE OSC 8", because he can be using an external osc. You can only assume that, it he had post the config fuses.

    One more thing, about this
    There's nothing much to post in schematic, the receiver is hooked as it should, GND goes to GND, VDD goes to VDD, and OUT is connected to PORTC.4
    What's the reference of your IR receiver? Because some need a pull up resistor, when your are not using it.
    Thanks and Regards;
    Gadelhas

  4. #4
    Join Date
    Feb 2013
    Posts
    1,124


    Did you find this post helpful? Yes | No

    Default Re: Can not decode properly IR remote code.

    I've solved the problem, but code is quite weird

    Code looks like this:

    Code:
    MAIN:
    PULSIN FLASH,1,SOMEVAR
    IF SOMEVAR<50 AND SOMEVAR >20 THEN GOTO KOUNT
    GOTO MAIN
    KOUNT:
    INCREMENT=INCREMENT+1
    IF FLASH=1 THEN POS=POS+1 ELSE NEG=NEG+1
    IF INCREMENT>1000 THEN GOTO COMPLETE
    GOTO KOUNT
    COMPLETE:
    IF POS>100 AND POS<300 AND NEG>1000 AND NEG<3000 THEN GOSUB JOB:
    POS=0:NEG=0:INCREMENT=0
    GOTO MAIN
    JOB:
    TOGGLE RELAY1
    RETURN
    END
    Last edited by CuriousOne; - 22nd December 2013 at 18:52.

Similar Threads

  1. remote code learning
    By Bruce in forum Code Examples
    Replies: 20
    Last Post: - 21st February 2021, 15:38
  2. Using Walter's Servo PWM encode / decode code
    By NickMu in forum mel PIC BASIC Pro
    Replies: 0
    Last Post: - 1st November 2012, 23:17
  3. Is this code not initialising the LCD properly?
    By Platypus in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 30th January 2010, 19:14
  4. Hitachi remote code
    By aa222k in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 26th October 2008, 23:20
  5. IR decode problem "hitachi TV remote"
    By chai98a in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 13th March 2006, 15:29

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts