Skip to content

Instantly share code, notes, and snippets.

@monkbroc

monkbroc/press.ino

Created Nov 6, 2015
Embed
What would you like to do?
Photon Button Press
void loop() {
static bool pressedOld = false;
bool pressed = HAL_Core_Mode_Button_Pressed(50);
if (pressed && !pressedOld) {
Particle.publish("press");
}
pressedOld = pressed;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.