MeshRuby
Ruby library for the MeshBlu IoT messaging platform.
Technical Details
- socket.io-client-simple as a SocketIO client.
- EventMachine for single threaded concurrency goodness.
Pushes incoming messages (background thread) into an EM::Queue object that executes in the main thread.
Project Status: Active
Under active maintenance but still in early development. The only event that is currently implemented is onmessage. Support the project by submitting an issue (you'll win our friendship forever)!
Example
Receive messages from MeshBlu and send a response:
friends = ['00000000-0000-0000-0000-000000000000']
uid = '11111111-1111-1111-1111-111111111111'
token = '22222222222222222222222222222222'
EM.run do
mesh = EM::MeshRuby.new(uid, token)
mesh. { |msg| mesh.emit(friends, "Thanks! :)") }
end
Otherstuff
Licensed under the Ruby License. Built with love by DataMelon