mercredi 9 août 2017

Create WebInterface that accesses hardware functions like tcp on hosted server

Ive done a lot of researching but I'm a bit overwhelmed by the possibilities i seem to have.

What i want to achieve:

I need to develop a web interface on a linux/windows server, which communicates through tcp via the opc protocol to control some leds. the plan is that the web interface would open a tcp socket server, where the clients with the leds can connect. when the user gives data to the web interface, it then sends the opc data via the socket to all connected clients (or selected clients). it should also be possible for the web interface to receive answers from the clients.

the problem is, that until now i only had a web interface which i programmed in plain js/php/html, without any help of a framework or something like that. with that knowledge it is very difficult to imagine how i should realize the communication via tcp. as far as i know plain javascript or php does not support tcp sockets.

1. Websockets I tried to achieve a similar function with that implementation once, but the problem is that i have to write a separate websocketserver which adds another source for failings. it seemed not to be very stable, which is why i would prefer a "direct" tcp socket connection.

2. Frameworks Is there a framework which can level me up from plain js/php/html which adds the required functionality? what additional function would a framework give me? I'm not quite understanding the need of a framework.

3. ASP asp.net seems to be what i want to achieve. a "single-application" web interface which can also target server hardware like tcp or serial. But the problem would be, i think, the enourmous learning curve when developing such an app. i'm also not sure if mono can run the asp.net with full functionality at the moment.

So long story short, what would your approach be?

Aucun commentaire:

Enregistrer un commentaire