You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a .net standard 2.0 dll (Drivers.CommunicationLocal) which is referencing SerialPort class. When I try to use this from a .Net 4.6.1 console app or a xUnit (.net core 2.0) on windows 10, I get the following exception. Using it from UWP app works fine.
System.PlatformNotSupportedException: System.IO.Ports is currently only supported on Windows.
at System.IO.Ports.SerialPort..ctor(String portName, Int32 baudRate, Parity parity, Int32 dataBits)
at Drivers.CommunicationLocal.CommunicationLayerSerialPortLocal..ctor(SettingSerialPortLocal settings) in C:\Users\abc\Documents\Visual Studio 2017\Projects\experiment\senna\src\Drivers.CommunicationLocal\CommunicationLayerSerialPortLocal.cs:line 24