Open hunterbeach opened 6 years ago
It's very much a work-in-progress. The websocket server is a replacement for their servers. Once you have the outlets connecting to your instance of the websocket server, you can control them as you wish.
My intention with this is to create a simple interface for detecting and controlling the outlets. It's not quite there yet. Take a look at index.js for an idea of where things are going. I'd love some help if you want to collaborate.
I attempted to have them connect to the websocket instance but couldn't get them to connect. I tried to redirect server2.vesync.com to the instance and also a AWS URL that I saw the outlets sending their response to, to no avail. I would definitely help with it, but I only know the very basics of JS, most of my projects I do in Python. I think I get an idea of what the program is doing, I just can't get the outlets to connect to it.
I finally got one to connect, even though I didn't change anything. So now I have one connected, I just have to figure out how to control them. I see the functions in outlet.js but I'm not too sure how to best access them.
@travissinnott have you seen https://github.com/itsnotlupus/vesync-wsproxy ?
How exactly is this meant to be used? I am trying to control some of these plugs and saw their reply to the server and that brought be here, but the README doesn't specify how this should be used. What is the purpose of the server? Does it take the place of their servers? What is an example of how to use this?