Skip to content
This repository was archived by the owner on Mar 17, 2025. It is now read-only.

Commit 06f7790

Browse files
committed
clean up timing
1 parent 660059c commit 06f7790

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

examples/FirebaseMorse_ESP8266/FirebaseMorse_ESP8266.ino

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,7 @@ void loop() {
7171
}
7272
int upTime = millis() - upStarted;
7373
if (upTime > shortMillis*3) {
74-
// A letter break is 3 * the length of a short (.). We give a lot of
75-
// lee way for poor morse-coders.
74+
// A letter break is 3 * the length of a short (.).
7675
if (currentLetter > morseToCharSize || morseToChar[currentLetter] == '\0') {
7776
Serial.println("Invalid morse char, ignoring");
7877
} else {
@@ -81,9 +80,7 @@ void loop() {
8180
Serial.println("Listening for new letter.");
8281
currentLetter = B1;
8382

84-
if (upTime > shortMillis * 5) {
85-
// A word break is 7 * the length of a short(.). We are being generous and
86-
// accepting anything over 5.
83+
if (upTime > shortMillis * 7) {
8784
currentMessage += " ";
8885
}
8986
} // else the upTime < shortMillis we attribute to button bounce.

0 commit comments

Comments
 (0)