supersocket - SuperSocket.SerialIO 2.0.0-beta.30

Serial IO support for SuperSocket

PM> Install-Package SuperSocket.SerialIO -Version 2.0.0-beta.30 -Source https://www.myget.org/F/supersocket/api/v3/index.json

Copy to clipboard

> nuget.exe install SuperSocket.SerialIO -Version 2.0.0-beta.30 -Source https://www.myget.org/F/supersocket/api/v3/index.json

Copy to clipboard

> dotnet add package SuperSocket.SerialIO --version 2.0.0-beta.30 --source https://www.myget.org/F/supersocket/api/v3/index.json

Copy to clipboard
<PackageReference Include="SuperSocket.SerialIO" Version="2.0.0-beta.30" />
Copy to clipboard
source https://www.myget.org/F/supersocket/api/v3/index.json

nuget SuperSocket.SerialIO  ~> 2.0.0-beta.30
Copy to clipboard

> choco install SuperSocket.SerialIO --version 2.0.0-beta.30 --source https://www.myget.org/F/supersocket/api/v2

Copy to clipboard
Import-Module PowerShellGet
Register-PSRepository -Name "supersocket" -SourceLocation "https://www.myget.org/F/supersocket/api/v2"
Install-Module -Name "SuperSocket.SerialIO" -RequiredVersion "2.0.0-beta.30" -Repository "supersocket" -AllowPreRelease
Copy to clipboard

Browse the sources in this package using Visual Studio or WinDbg by configuring the following symbol server URL: https://www.myget.org/F/supersocket/api/v2/symbolpackage/


SuperSocket.SerialIO

Join the chat at https://gitter.im/supersocket/community Build Status NuGet Version NuGet Download

Serial IO support for SuperSocket

The sample code below shows us how we build a serial IO communication server with SuperSocket.

var host = SuperSocketHostBuilder
    .Create<StringPackageInfo, CommandLinePipelineFilter>()
    .UsePackageHandler(async (s, package) =>
        {
            await s.SendAsync(Encoding.UTF8.GetBytes(package.ToString() + "\r\n"));
        })
    .ConfigureSuperSocket(options =>  
        {
            options.Name = "SIOServer";
            options.Listeners = new[] {
                new SerialIOListenOptions()
                {
                    PortName = "COM2",   // serial port name
                    BaudRate = 9600,  // baudRate of the serial port
                    Parity = Parity.None,
                    StopBits = StopBits.None,
                    Databits = 5;  // value limit 5 to 8
                }
            };
        })
    .UseSerialIO()
    .ConfigureLogging((hostCtx, loggingBuilder) => {
        loggingBuilder.AddConsole();
    }).Build();

You also can leave the infromation of Serial IO in the configuration.

{
    "serverOptions": {
        "name": "SIOServer",
        "listeners": [
            {
                "path": "sio://COM1/?BaudRate=9600&Parity=Odd&StopBits=2&Databits=7"
            }
        ]
    }
}
  • .NETFramework 6.0
    • SuperSocket.Server.Abstractions (>= 2.0.0-beta.30)
    • System.IO.Ports (>= 4.7.0)
  • .NETFramework 7.0
    • SuperSocket.Server.Abstractions (>= 2.0.0-beta.30)
    • System.IO.Ports (>= 4.7.0)
  • .NETFramework 8.0
    • SuperSocket.Server.Abstractions (>= 2.0.0-beta.30)
    • System.IO.Ports (>= 4.7.0)
  • .NETFramework 6.0: 6.0.0.0
  • .NETFramework 7.0: 7.0.0.0
  • .NETFramework 8.0: 8.0.0.0

Owners

Kerry Jiang

Authors

SuperSocket Developer Community

Project URL

https://github.com/SuperSocket/SuperSocket.SerialIO

License

Unknown

Info

250 total downloads
64 downloads for version 2.0.0-beta.30
Download (24.93 KB)
Download symbols (28.7 KB)
Found on the current feed only

Package history

Version Size Last updated Downloads Mirrored?
2.0.0 33.1 KB Sun, 20 Apr 2025 22:28:43 GMT 66
2.0.0-beta.30.24 24.94 KB Sun, 26 Jan 2025 20:16:35 GMT 60
2.0.0-beta.30 24.93 KB Sun, 26 Jan 2025 20:23:53 GMT 64
2.0.0-beta.21.23 31.7 KB Sun, 05 May 2024 01:36:59 GMT 60