dotnet / dotnet/dotnet-api-docs
System.IO.Ports.SerialPort.PortName should start with "/dev/" on Linux
- Dominant language
- C#
- Stars
- 949
- Forks
- 1.7k
- Avg merge
- 3d 27m
- Merged PRs (30d)
- 49
Description
In , a user constructed ` System.IO.Ports.SerialPort` with "ttyACM0" as `PortName` on Linux and then wondered why it did not work. It would be useful to document that the port name on Linux should be an absolute path such as "/dev/ttyACM0", rather than only the basename "ttyACM0". This would go on the following pages:
- [SerialPort Constructors](https://docs.microsoft.com/dotnet/api/system.io.ports.serialport.-ctor?view=dotnet-plat-ext-3.1), in the description of the `portName` parameter of each constructor that has one
- [SerialPort.PortName Property](https://docs.microsoft.com/en-us/dotnet/api/system.io.ports.serialport.portname?view=dotnet-plat-ext-3.1)
The implementation of the SerialPort.GetPortNames() method appears to return names in the correct format already.
Contributor guide
Assessment
This issue has not been assessed yet.