![]() ![]() #Modified code from main loop: s = serial.Serial(5) #Modified code from thread reading the serial port while 1: tdata = s.read # Wait forever for anything time.sleep(1) # Sleep (or inWaiting doesn't give the correct value) dataleft = s.inWaiting # Get. Using a combination of read with no timeout and the inWaiting method.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |