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

binary_sensor.<car>_asleep #360

Closed
carleeno opened this issue Nov 19, 2022 · 3 comments
Closed

binary_sensor.<car>_asleep #360

carleeno opened this issue Nov 19, 2022 · 3 comments
Labels
enhancement New feature or request

Comments

@carleeno
Copy link
Contributor

Is your feature request related to a problem? Please describe.
I'm unable to determine if car is disconnected (poor signal, service outage) vs asleep

Describe the solution you'd like
A binary sensor to indicate if the car is asleep

Describe alternatives you've considered

  • An attribute to the online sensor that shows state: asleep (this is what v2.* of the tesla integration had). The attribute worked, but having a dedicated binary sensor is much more useful given how often/common it is for the car to be asleep vs offline.
  • Change the online binary_sensor to a regular sensor and publish the different states. this would be too disruptive to change an existing sensor.

Additional context
I'm happy to make a PR (here and in teslajsonpy) to add the asleep binary sensor, but I wanted to started a conversation first to see if we feel that's the best approach.

@alandtse
Copy link
Owner

@shred86 any thoughts since you were the one to change it?

I'm ok with an added attribute although the HA philosophy was to move away from attributes and move to straight sensors. I believe the philosophy is that anything someone may want to access directly or have history of, should be it's own sensor.

Breaking changes are highly disruptive so the preference is to avoid them unless there's a strong justification. That would mean we should lean to keeping existing sensors functional and adding others. Of course, that may mean we end up with tons of sensors so that's another countervailing issue to consider.

@alandtse alandtse added the enhancement New feature or request label Nov 19, 2022
@carleeno
Copy link
Contributor Author

thanks @alandtse that's what I was feeling as well, which is why my main solution/suggestion was to add a new sensor for it. Apologies if I didn't format the request well.

@alandtse
Copy link
Owner

Oh sorry. Most people aren't using the template so I forgot that the alternatives section existed and I just answered without thinking. Yes, I'm fine with a binary sensor PR.

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

No branches or pull requests

2 participants