natekspencer / hacs-litterrobot

Home Assistant integration for a Litter-Robot Connect self-cleaning litter box
MIT License
8 stars 1 forks source link

[Feature Request] Status information #8

Closed ShagoY closed 3 years ago

ShagoY commented 3 years ago

hello :)

First of all thank you for your work!

I have a small question, why don't you use the "status" information in the widget "vacuum.lilas_litter_box"?

I find that there is much more information there, for example it indicates when the cat is doing things (Cat Sensor Timing).

image

So I created a sensor but I admit that I would like it to be displayed directly... Instead of "On the base" in my screenshot.

# Litter Robot
- platform: template
  sensors:
    lilas_status:
      friendly_name_template: "{{ state_attr('vacuum.lilas_litter_box','friendly_name') }} Status"
      value_template: "{{ state_attr('vacuum.lilas_litter_box','status') }}"

What do you think about it ?

natekspencer commented 3 years ago

I don't disagree with you. The status definitely shows more information. That being said, there are a couple of reasons why I didn't do this:

  1. HA only officially supports a certain set of "vacuum" states: https://developers.home-assistant.io/docs/core/entity/vacuum/#states
    • Using unsupported states, while possible, risks potentially having this component break or be blocked by HA should the inherited VacuumEntity code be changed/restricted.
  2. The default entity display for a vacuum is sorely lacking. I wish there was a vacuum card, similar to how a thermostat card is available.
    • I actually use a custom lovelace card for my LR unit, which includes the ability to show the status: https://github.com/denysdovhan/vacuum-card
    • This is an example of my configuration for it:
      
      type: 'custom:vacuum-card'
      entity: vacuum.shit_be_gone_litter_box
      image: 'https://brands.home-assistant.io/litterrobot/icon@2x.png'
      compact_view: false
      show_name: true
      show_status: true
      show_toolbar: true
      stats:
      default:
    • entity_id: switch.shit_be_gone_sleep_mode subtitle: Sleep Mode
    • attribute: clean_cycle_wait_time_minutes unit: minutes subtitle: Clean Cycle Wait Time
    • attribute: power_status subtitle: Power Status actions:
    • name: Reset Waste Drawer service: vacuum.send_command icon: 'mdi:delete-variant' service_data: entity_id: vacuum.shit_be_gone_litter_box command: reset_waste_drawer
      
      ![image](https://user-images.githubusercontent.com/3792831/109397929-ade9ca00-78f6-11eb-871a-18bdbfaecb80.png)
ShagoY commented 3 years ago

Ok I thought there was something behind your choice :)

Having said that, maybe directly integrate the sensor status to your project as a complement ? Cause I noticed that when our LR unit was full this was not clearly indicated in your Entities "out of the box". Sorry I deleted my db lately, I don't have any example to give you.

Anyway, I just installed your custom lovelace card ! It's really nice :) Too bad we don't have the % of the garbage drawer anymore. But I guess that our product was not originally planned ^^.

natekspencer commented 3 years ago

I'm actually working on the official integration for this component. One of the fields I'm contemplating (and building via the pypi package) is a "waste drawer full" indicator to handle that very scenario.

On your other note: The waste drawer gauge is still there. You can modify the stats that display on that custom card and add it or you can just show it as the separate entity that it is.