# mfd-serial **Repository Path**: mirrors_intel/mfd-serial ## Basic Information - **Project Name**: mfd-serial - **Description**: No description available - **Primary Language**: Unknown - **License**: MIT - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2025-07-04 - **Last Updated**: 2026-05-02 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README > [!IMPORTANT] > This project is under development. All source code and features on the main branch are for the purpose of testing or evaluation and not production ready. # MFD SERIAL Tool for communication via serial port (e.g UART). ## Usage Open serial connection put serial port and baud rate: port can be e.g. COM1 if windows or /dev/ttyUSB0 if linux ```python serial = SerialConnection(serial_port='/dev/ttyUSB0', baud=115200) ``` Read data from serial: ```python serial.read() ``` Send text msg via serial port ```python serial.send('Text to send') ``` Read until some expression appear: ```python serial.read_until('Module Error') ``` Close serial connection: ```python serial.close() ``` Read in background (e.g. if we want to run tests and log everything what happen on serial port during the test) ```python serial.read_in_background() (... test steps ...) serial_log = serial.get_result() #get_result will automatically close the connection ``` SerialConnection can be used as context manager: ```python with SerialConnection(serial_port='/dev/ttyUSB0', baud=115200) as serial: log = serial.read() ``` ## Issue reporting If you encounter any bugs or have suggestions for improvements, you're welcome to contribute directly or open an issue [here](https://github.com/intel/mfd-serial/issues).