Receiving a string of characters from a serial port
📁 exception, Advanced Python Topics, example, python3, bots, AI, game, work
This is not a term paper or a diploma project! I haven't been a student for a long time. This is an attempt to write another free program for "home" car diagnostics. And I'm not very strong in Python. So I'm asking for help.
Initial data:
There is a device connected to the computer via a USB port. The computer and the device exchange data in character form. Essentially, this is a classic connection: the device acts as a server, and the computer acts as a terminal. If that means anything to anyone, this device is an OBD-II (On-Board Diagnostics) adapter ELM327.
The system works on a very simple principle — in response to a client (terminal) request (command), the server returns a response. Here is an example of a request-response:
Similar situation on Python2 when receiving information from the UT60D tester, which only transmits signals to the port.
When opening the port with the recommended settings, there is +10 volts at the port input and the signal bursts disappear.
What helped:
ser.rtsToggle=True
Log in to leave an answer
Blogs