Skip to content

Commit 099fd57

Browse files
committed
Set pin mode in setup.
1 parent c87453e commit 099fd57

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/Sensors/DigitalMotionSensor/DigitalMotionSensor.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,13 @@ char clientID[] = "CLIENT_ID";
3232

3333
void setup()
3434
{
35+
pinMode(SENSOR_PIN, INPUT);
3536
Serial.begin(9600);
3637
Cayenne.begin(username, password, clientID);
3738
}
3839

3940
void loop()
4041
{
41-
pinMode(SENSOR_PIN, INPUT);
4242
Cayenne.loop();
4343
checkSensor();
4444
}

0 commit comments

Comments
 (0)