|
37 | 37 |
|
38 | 38 |
|
39 | 39 | cli = argparse.ArgumentParser( |
40 | | - description="A minimal serial ternimal.", |
| 40 | + description="A minimal serial terminal. To exit the program, press the escape key and enter 'exit' followed by enter.", |
41 | 41 | formatter_class=argparse.ArgumentDefaultsHelpFormatter |
42 | 42 | ) |
43 | 43 |
|
|
46 | 46 | cli.add_argument("-n", "--noecho", default=False, action="store_true", |
47 | 47 | help="Direct character transmission. Does not echo the user input to stdout.") |
48 | 48 | cli.add_argument( "--escape", default="\033", type=str, action="store", |
49 | | - help="Change the default escape character (escape)") |
| 49 | + help="Change the default escape character (␛).") |
50 | 50 | cli.add_argument("-b", "--baudrate", default=115200, type=int, action="store", |
51 | 51 | help="The baudrate used for the communication.") |
52 | 52 | cli.add_argument("-f", "--format", default="8N1", type=str, action="store", |
53 | 53 | help="Configuration-triple: xyz with x=bytelength in bits {5,6,7,8}, y=parity {N,E,O}, z=stopbits {1,2}.") |
54 | 54 | cli.add_argument("-w", "--write", metavar="logfile", type=str, action="store", |
55 | | - help="Write received data into a file") |
| 55 | + help="Write received data into a file.") |
56 | 56 | cli.add_argument("device", type=str, action="store", |
57 | 57 | help="Path to the serial communication device.") |
58 | 58 |
|
@@ -81,7 +81,7 @@ def ReceiveData(uart, term): |
81 | 81 |
|
82 | 82 | # Shutdown receiver thread |
83 | 83 | ShutdownReceiver = True |
84 | | - if ReceiverThread.isAlive(): |
| 84 | + if ReceiverThread.is_alive(): |
85 | 85 | ReceiverThread.join() |
86 | 86 |
|
87 | 87 |
|
@@ -233,7 +233,7 @@ def main(): |
233 | 233 | # Shutdown receiver thread |
234 | 234 | global ShutdownReceiver |
235 | 235 | ShutdownReceiver = True |
236 | | - if ReceiverThread.isAlive(): |
| 236 | + if ReceiverThread.is_alive(): |
237 | 237 | ReceiverThread.join() |
238 | 238 |
|
239 | 239 | # Clean up everything |
|
0 commit comments