I want to send a socket with data (just an integer like "23") from python to a web app that is written using Meteor which is a web framework built on top of node.js and other libraries.
On python side i have the following code:
import serial, socket
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.connect(("localhost", 3000))
s.send ('something')
What do I have to do on Meteor side? Is this python code correct? Is this different from websockets?
Meteor uses the DDP protocol to communicate, so you would have to write a DDP client for Python and either CALL a remote Meteor method or SUB to a published channel.
Some initial work on a python DDP client has been done, but not finished, here: https://github.com/meteor/meteor/blob/master/examples/unfinished/python-ddp-client/ddp-client.py