Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Accessing the SerialPort class using .Net Core 3.0

I'm starting a new .NET Core 3.0 project in which I need to access the System.IO.Ports.SerialPort class. The documentation I'm reading on the class shows that it is applicable to .NET Core 3 ( see the bottom of https://docs.microsoft.com/en-us/dotnet/api/system.io.ports.serialport?view=netcore-3.0 ). However when I add a using statement to my class it isn't able to resolve System.IO.Ports. Is there some additional step that needs to be done to reference the SerialPort class for a .NET Core 3.0 program running on the Windows desktop?

like image 933
Joel Avatar asked Oct 06 '19 15:10

Joel


Video Answer


1 Answers

Found the answer a few moments after I posted this question. To use the SerialPort class there is an additional package that needs to be installed. I was able click QuickActions icon to install the package.

enter image description here

like image 130
Joel Avatar answered Oct 02 '22 12:10

Joel