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

Support for Bresser 7-in-1 weather stations #40

Merged
merged 28 commits into from
Mar 3, 2023

Conversation

jorgenavarroortiz
Copy link
Contributor

Hi,

I have included the decoder for the Bresser 7-in-1 into this library (based on https://github.com/merbanan/rtl_433/blob/master/src/devices/bresser_7in1.c). You can check my forked repo at https://github.com/jorgenavarroortiz/BresserWeatherSensorReceiver.

After the pull request I will update the description at the beginning with two examples of weather stations using this decoder.

I hope you will find it useful and included in the upstream repository. Thanks.

Best regards,
Jorge

@jorgenavarroortiz
Copy link
Contributor Author

By the way, I have also included the pinout for the Heltec Wireless Stick (https://heltec.org/project/wireless-stick/), which is the device I have been using.

@matthias-bs matthias-bs added the enhancement New feature or request label Mar 3, 2023
@matthias-bs matthias-bs self-assigned this Mar 3, 2023
@matthias-bs
Copy link
Owner

Dear Jorge,

Thank you very much for your contribution!

There are still two compiler warnings which I would like to have fixed before merging this pull request:

/home/runner/work/BresserWeatherSensorReceiver/BresserWeatherSensorReceiver/src/WeatherSensor.cpp: In member function 'DecodeStatus WeatherSensor::decodeBresser6In1Payload(uint8_t*, uint8_t)':
/home/runner/work/BresserWeatherSensorReceiver/BresserWeatherSensorReceiver/src/WeatherSensor.cpp:649:10: error: unused variable 'light_ok' [-Werror=unused-variable]
     bool light_ok    = false;
          ^~~~~~~~
/home/runner/work/BresserWeatherSensorReceiver/BresserWeatherSensorReceiver/src/WeatherSensor.cpp: In member function 'DecodeStatus WeatherSensor::decodeBresser7In1Payload(uint8_t*, uint8_t)':
/home/runner/work/BresserWeatherSensorReceiver/BresserWeatherSensorReceiver/src/WeatherSensor.cpp:811:15: error: unused variable 'tmp' [-Werror=unused-variable]
       uint8_t tmp = msg[i];
               ^~~
cc1plus: some warnings being treated as errors

May I ask you to fix this? I can imagine that was already in the original rtl_433 code.

Best regards
Matthias

@matthias-bs matthias-bs self-requested a review March 3, 2023 11:30
@jorgenavarroortiz
Copy link
Contributor Author

jorgenavarroortiz commented Mar 3, 2023

Dear Jorge,

Thank you very much for your contribution!

There are still two compiler warnings which I would like to have fixed before merging this pull request:

/home/runner/work/BresserWeatherSensorReceiver/BresserWeatherSensorReceiver/src/WeatherSensor.cpp: In member function 'DecodeStatus WeatherSensor::decodeBresser6In1Payload(uint8_t*, uint8_t)':
/home/runner/work/BresserWeatherSensorReceiver/BresserWeatherSensorReceiver/src/WeatherSensor.cpp:649:10: error: unused variable 'light_ok' [-Werror=unused-variable]
     bool light_ok    = false;
          ^~~~~~~~
/home/runner/work/BresserWeatherSensorReceiver/BresserWeatherSensorReceiver/src/WeatherSensor.cpp: In member function 'DecodeStatus WeatherSensor::decodeBresser7In1Payload(uint8_t*, uint8_t)':
/home/runner/work/BresserWeatherSensorReceiver/BresserWeatherSensorReceiver/src/WeatherSensor.cpp:811:15: error: unused variable 'tmp' [-Werror=unused-variable]
       uint8_t tmp = msg[i];
               ^~~
cc1plus: some warnings being treated as errors

May I ask you to fix this? I can imagine that was already in the original rtl_433 code.

Best regards Matthias

I think I have corrected them in the fork repo (it was just to remove those lines). I hope that this is already updated in the pull request, but I have little experience with github and pull requests. Can you check that everything is ok? If not, please just remove those lines. Thanks.

@coveralls
Copy link

Pull Request Test Coverage Report for Build 4327328010

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 99.997%

Totals Coverage Status
Change from base Build 4322838457: 0.0%
Covered Lines: 30090
Relevant Lines: 30091

💛 - Coveralls

@matthias-bs matthias-bs merged commit 90b8e33 into matthias-bs:main Mar 3, 2023
@matthias-bs
Copy link
Owner

Thank you very much for the modifications! I have included your pull request in 90b8e33 and made a few minor changes afterwards. The most important modification was to change the define set by the Arduino IDE for the "Heltec Wireless Stick" to ARDUINO_heltec_wireless_stick. This board has also been added to the CI workflow.

I will provide an updated release within the next couple of days.

Many thanks for this great addition!

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

Successfully merging this pull request may close these issues.

None yet

3 participants