Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. Announcements
  3. 💬 Infrared Sender and Receiver

💬 Infrared Sender and Receiver

Scheduled Pinned Locked Moved Announcements
45 Posts 26 Posters 15.0k Views 26 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    bollarcreets
    wrote on last edited by
    #41

    Following (I think) the instructions to the letter:

    • Using a Pro Mini
    • Installed the IRremote library (current version through Arduino Libraries Manager: 2.8.0)
    • Copied exactly the sample code

    When I come to compile, I get the following error:

    /home/pc/Arduino/IrSensor/IrSensor.ino: In function 'void sendRCCode(byte)':
    IrSensor:361:32: error: 'AIWA_RC_T501' was not declared in this scope
         else if (pIr->code.type == AIWA_RC_T501) {
                                    ^~~~~~~~~~~~
    IrSensor:362:15: error: 'class IRsend' has no member named 'sendAiwaRCT501'; did you mean 'sendRC5'?
            irsend.sendAiwaRCT501(pIr->code.value);
                   ^~~~~~~~~~~~~~
                   sendRC5
    IrSensor:364:83: error: 'MITSUBISHI' was not declared in this scope
         else if (pIr->code.type == LG || pIr->code.type == SANYO || pIr->code.type == MITSUBISHI) {
                                                                                       ^~~~~~~~~~
    /home/adams-pc/Arduino/IrSensor/IrSensor.ino: In function 'void dump(decode_results*)':
    IrSensor:419:43: error: 'USECPERTICK' was not declared in this scope
               Serial.print(results->rawbuf[i]*USECPERTICK, DEC);
                                               ^~~~~~~~~~~
    IrSensor:422:49: error: 'USECPERTICK' was not declared in this scope
               Serial.print(-(int)results->rawbuf[i]*USECPERTICK, DEC);
                                                     ^~~~~~~~~~~
    exit status 1
    'AIWA_RC_T501' was not declared in this scope
    

    Am I missing something?

    E 1 Reply Last reply
    0
    • B bollarcreets

      Following (I think) the instructions to the letter:

      • Using a Pro Mini
      • Installed the IRremote library (current version through Arduino Libraries Manager: 2.8.0)
      • Copied exactly the sample code

      When I come to compile, I get the following error:

      /home/pc/Arduino/IrSensor/IrSensor.ino: In function 'void sendRCCode(byte)':
      IrSensor:361:32: error: 'AIWA_RC_T501' was not declared in this scope
           else if (pIr->code.type == AIWA_RC_T501) {
                                      ^~~~~~~~~~~~
      IrSensor:362:15: error: 'class IRsend' has no member named 'sendAiwaRCT501'; did you mean 'sendRC5'?
              irsend.sendAiwaRCT501(pIr->code.value);
                     ^~~~~~~~~~~~~~
                     sendRC5
      IrSensor:364:83: error: 'MITSUBISHI' was not declared in this scope
           else if (pIr->code.type == LG || pIr->code.type == SANYO || pIr->code.type == MITSUBISHI) {
                                                                                         ^~~~~~~~~~
      /home/adams-pc/Arduino/IrSensor/IrSensor.ino: In function 'void dump(decode_results*)':
      IrSensor:419:43: error: 'USECPERTICK' was not declared in this scope
                 Serial.print(results->rawbuf[i]*USECPERTICK, DEC);
                                                 ^~~~~~~~~~~
      IrSensor:422:49: error: 'USECPERTICK' was not declared in this scope
                 Serial.print(-(int)results->rawbuf[i]*USECPERTICK, DEC);
                                                       ^~~~~~~~~~~
      exit status 1
      'AIWA_RC_T501' was not declared in this scope
      

      Am I missing something?

      E Offline
      E Offline
      evb
      wrote on last edited by
      #42

      @bollarcreets, I am afraid that the script has never been adapted to the evolution of the IRRemote library.
      If you take library version 2.2.3, the script will compile.

      If you take the source code from the latest version 2.8.1 you will also see that the typedef enums AIWA_RC_T501 and MITSUBISHI are commented out.

      If you want to run this example script with the latest version of the library, you will need to analyse and understand the script in order to modify it...

      B 1 Reply Last reply
      1
      • E evb

        @bollarcreets, I am afraid that the script has never been adapted to the evolution of the IRRemote library.
        If you take library version 2.2.3, the script will compile.

        If you take the source code from the latest version 2.8.1 you will also see that the typedef enums AIWA_RC_T501 and MITSUBISHI are commented out.

        If you want to run this example script with the latest version of the library, you will need to analyse and understand the script in order to modify it...

        B Offline
        B Offline
        bollarcreets
        wrote on last edited by
        #43

        @evb said in 💬 Infrared Sender and Receiver:

        If you take library version 2.2.3, the script will compile.

        That does indeed work - thanks!

        What's the best way to get the tutorial edited to include this information?

        mfalkviddM 1 Reply Last reply
        0
        • B bollarcreets

          @evb said in 💬 Infrared Sender and Receiver:

          If you take library version 2.2.3, the script will compile.

          That does indeed work - thanks!

          What's the best way to get the tutorial edited to include this information?

          mfalkviddM Offline
          mfalkviddM Offline
          mfalkvidd
          Mod
          wrote on last edited by
          #44

          @bollarcreets I've added a note in the instructions. Please let me know if you think it could be reworded or put someplace else to make it clearer.

          B 1 Reply Last reply
          1
          • mfalkviddM mfalkvidd

            @bollarcreets I've added a note in the instructions. Please let me know if you think it could be reworded or put someplace else to make it clearer.

            B Offline
            B Offline
            bollarcreets
            wrote on last edited by
            #45

            @mfalkvidd thanks, that change is all that's needed I think. Thanks to you and @evb for the prompt help!

            1 Reply Last reply
            1
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            10

            Online

            11.7k

            Users

            11.2k

            Topics

            113.0k

            Posts


            Copyright 2019 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • MySensors
            • OpenHardware.io
            • Categories
            • Recent
            • Tags
            • Popular