aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--vote/vote.ino22
1 files changed, 6 insertions, 16 deletions
diff --git a/vote/vote.ino b/vote/vote.ino
index 44fd179..cc17e79 100644
--- a/vote/vote.ino
+++ b/vote/vote.ino
@@ -41,10 +41,6 @@ struct Vote {
int measure;
};
-void begin();
-String desc();
-int read();
-String debug();
bool push(String id, unsigned long timestamp, int measure);
void printStack();
bool qualifyVote(Vote vote, unsigned long currentTime);
@@ -137,17 +133,6 @@ bool qualifyVote(Vote vote, unsigned long currentTime) {
return false;
}
-/// Dump internal variables, formatted for use with Serial Plotter
-///
-/// @return internal variables as String
-String debug() {
- return static_cast<String>(
- "pin:") + _pin
- + "\tboolState:" + _boolState
- + "\ttime:" + _time
- + "\tcount:" + _count;
-}
-
void setup() {
// enable logging to serial
Serial.begin(115200);
@@ -164,10 +149,15 @@ void setup() {
}
void loop() {
+
BLEScanResults *foundDevices = pBLEScan->start(scanTime, false);
pBLEScan->clearResults();
- printStack();
+ // misuse error-only log level for plot-friendly output
+#if ARDUHAL_LOG_LEVEL == ARDUHAL_LOG_LEVEL_ERROR
+ Serial.printf("pin:%d boolState:%d time:%d count:%d\n",
+ _pin, _boolState, _time, _count);
+#endif
delay(500);
}