Closed MatyasK closed 6 years ago
You need to add a type. For RM Pro use
device = broadlink.rm((RMIPAddress, RMPort), RMMACAddress,10141)
at the first line of the sendCommand
method.
However, this only solves the "learning" part. The sending part has a whole bunch of issues. It seems that the broadlink lib was updated and we need to make a few changes to support it.
I think I have a solution. I'm still doing more testing, but expect a PR very soon
@eyalellenbogen What were the other issues with sending? Once the device is initialized with the proper device type, the rest should work fine. I'm just wondering what issue you had so I can test.
@uudruid74 a lot has happened since and I kind of forgot :). But, if you try sending data you'll probably stumble on the same issues. Unless you're having no problems... in that case it's probably something I did wrong.
@MatyasK Should be fixed in my tree.
@eyalellenbogen Everything is working great
Resolved by #13
The ip and mac address is correct.
Exception happened during processing of request from ('192.168.10.22', 63908) Traceback (most recent call last): File "/usr/lib/python2.7/SocketServer.py", line 290, in _handle_request_noblock self.process_request(request, client_address) File "/usr/lib/python2.7/SocketServer.py", line 318, in process_request self.finish_request(request, client_address) File "/usr/lib/python2.7/SocketServer.py", line 331, in finish_request self.RequestHandlerClass(request, client_address, self) File "/usr/lib/python2.7/SocketServer.py", line 652, in init self.handle() File "/usr/lib/python2.7/BaseHTTPServer.py", line 340, in handle self.handle_one_request() File "/usr/lib/python2.7/BaseHTTPServer.py", line 328, in handle_one_request method() File "server.py", line 56, in do_GET result = getTempRM() File "server.py", line 177, in getTempRM device = broadlink.rm((RMIPAddress, RMPort), RMMACAddress) TypeError: init() takes exactly 4 arguments (3 given)