-
Notifications
You must be signed in to change notification settings - Fork 9
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
[suggestion] cleaning mode #4
Comments
battery status would also be nice |
Yeah, I've been thinking how to approach the cleaning modes, especially the power, and thought that the solution using a fan accessory for both mop and non-mopping modes is not a very fortunate one. A separate switch for mopping mode, and a fan accessory for non-mopping modes rescaled to 0-100 should do at least. But we would have to be able to detect whether the vacuum the plugin is controlling is a mopping-capable robot. OR, maybe besides the normal/mop mode switch, provide a config setting for any two modes the user prefers, so they'd get a switch for Quiet/Max, or Balanced/Turbo, etc. Currently I'm using only one mode anyway, as when I'm not at home I don't care how quickly the vacuum will do its job. The battery status is there in every accessory already - whether it's charging, battery level and low level state. Or maybe you're thinking of a "status accessory" for something battery-related? |
i was thinking of a mixture... |
Which sensor for battery level would you have in mind? Nothing existing really fits, and I don't know whether a custom accessory would show up as a sensor showing a numeric value, for example. The ones that do are I think light level (in lux), temperature (celsius or fahrenheit), and humidity (percentage). That's it, I think. The rest are devices you can control, like doors, window coverings, fans, bulbs. |
I think of the humidity sensor as it’s percentage and fits the battery level reported by Valetudo. |
By the way, have you tried to send a pull request for Valetudo with the speed modes? They use their own values in the client for the different speeds, but their own fake backend actually does define the presets available in the official robot's interface (i.e. Quiet, Balanced, Turbo, Max, Mop). I implemented those, but when they are set, the default Valetudo interface shows |
pushed ;) |
In case you didn't notice, 0.1.2 is live with cleaning modes. I'm still contemplating the humidity sensor as battery indicator idea. Is it really useful to see the battery level in the Home app directly? Would you do anything about it if it crossed a specific threshold? Do you want to set up automations with it (e.g. red lights turn on in the living room if the battery is low ;) )? Not saying it's a terrible idea and would never implement it. It's just that it is an additional code I have to maintain afterwards, for a functionality I'm not completely sold on. It's not a lot of code, honestly, but still. I'm much more eager to implement buttons for cleaning saved zones or spots, or adding MQTT support so the plugin receives vacuum's status by listening to notifications, rather than having to poll every few seconds. My simple HTTP notifier PR for Valetudo got rejected, so I'm about to set up a standalone MQTT broker at home to test this ecosystem. I've never been a huge fan of MQTT, but I guess it has its uses, for a slight cost of additional infrastructure. |
Guess you can drop the humidity/battery sensor. In terms of automation you could set up some form of notification and action(e.g. on battery < 30% notify the user and regardless of the task go to the dock). Still this sound more like a useless feature even as I type it. Scrap it. |
The vacuum does stop and go back to base when low on juice - there are even suitable error messages for that. I would know because I recently sent a PR to dustcloud with updated Polish translations. ;) I'm all for simpler solutions and the HTTP notifications I proposed in the PR would solve some of my issues, but MQTT prevails as THE IoT protocol, apparently. No worries, though - this plugin will be both HTTP- and MQTT-capable. Once MQTT is configured, I'd like to offer the same exact features, but use a different means of communication. Here's an idea - maybe I could implement some kind of a status forwarder in the plugin, that, once configured, would post human-readable messages to a predefined URL, to enable push notifications, for example. We could define which status changes should be forwarded, too - I know it spams a lot of these status updates when working, because it does that even for area covered or battery level changes. Seems like a bit beyond what a Homebridge plugin should do, but then again, one wouldn't have to set up any other ways of getting such notifications. |
I did something different - scripting based telegram notifications. I have now updated to the latest version - for me it’s mostly ok so I would leave it like this. As of now i am contemplating in baking telegram notification support directly in Valetudo so the vacuum would be self sufficient... |
Just a question as i have not looked into homebridge (yet). Are there any switch types which support more than 2 states? I am thinking of a multi-level switch - simple press toggles between on/off while long press allows for setting the desired level (e.g. low, medium, high). It would combine the power modes of the vacuum and the ability to turn that particular mode on or off. |
There is a programmable switch, for example, but its purpose is to have an "intelligent" HomeKit-compatible physical button that can be programmed to perform different actions on a click, double-click and a long-press, so you can't really use it like that in HomeKit, just program the actions performed. There are other sort of multi-level switches, but very specific ones, like the one for alarm systems - this one has Stay, Away, Night, Disarm, Triggered, so this doesn't make any sense for our purpose. :( |
Did you start using MQTT? I would also love to have controls of zones in HomeKit, I just haven't been able to program it myself :( |
I have had zero time available recently, but I've been thinking about the zone cleanups, and it's doable provided that the plugin can indeed associate current action with cleaning the chosen zone when checking for vacuum's status. As for MQTT, I'd love to implement it for sure. |
one thing to add is a way to control the cleaning mode: vacuum/mop and the power level associated with it. My first idea would be to add a fan mode which can be controlled but this is tricky as the user needs to remember which percent of the fan corresponds to which cleaning mode. Another idea would be to have switches for cleaning and mopping. Still you somehow need to control the power levels for vacuuming...
Mopping is tricky as it is missing from valetudo. It's an additional mode during which the vacuum moves slower.
I modified valetudo as follows:
var fanspeeds = { 38: "Quiet", 60: "Balanced", 75: "Turbo", 100: "Max", 105: "Mop" };
`function handleFanspeedButton() {
window.clearTimeout(currentRefreshTimer);
The text was updated successfully, but these errors were encountered: