Skip to content

Files

Latest commit

06d413f · Mar 14, 2025

History

History

hio-dotnet.Demos.SimpleDriversServer

Simple Drivers Server

This application creates server that can connect J-Link and PPK. It provides access to HW peripherials for WASM applications.

Server

Server is based on EmbedIO.

It creates:

  • API endpoint
  • Web static server
  • Web Sockets

Structure

This server is very simple. All classes are defined here as part of the HW Drivers.

API and Web Socket has common Controller. It means you can use same commands on API and Web Socket. Each has prepared client.

Usage

Main usage is now for application hio-dotnet.Demos.BlazorComponents.RadzenLib.WASM. In RemoteConsoleService.cs you can see how to use the drivers server.

Hosting of WASM

The server can be used to host the WASM application. In that case publish the WASM app and add it to the server exe/dll folder. Than you will run the server like this:

using hio_dotnet.HWDrivers.Server;

Console.WriteLine("Hello, lets start drivers server :)");
var server = new LocalDriversServer("./BlazorApp");
await server.Start();