Skip to content

Instantly share code, notes, and snippets.

@dmiddlecamp
Created January 20, 2015 20:17
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dmiddlecamp/04c6f0591c736f12f710 to your computer and use it in GitHub Desktop.
Save dmiddlecamp/04c6f0591c736f12f710 to your computer and use it in GitHub Desktop.
Sample Spark.function 'nyan' / rainbow firmware!
void setup() {
Spark.function("nyan", nyanHandler);
}
void loop() {
//nothing to see here!
}
int nyanHandler(String cmd) {
if (cmd == "on") {
Spark_Signal(true);
}
else if (cmd == "off") {
Spark_Signal(false);
}
}
@Tekee
Copy link

Tekee commented Mar 21, 2018

Does anyone know why this coding doesn't work anymore?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment