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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow rfxtrx network usage #25378
Allow rfxtrx network usage #25378
Conversation
Hi @barrystaes, It seems you haven't yet signed a CLA. Please do so here. Once you do that we will be able to review and accept this pull request. Thanks! |
Hey there @Danielhiversen, mind taking a look at this pull request as its been labeled with a integration ( This is a automatic comment generated by codeowners-mention to help ensure issues and pull requests are seen by the right people. |
Hi @barrystaes, It seems you haven't yet signed a CLA. Please do so here. Once you do that we will be able to review and accept this pull request. Thanks! |
Code is UNTESTED. Also beware i'm new to Python, feedback is very welcome. Questions for owner:
|
Just add new fields instead "host"/"port" |
Ok wil do. I was not sure how to make either |
You can use voluptuous Inclusive/Exclusive |
Ok implemented a I am now going to look into how to properly test this locally, update documentation, etc. |
vol.Exclusive(CONF_DEVICE, CONNECTION_GROUP): cv.string, | ||
vol.Exclusive(CONF_HOST, CONNECTION_GROUP): cv.string, | ||
vol.Exclusive(CONF_DUMMY, CONNECTION_GROUP): cv.boolean, | ||
vol.Optional(CONF_PORT, default=DEFAULT_PORT): cv.positive_int, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
port and host should be in a Inclusive group. That mean both are required. There is no point in a default port since this is all custom fetures anyway.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried but failed. Do you have an example of such a inclusive group within a exclusive group?
Or is the yaml below fine? This is easy to implement using two Required wrapped into one Exclusive.
rfxtrx:
network:
host: 1.2.3.4
port: 5678
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@elupus do you have an example of such a inclusive group within a exclusive group? Could not find a component/platform that does this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remember to upgrade to pyRFXtrx 0.24.0
Update: PR is not abandoned, i'll find time within a few weeks at most. |
@barrystaes if you're not going to work on this PR for a while, please close it. Then you can reopen the PR yourself and we'll keep thread history. We're trying to decrease our open PR buffer. Thanks! |
This PR is now running stale for 3 months, therefore I'm closing it for now. Feel free to re-open when ready. |
WIP asking for feedback 馃挕
Description:
I wanted to use rfxcom device via network. Started with this HA forum thread, then a PR to pyRFXtrx, and now this (concept) PR to Home Assistant.
Pull request with documentation for home-assistant.io: todo on checklist
Example entry for
configuration.yaml
:So changed:
device: /dev/ttyUSB0
was supported, the above is an alternative.Checklist:
tox
. Your PR cannot be merged unless tests passIf user exposed functionality or configuration variables are added/changed:
If the code communicates with devices, web services, or third-party tools:
python3 -m script.hassfest
.requirements_all.txt
by runningpython3 -m script.gen_requirements_all
..coveragerc
.If the code does not interact with devices: