Created
June 29, 2020 07:18
-
-
Save kkmonster/8afa02c5944aadce4b49b120851b3cf4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <Arduino.h> | |
#include "corgi85_blynk.h" | |
void CORGI85_BLINK::loop(void) | |
{ | |
switch (mode) | |
{ | |
case stop: | |
/* code */ | |
break; | |
case setup: | |
/* code */ | |
Blynk.begin(auth, ssid, pass); | |
break; | |
case run: | |
/* code */ | |
break; | |
default: | |
break; | |
} | |
} | |
void CORGI85_BLINK::get(void) | |
{ | |
switch (mode) | |
{ | |
case none: | |
/* code */ | |
break; | |
case setup: | |
/* code */ | |
Blynk.begin(auth, ssid, pass); | |
break; | |
case run: | |
/* code */ | |
break; | |
default: | |
break; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifndef CORGI85_BLYNK_H | |
#define CORGI85_BLYNK_H | |
enum corgi85_blynk_mode | |
{ | |
stop, | |
setup, | |
run | |
}; | |
class CORGI85_BLINK | |
{ | |
public: | |
char auth[] = "YourAuthToken"; | |
void loop(void); | |
uint8_t get () | |
private: | |
corgi85_blynk_mode mode = none; | |
}; | |
#endif |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment