Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Regency ceiling fans #1948

Merged
merged 9 commits into from
Jan 21, 2022
Merged

Add support for Regency ceiling fans #1948

merged 9 commits into from
Jan 21, 2022

Conversation

dtiller
Copy link
Contributor

@dtiller dtiller commented Jan 20, 2022

This decoder handles Regency brand ceiling fan commands. I will upload test data soon.

@dtiller
Copy link
Contributor Author

dtiller commented Jan 21, 2022 via email

@zuckschwerdt
Copy link
Collaborator

32 bits which this variable requires

you lost me, I see a single byte? (and then %d is wrong for uint32_t)

@merbanan
Copy link
Owner

uint8_t bytes[NUM_BYTES];
uint32_t value = bytes[VALUE_BYTE];

sprintf(value_string, "speed %d", value);

So we have u8->u32 and then %d in the sprintf. When reading about printf %d needs int. And int will hold u8 so I don't understand what you are referring to. In practice this means nothing but I aim to keep things as simple as possible if possilbe.

@dtiller
Copy link
Contributor Author

dtiller commented Jan 21, 2022 via email

@zuckschwerdt
Copy link
Collaborator

bottom line: we have a lot of code to manage, we need it simple, plain and uniform; all decoders should roughly look the same, the odd ones are not great and need to get fewer. And the PR is likely the only chance to get help by the author.

Thanks for sticking with this and working through all the requests. Looks good to merge.

@merbanan
Copy link
Owner

LGTM

@zuckschwerdt zuckschwerdt merged commit e66eec4 into merbanan:master Jan 21, 2022
@sheilbronn
Copy link

Hi there,
I seem to have a regency remote control in my suburban environment and I noticed some invalid percentages (192%, 195%) being emitted. Are these valid values or should the corresponding signal be suppressed before output?

26 06:25:38 {"protocol":211,"model":"Regency-Remote","channel":15,"command":"light_intensity","value":"192 %","mod":"ASK","freq":433.85,"rssi":-9.729,"snr":6.362,"noise":-16.091}
20 17:18:52 {"protocol":211,"model":"Regency-Remote","channel":15,"command":"light_intensity","value":"0 %","mod":"ASK","freq":433.883,"rssi":-2.178,"snr":4.2,"noise":-6.377}
18 19:44:25 {"protocol":211,"model":"Regency-Remote","channel":11,"command":"light_intensity","value":"0 %","mod":"ASK","freq":433.854,"rssi":-1.383,"snr":12.218,"noise":-13.601}
21 19:49:24 {"protocol":211,"model":"Regency-Remote","channel":1,"command":"light_intensity","value":"195 %","mod":"ASK","freq":433.927,"rssi":-6.751,"snr":12.841,"noise":-19.591}
23 20:57:12 {"protocol":211,"model":"Regency-Remote","channel":7,"command":"light_intensity","value":"64 %","mod":"ASK","freq":433.898,"rssi":-4.097,"snr":4.336,"noise":-8.434}

There are also fan_speed command on the same channel but I don't know whether this makes sense at all...
I attached the Regency readings that got picked in my logs recently as a file attachment: regency.log

Let me know if I can help with more data, but I don't know the owner of the device....
Shall I open a separate issue?

@dtiller
Copy link
Contributor Author

dtiller commented Apr 26, 2022 via email

@sheilbronn
Copy link

sheilbronn commented Apr 26, 2022

If you want to capture more data I can see if I can tighten the code to more accurately detect a regency remote.

@dtiller : I'm happy to give it a try. These signals are quite rare, though.

Use the -S option with either 'known' or 'all'.

I restarted rtl_433 with -S known.
Now my log dir is filling up with files named like "g0XX_433.9M_1024k.cu8".
Am I supposed to watch out for the Regency remote signal in my rtl_433 log file and then find out the corresponding cu8 file that caused the signal ?!

@dtiller
Copy link
Contributor Author

dtiller commented Apr 26, 2022 via email

@sheilbronn
Copy link

Ouch! You might want to enable only the regency decoder and select known. I think that would be rtl_433 -R 211 -S known etc

That's fine. I'm decoding every protocol/signal in my neighbourhood relaying the results to my home automation OpenHAB. I build a wrapper around rtl_433 supporting MQTT Auto Discovery for different types of devices - ugly stuff ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants