en-us_commands:reference:filo
Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| en-us_commands:reference:filo [2026/09/07 21:52] – 만듦 - 바깥 편집 127.0.0.1 | en-us_commands:reference:filo [2026/09/14 20:30] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 14: | Line 14: | ||
| ===== Example ===== | ===== Example ===== | ||
| + | |||
| + | Send '' | ||
| <code cpp> | <code cpp> | ||
| - | uint16_t | + | uint16_t |
| - | FILO(0, | + | uint16_t lastNumber = 0; |
| + | |||
| + | void setup() { | ||
| + | Serial.begin(115200); | ||
| + | } | ||
| + | |||
| + | void loop() { | ||
| + | if (!Serial.available()) return; | ||
| + | const char action = Serial.read(); | ||
| + | const bool store = action == ' | ||
| + | const bool retrieve = action == ' | ||
| + | const bool clearBuffer = action == ' | ||
| + | if (store) ++nextNumber; | ||
| + | |||
| + | const bool ok = FILO(0, | ||
| + | FILO(0, false, false, nextNumber, lastNumber, 16, false); // Return both inputs to LOW so the next character creates a new rising edge. | ||
| + | if (retrieve && ok) Serial.println(lastNumber); | ||
| + | if (retrieve && !ok) Serial.println(F(" | ||
| + | } | ||
| </ | </ | ||
| Line 23: | Line 43: | ||
| '' | '' | ||
| + | |||
| + | ===== Built-in Commands in the Same Category ===== | ||
| + | |||
| + | * [[: | ||
| [[: | [[: | ||
en-us_commands/reference/filo.1788785565.txt.gz · Last modified: by 127.0.0.1
