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

Added MQTT Publish ability #7

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

dWoolridge
Copy link

@dWoolridge dWoolridge commented Oct 21, 2022

Hello,

I found your version of rfxcmd and thought it was the best option to add MQTT publish capabilities. I've got it working and thought I'd make it available to you through a pull request. It's completely up to you if you want to incorporate this or not.

It should work for most of the weather sensors (0x50 - 0x57). I've tested it with sensors of type 0x50 & 0x52 on a Raspberry Pi (Raspbian GNU/Linux 11 (bullseye)) with an RFXcom RFXrec433.

Changes made:

  • Added MQTT config section to config.xml.sample
  • rfxcmd.py: added MQTT config reads, new function "sendMQTT" called from the decode_packet function
  • Changed the code in rfxcmd.py to use the outputfile in the config instead of defaulting to /var/log/output.log. I got permission errors when it defaulted to that file.

Thanks,
dwoolridge

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.

1 participant