-
-
Notifications
You must be signed in to change notification settings - Fork 32.2k
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 Ubiquiti mFi sensors and switches #1151
Conversation
This is an automated response to help you succeed in getting this PR merged.
If your code communicates with devices:
If your code does not depend on external devices:
|
port = int(config.get('port', 6443)) | ||
username = config.get(CONF_USERNAME) | ||
password = config.get(CONF_PASSWORD) | ||
|
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.
Can you please check if the mandatory configuration parts are provided? If not, the setup should fail with a log entry.
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.
Yeah, forgot to do this, will fix it up.
value = self._port.value | ||
if self._port.tag == 'temperature': | ||
temp_unit = self._hass.config.temperature_unit | ||
if temp_unit.endswith('F'): |
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.
There is no need for this. Home Assistant will automatically convert temperature values to the user preferred temperature unit.
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.
Ah, nifty, thanks.
This adds support for sensors based on Ubiquiti's mFi platform. All ports/sensors are detected from the mFi controller and exposed.
This adds support for mFi devices that are swichable, such as the mFi Outlet device.
Add support for Ubiquiti mFi sensors and switches
No description provided.