How to send UDP messages to devices on network?

Hi again!
@mhartington @leob @mike I want to send UDP(User Datagram Protocol) messages to clients. Any Service exists in Angular Ionic like $http? Do let me know! Thank You…

No experience with this, but I see 2 Cordova plugins which can do it apparently:

its ok @leob . Do you have experience with socket.IO?

No I don’t have experience with that yet …

I want to add realtime communication (chat function) to my app, but for now I’m planning to use Firebase for that.

When at some point it doesn’t perform well enough or it’s getting to expensive then I’ll look at setting up my own server with or a solution like that.

@leob You have any idea of how to inject those UDP plugins into Angular applications?

Sorry no, but you can look at how ngCordova does that, for instance the battery status plugin (arbitrary example):


ngCordova is just an Angular wrapper around Cordova plugins, the code isn’t difficult to read.
As you see the code for this plugin is just 47 lines.

Bluetooth plugin (a bit longer but still jut 218 lines):