Downloaded bounce. I'm getting this:
Documents\Arduino\libraries\IPodSerialLib/iPodSerial.h:167: error: ISO C++ forbids declaration of 'byte' with no type
for this: (which is his, so I could make sure that I wasn't crazy)
#include <SimpleRemote.h>
#include <Bounce.h>
const byte BUTTON_PIN = 5;
const unsigned long DEBOUNCE_MS = 20;
Bounce button(BUTTON_PIN, DEBOUNCE_MS);
SimpleRemote simpleRemote;
void setup()
{
pinMode(BUTTON_PIN, INPUT);
// enable pull-up
digitalWrite(BUTTON_PIN, HIGH);
simpleRemote.setup();
}
void loop()
{
simpleRemote.loop();
if (button.update())
{
if (button.read() == LOW)
{
// prod the iPod in case it went to sleep since we last talked to it
// (after which older iPods will stop responding to us otherwise)
simpleRemote.sendiPodOn();
delay(50);
simpleRemote.sendButtonReleased();
simpleRemote.sendPlay();
}
else
{
simpleRemote.sendButtonReleased();
}
}
}
I am at a loss. What do I have to do to his library, or my original code (without his library) to just make this durn thing work?