sui77 / rc-switch

Arduino lib to operate 433/315Mhz devices like power outlet sockets.
1.91k stars 659 forks source link

Fix and support for Conrad_RS-200 protocol #313

Closed to-scho closed 4 years ago

to-scho commented 4 years ago

There is a tiny bug hat prevents the usage for "Conrad RS-200" based devices. The RS-200 protocol does not repeat packets that often. One need already to detect the end of the first packet. The gap between two transmission are not handled right when RF packet is received first time.

a) 1st gap detection fixed b) Furthermore the "Conrad RS-200" protocol is added.

1technophile commented 4 years ago

Thanks for this PR, did you add the chance to test your modification with other protocols to see if in the real there is no side effects?

to-scho commented 4 years ago

Yes, but I have just one other at hand. It also works well with my PIR sensor from SonOff. I found that first packed gap is not recognized using a scope. When there is no reason that first gap / two packets are not enough it looked just like tiny bug of the first iteration to me.

1technophile commented 4 years ago

I will do some tests on my side. Would it be possible to share the results of simpleRcscanner if available, and the expected decoding. The goal is to include them into future unit testing.

to-scho commented 4 years ago

Sorry, I haven't used simpleRcscanner

1technophile commented 4 years ago

And would it be possible to capture at least 4 or 5 recordings for future use and in the mean time the corresponding results with your modified code?

to-scho commented 4 years ago

ouch, my experiments with that are half a year ago. I know, very late PR...

I need to reflash my working device. This may take a while.

1technophile commented 4 years ago

No problem, we will not setup unit testing fast, the goal is just to have some date in input /results to avoid regressions.

to-scho commented 4 years ago

One thing came into my mind. I started experiments using rc-switch because of this two issues reported here:

(Conrad) RS-200 switch is too noisy? #228 Conrad RS-200 Sockets / Europe Supplies Ltd. RS-200 #231

The latter one decoded the rc-200 protocol completely. My issue and PR is about receiving it.

In that posts there are some traces. Is that sufficient for you?

1technophile commented 4 years ago

Thanks I will check

1technophile commented 4 years ago

Tests are ok for me