Closed Gohper closed 5 years ago
For other protocols, what about this code, https://github.com/telldus/telldus/blob/master/telldus-core/service/ , possible/useful to convert to python? I the your tellsticknet, it seems to do all that is implemented very good! Oh sending message on the phone, my fingers are to big!
Please feel free to contribute! I'll accept any bug fixes or additions with support for more protocols.
I will try, my time is limited and my skills in python is very basic. But it is just another language with its plus and minus... As i understand the code archtech selflearning is using the built in encoding in the tellstick net. I have a proxy in java which old tellstickd uses. Originally the tellstickd taclked with the first usb connected tellstick. It is written in perl, I modified it so it sends udp packets to the proxy, and I also added a protocol for NEXASL. In the proxy I also used the built in encoding for this, but it does not work for all Nexa devices.... I do not know if the telldus core uses the correct encoding. For example, I have one transmitter which controls two devices, and this works. But when sending the same thing from the telldus net, it does not work, only one device reacts. This must be something with the timing, I think. The Nexa device that does not work is a newer EYCR-2300, but I have older that works. And all they work from Telldus Live... I will dive into the dark world of python after dinner. Anything, trix when running it directly from the clone ?
The time isn't there, but I have som basic functions for Nexa/Arctech codeswitch that seems to produce the correct string. I have not invoked it within the tellsticknet code, this may take a while since I'm new to python. And now the selflearning code...
Allmost there for the Arctech codeswitch...
I assume that the new encoding call is top be in the archtech .py line 27.
if model == "codeswitch": return encode_codeswitch(house, unit, method) elif method == const.TURNON and model == "selflearning-dimmer": method, param = const.DIM, 255 elif method == const.DIM and int(param) == 0: method = const.TURNOFF
Sorry for the code tag layout....
And I also assume that def encode(model, house, unit, method, param, **kwargs): returns bytes. Is this correct?
First I thought that, in the tellstick net, built in support for self learning was used, but it looks like this is encoded in the protocol. Hopefully I will test this during the weekend. :o)
How do I build it? Gives error on all targets...
"Gives error on all targets..." is insufficient information, sorry.
Ok, I have not had the time to dig deeper into this. I will post a log when I have the time.
Hi, tried to turn on an codeswitch device, the log says it is sending selflearning.
Ideas?