Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- String name = "";
- void setup() {
- Serial.begin(9600);
- }
- void loop() {
- getText();
- if (name != "") {
- Serial.println("HEllo: " + name);
- name = "";
- }
- }
- void getText() {
- while (Serial.available()) {
- name = Serial.readString();
- }
- }
Add Comment
Please, Sign In to add comment