Copy and paste the code below into a blank Arduino sketch. Then compile and upload it to your Metro.
// CIRC11 - Relay int relayPin = 2; void setup() { pinMode(relayPin, OUTPUT); } void loop() { digitalWrite(relayPin, HIGH); delay(1000); digitalWrite(relayPin, LOW); delay(1000); }
The example code uses pin 13 and we have the relay connected to pin 2. Make sure you made this change in the code:
LED_BUILTIN -> 2
The transistor or coil portion of the circuit isn't quite working. Check the transistor is plugged in the right way.