I would like to find the best way to connect javascript to a c# engine.
In my case I have a c# process that manages the raspberry GPIOs and I want to expose a set of functions to multiple js clients which can also be remote.
I tried to implement an MQ service with serialization commands in JSON but the structure to expose all the commands and manage the response of the functions is very elaborate.
my engine exposes workbench with a list of example functions:
public interface IWorkbench
{
public void SetDigitalOutput(byte[] output);
public byte[] GetDigitalInput();
public double GetTemperatureBySensor();
}
I need to be able from a js client to call this set of functions and get the result. What can I use to make my life easy?