-
Notifications
You must be signed in to change notification settings - Fork 2
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
Enhanced support for Petkit devices #4
Comments
on the other hand thoses feeders had an another specificity : some feeders have 2 hoppers, in fact we have : "amount1" and "amount2" for the |
Hey, Thank you! I'm very glad the card is useful! Yes, I can definitely add support for both features, however if you agree, I would like a bit of discussion first to decide on the best approach from the technical and UX perspectives, so I have a few questions: (warning: wall of text, sorry! 😄 ) General questions
I would also need to think about how & where to place this new information. The space is already a bit limited, and I don't want to have too much information Enable / Disable feeding entry
Does this mean that If If Dual/Multi source scheduleIf I understood correctly, the device can simultaneously dispense from both hoppers for one entry; so I see no problem in the add/edit screen as we have the space for more inputs, and no problem for the actions as we are not limited in the data. But for the state sensor it gets complicated with the device-specific states... First IdeasContinue with encoded text sensorWe could continue using a single sensor as an array of numbers, Pros:
Cons:
Pro/Con:
I can at least make the 'parseStateString' regex and number-state map type: custom:dispenser-schedule-card
device_type: 'petkit-yumshare-dual-hopper' or custom type: custom:dispenser-schedule-card
custom_device:
state_string_regex: /(?<hour>[0-9]{2}),(?<minute>[0-9]{2}),(?<status>[0-9]{3})/
status_map:
- "255 -> Pending"
- "100 -> SurplusControl"
- etc Full state in action responseWe could implement this the same way as We could have a simple sensor that has the count and the {
"device": {
"disable-individual-entry": true,
"disable-entire-plan": false,
"hopper-count": 2,
"weight-scale": true,
"max-entries": 20,
"weekly-plan": false
},
"schedule": [
{
"disabled": false,
"time": "10:20",
"amount": [10, 5],
"dispensed": [10.2, 5.5],
"status": "Distribuée",
"icon": "mdi:check"
// or one of the predefined card statuses
// to include status colors:
// "display-state": "success"
},
{
"disabled": true,
"time": "10:20",
"amount": [10, 5],
"status": "SurplusControl™",
"icon": "mdi:clock-remove-outline"
// or one of the predefined card statuses
// to include status colors:
// "display-state": "disabled"
}
]
} Pros:
Cons:
Pro/Con:
State in attributesSame as the action response approach, but using text sensor attributes. Pros:
Pro/Con:
Again, sorry for the many words, but I'm curious to hear your thoughts. Thanks! |
I don't think so, in my case i have 10 feed entry by day. But i already reached the limit with 255 chars in HA.
Native petkit feeding plan returned from API : This for the feeding plan : And this for the "result" :
By writing this information I realize that integrating the specificities of this distributor will be complicated...
Yes
No there is 2 entry, one for each hopper
I think this could be kept like that, there is too much information
Look to be the better solution Tell me what you think of this information? and I suggest that we continue on Discord, it will be simpler for our exchanges :-) |
Hi Cristian,
First of all, thank you for this beautiful card.
I've wanted something like this for our feeders for a long time. You did it !
I had a request regarding my Petkit integration, many users asked me for schedule management support.
However, there are specificities to our Petkit distributors that are not found in others.
We have a "To be dispensed" option to activate or deactivate certain portions and this only affects the current day (this does not modify the general feeding plan)
Do you think that in addition to the add, remove, edit actions, we could add something like: enable, disable?
The text was updated successfully, but these errors were encountered: