We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d05dfbf commit 219c6e8Copy full SHA for 219c6e8
java/libraries/serial/examples/SimpleRead/SimpleRead.pde
@@ -54,9 +54,9 @@ void setup() {
54
55
void loop() {
56
if (digitalRead(switchPin) == HIGH) { // If switch is ON,
57
- Serial.print(1, BYTE); // send 1 to Processing
+ Serial.write(1); // send 1 to Processing
58
} else { // If the switch is not ON,
59
- Serial.print(0, BYTE); // send 0 to Processing
+ Serial.write(0); // send 0 to Processing
60
}
61
delay(100); // Wait 100 milliseconds
62
0 commit comments