Go Down

Topic: IRRemote PC Control Help (Read 771 times) previous topic - next topic

amansammy

Hello everyone!  :)
Just build a IRRemote reciever with arduino and it works great. The HEX codes of my remote buttons are all well displayed on the serial monitor. What I want to do is control my PC(volume, brightness stuff) using this.
I think I worked this out a bit(although compiling a working code goes up my mind :smiley-slim:)
The HEX codes of the volume up and down button on my remote would be used the trigger the volume of my PC.

Volume UP      :     2028877
Volume DOWN :     20208F7

The reciever code is this:
Code: [Select]

#include <IRremote.h>

int RECV_PIN = 11;

IRrecv irrecv(RECV_PIN);

decode_results results;

void setup()
{
  Serial.begin(9600);
  irrecv.enableIRIn();
}

void loop() {
  if (irrecv.decode(&results)) {
    Serial.println(results.value, HEX);
    irrecv.resume();
  }
}


Anyone done this before?

Please help what to do next.

Thank You! :)

HazardsMind

Try to incorporate this into your code somehow. it is designed to put in certain key strokes and log off the computer, the same may be done with Vol up and down.

http://arduino.cc/en/Tutorial/KeyboardLogout
My GitHub:
https://github.com/AndrewMascolo?tab=repositories

amansammy

There is an error of Keyboard only supported in Arduino Leonardo.
Anything else?

HazardsMind

http://hackaday.com/2012/06/29/turning-an-arduino-into-a-usb-keyboard/
My GitHub:
https://github.com/AndrewMascolo?tab=repositories

amansammy

Another problem, this needs Arduino Leonardo or Uno. I only have Duemilanove. :(

HazardsMind

ok,
http://www.practicalarduino.com/projects/virtual-usb-keyboard
http://arduino.cc/forum/index.php/topic,39243.0.html

My GitHub:
https://github.com/AndrewMascolo?tab=repositories

Go Up