jaxsonpd / better-serial

A serial terminal that isn't rubbish ish
GNU General Public License v3.0
1 stars 0 forks source link
python3 serial-communication threading

Better Serial

A serial terminal that isn't rubbish. This project was inspired by the sorry state of the serial monitor offering available especially on windows. Its key features are listed below.

Implemented:

To be implemented:

Screenshots

The terminal in dumb mode: dumb mode screen snip

Use

There are two modes for this application. These are detailed in the following sections. The command line arguments for the application can be found by running with the -h flag.

Dumb Terminal

In this mode the serial monitor acts like a dumb terminal sending chars when pressed and writing chars when received. In this mode no special chars can be sent to the device however the special char display switch for incoming data does work.

To exit this mode use <alt-c> which will terminate the send and receive threads.

Local Edit/CMD sender

In this mode the serial monitor has local line edit and allows the sending of special chars using the \xFF or \o888 methods (where \ is a special char and must be escaped). The terminal reads back as normal printing chars when they are received.

To exit this mode use <ctrl-c><ctrl-c> to exit both the send and receive threads.

Installation

Manual run

Clone the git repository and then run:

python3 ./src/main.py

This applications requirements are outlined in requirements.txt. These can be installed using:

pip3 install -r requirements.txt

Pre-compiled

Pre-compiled versions of this application can be found in the releases tab. These have been created using pyinstaller and may or may not work, I make no promises.

Program overview

This application uses multithreading to realise simultaneous send and receive. This allows the use of blocking read and writes simplify the code. There are two threads the first handles receive and print to the terminal com_rx.py and the second handles getting user input and sending to the device com_tx.py.

To Do

Admin/Tidy

Features

Bug Fix