Reading the time (MSF77)
First try this code to make sure the receiver is working. Wire an LED to PB0 and pin T of the receiver to PB3 and also wire
G to 0V
V to 3V
P1 to 0V (turns the receiver on)
and the LED should flash as the signal comes in. Next step decoding it...
void setup() {
pinMode(PB3, INPUT);
pinMode(PB0, OUTPUT);
// flash a couple of times so we know chip is on
digitalWrite(PB0, HIGH);
delay(250);
digitalWrite(PB0, LOW);
delay(250);
digitalWrite(PB0, HIGH);
delay(250);
digitalWrite(PB0, LOW);
delay(250);
}
void loop() {
int a = digitalRead(PB3);
if (a == 0) {
digitalWrite(PB0, LOW);
} else {
digitalWrite(PB0, HIGH);
}
}
The datasheet tells you which pins...