Open dzwiedzmin opened 4 years ago
Just as a follow up. This was caused because I was trying to use codes captured by Somfy Telis 4 Remote. You cannot duplicate this remote, but using the buckets I was able to add a new remote. In my case I had to use repeat=2 for PROG (had no reaction with other values) and repeat=16 for other commands (otherwise sometimes the blinds stopped half-way).
I would recommend adding another param to __parge_B1:
def __parge_B1(self, b1String, device):
call it using:
if len(args.b1string) > 0:
parsedConfig = self.__parge_B1(args.b1string, args.device)
and only calculating the device and rolling code from the captured b1string if no device supplied.
if device is None:
execute the rest of the block, excluding the last return line
If anybody has similar issues hope this will work for you as well.
Thanks for the follow up. I'll add the information about the Telis 4 to the readme and will look into your proposed change.
I experienced the same issues as @dzwiedzmin with my Somfy Telis 4 RTS and a Somfy Telis Soliris RTS. Created a pull request which skips B1 parsing if device was specified as suggested .
I don't like the idea of passing the device into the parsing method. As far as I understand, the parsing of the buckets and pulse values works for your B1 string, but decoding the payload doesn't work. Maybe splitting the decoding in those two steps is a better way.
@dzwiedzmin / @tza4s do the bucket values from your B1 string work? I added buckets.md where we can collect working bucket timings. Maybe the parsing of a B1 isn't necessary at all.
/edit: mixed up B0 and B1
I am currently setting up everything (Sonoff, flash Tasmota+Portish) and had troubles with the B1 parsing.
Not sure yet, if my Buckets will work. I will post an update in a couple of days and after further tests.
I don't like the idea of passing the device into the parsing method. As far as I understand, the parsing of the buckets and pulse values works for your B1 string, but decoding the payload doesn't work. Maybe splitting the decoding in those two steps is a better way.
@dzwiedzmin / @tza4s do the bucket values from your B1 string work? I added buckets.md where we can collect working bucket timings. Maybe the parsing of a B1 isn't necessary at all.
/edit: mixed up B0 and B1
This just seems like a solution to avoid the error with the least refactoring. The bucket parsing works, and the payload parsing is not needed when device provided as a param.
I just configured 2 pieces of TELIS SOLARIS RTS, where 2 of them had the issue described in this report. B1 string looking like this:
AA B1 05 0A14 1306 051E 0280 7F30 48080808080808092A2A2B3A2B3A2B3B3B3B3B3B3A2B3A3B3B2B3A2A2A2B3B3A2A3B3B3B3B2B3A3B3B3B2B3A3B3B2A3B3B2B 55
Solved by putting the buckets to the ~/.yfmosrc
profile manually and managed to get it working.
I'll update the buckets file with what i captured.
Hi, thanks for this tool, Unfortunately when i run
python yfmos.py init --debug --device 0xaabbcc --rollingcode 0 --profile somfy_obie AA B1 05 09EC 12DE 04EC 0280 6B26 48080808080808092A2A3B2A3B2A3B3B3B3B3B3B2A3B3B3B2A3B2A3B2B3A3B2B3B3A2A2B3A3B2B3A3B3B3B3B3B3B2A3B3B2A 55
I get
ListofElem: ['AA', 'B1', '05', '09EC', '12DE', '04EC', '0280', '6B26', '48080808080808092A2A3B2A3B2A3B3B3B3B3B3B2A3B3B3B2A3B2A3B2B3A3B2B3B3A2A2B3A3B2B3A3B3B3B3B3B3B2A3B3B2A', '55'] NumBuckets: 5 Bucket 0: HWsync (2540) Bucket 1: SWsync (4830) Bucket 2: Long (1260) Bucket 3: Short (640) Bucket 4: InterFrameGap (27430) Data: 4 8 0 8 0 8 0 8 0 8 0 8 0 8 0 9 2 A 2 A 3 B 2 A 3 B 2 A 3 B 3 B 3 B 3 B 3 B 3 B 2 A 3 B 3 B 3 B 2 A 3 B 2 A 3 B 2 B 3 A 3 B 2 B 3 B 3 A 2 A 2 B 3 A 3 B 2 B 3 A 3 B 3 B 3 B 3 B 3 B 3 B 2 A 3 B 3 B 2 A InterFrameGap 0: States.ST_UNKNOWN Traceback (most recent call last): File "yfmos.py", line 435, in <module> Yfmos() File "yfmos.py", line 134, in __init__ getattr(self, args.command)() File "yfmos.py", line 159, in init parsedConfig = self.__parge_B1(args.b1string) File "yfmos.py", line 265, in __parge_B1 print(pulse[int(listOfElem[i])]) KeyError: 8
Any ideas what's going on ? I will try to fix this but I hardly know python so that may be tricky.