Advertisement
Guest User

Untitled

a guest
Mar 24th, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. //////////// Serial Input 1:
  2. SS25.00
  3. //////////// Serial Output 1:
  4. 25.00
  5.  
  6.  
  7. //////////// Serial Input 2:
  8. SS25.00
  9. //////////// Serial Output 2:
  10. 25���
  11.  
  12.  
  13.  
  14. //////////// CODE:
  15.  
  16. String speed_setting;
  17.  
  18. // Read incoming speed. Formatted as characters: XX.X
  19. for(int i=0; i<5; i++){
  20. char incoming_value = Serial.read(); // TODO: I think this causes the decimal problem
  21. speed_setting += incoming_value;
  22. }
  23. Serial.flush();
  24. Serial.println(speed_setting);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement