I'm new to this and I need help with my project. I recently got this UNO R3 Super Starter Kit and I thought I'd make a Remote Controlled car out of this. I decided I'd use the IR sensor and the IR Remote to do this. I'll program it so that when I press the "Up" button on the remote, it would cause my Elegoo UNO R3 board to start the DC Motor to turn the wheel of the car. Here is my code but when I upload it, it says error status 1 error compiling for Arduino Uno:
#include <IRremote.h>
#include <IRremoteInt.h>
//www.elegoo.com
//2016.12.9
#include "IRremote.h"
int receiver = 11; // Signal Pin of IR receiver to Arduino Digital Pin 11
/*-----( Declare objects )-----*/
IRrecv irrecv(receiver); // create instance of 'irrecv'
decode_results results; // create instance of 'decode_results'
/*-----( Function )-----*/
void translateIR() // takes action based on IR code received
// describing Remote IR codes
{
switch(results.value)
{
case 0xFF906F: pinMode (3,OUTPUT);
pinMode (4,OUTPUT);
pinMode (5,OUTPUT); break;
}// End Case
}
void loop() /*----( LOOP: RUNS CONSTANTLY )----*/
{
}
What am I doing wrong?