I have a software that reads serial data (in coming bytes for sensor reading) from USB port. For simulation purpose I need to write a python script that continuous writes bytes to the USB port simulating a USB device. I require that the /dev/serial/by_id to be created as the software reads the data from that file itself. I cannot edit the software. How can I make this work. I read through the pyserial documentation but I could not figure it out
Requirements:
- the serial port is accessible at /dev/serial/file
- it is listed by serial.tools.list_ports.