Git Product home page Git Product logo

Comments (13)

dsgrafiniert avatar dsgrafiniert commented on September 23, 2024 1

"main_brush": false,
"spot_area": true,
"custom_area": false,
"mopping_system": true,
"voice_report": false,
"single_room": false,
"auto_empty_station": false

from ecovacs-deebot.js.

mrbungle64 avatar mrbungle64 commented on September 23, 2024

@dsgrafiniert

Describe the solution you'd like
It would be great, if the cleaning status of the OZMO Slim 10 would be parsed in the script.

What script do you mean?

from ecovacs-deebot.js.

mrbungle64 avatar mrbungle64 commented on September 23, 2024

@dsgrafiniert

You are using the example script app.js, right?
This example script is deprecated and should not be used anymore

Line 8-9:

// This example app is deprecated
// Please don't use it anymore :)

app2.js is the latest example script.

btw: the cleaning status is already output 😉

[VacBot] *** cleanStatus = stop

from ecovacs-deebot.js.

mrbungle64 avatar mrbungle64 commented on September 23, 2024

@dsgrafiniert

The developer of the homebridge-deebotEcovacs plugin owns an OZMO Slim 10.
His plugin is using this library, so as far as I know the OZMO Slim 10 is working properly with this library.

from ecovacs-deebot.js.

mrbungle64 avatar mrbungle64 commented on September 23, 2024

@dsgrafiniert

Have you already tried if it works with example script app2.js?

from ecovacs-deebot.js.

dsgrafiniert avatar dsgrafiniert commented on September 23, 2024

Sorry for the late response. I did not rely on the deprecated app.js but created my own small debugging script.

However, the MQTT messages "CleanSt" and "GoChargeBgdata" are not getting parsed correctly.

from ecovacs-deebot.js.

mrbungle64 avatar mrbungle64 commented on September 23, 2024

@dsgrafiniert

Sorry for the late response. I did not rely on the deprecated app.js but created my own small debugging script.

Please post the debugging script so I can see if these messages really need to be parsed.

from ecovacs-deebot.js.

dsgrafiniert avatar dsgrafiniert commented on September 23, 2024
const ecovacsDeebot = require('ecovacs-deebot'), 
    EcoVacsAPI = ecovacsDeebot.EcoVacsAPI, 
    VacBot = ecovacsDeebot.VacBot;
    
    ...
    
let api = new EcoVacsAPI(deviceid, countrycode, continent);

api.connect(username, md5_pw).then(() => {
	console.log("Connected!");
    
    api.devices().then((devices) => {
    	console.log("Devices:", JSON.stringify(devices));
    	let vacuum = devices[0]; // Selects the first vacuum from your account
    	let vacbot = api.getVacBot(api.uid, EcoVacsAPI.REALM, api.resource, api.user_access_token, vacuum, continent);
    	vacbot.on("ready", (event) => {
    		console.log("Vacbot ready");            
    	});
        vacbot.on("BatteryInfo", (battery) => {
        	console.log("Battery level: %d\%", Math.round(battery));
        });

        console.log('[app2.js] name: ' + vacbot.getDeviceProperty('name'));
        console.log('[app2.js] isKnownDevice: ' + vacbot.isKnownDevice());
        console.log('[app2.js] isSupportedDevice: ' + vacbot.isSupportedDevice());
        console.log('[app2.js] is950type: ' + vacbot.is950type());
        console.log('[app2.js] isNot950type: ' + vacbot.isNot950type());
        console.log('[app2.js] hasMainBrush: ' + vacbot.hasMainBrush());
        console.log('[app2.js] hasEdgeCleaningMode: ' + vacbot.hasEdgeCleaningMode());
        console.log('[app2.js] hasSpotCleaningMode: ' + vacbot.hasSpotCleaningMode());
        console.log('[app2.js] hasSpotAreaCleaningMode: ' + vacbot.hasSpotAreaCleaningMode());
        console.log('[app2.js] hasCustomAreaCleaningMode: ' + vacbot.hasCustomAreaCleaningMode());
        console.log('[app2.js] hasMoppingSystem: ' + vacbot.hasMoppingSystem());
        console.log('[app2.js] hasVoiceReports: ' + vacbot.hasVoiceReports());
});

    
}).catch((e) => {
	// The Ecovacs API endpoint is not very stable, so
	// connecting fails randomly from time to time
	console.error("Failure in connecting!");
});


Following output of the features listing:

[app2.js] name: false
[app2.js] isKnownDevice: false
[app2.js] isSupportedDevice: false
[app2.js] is950type: false
[app2.js] isNot950type: true
[app2.js] hasMainBrush: false
[app2.js] hasEdgeCleaningMode: true
[app2.js] hasSpotCleaningMode: true
[app2.js] hasSpotAreaCleaningMode: false
[app2.js] hasCustomAreaCleaningMode: false
[app2.js] hasMoppingSystem: false
[app2.js] hasVoiceReports: false

from ecovacs-deebot.js.

mrbungle64 avatar mrbungle64 commented on September 23, 2024

@dsgrafiniert

You have to add the following event to get cleaning status:

vacbot.on("CleanReport", (value) => {
      console.log("CleanReport: " + value);
});

and you may need to run the following command:

setTimeout(() => {
      vacbot.run("GetCleanState");
}, 6000);

In the script app2.js you can see even more examples of events and commands.

from ecovacs-deebot.js.

mrbungle64 avatar mrbungle64 commented on September 23, 2024

@dsgrafiniert

[app2.js] hasMainBrush: false
[app2.js] hasEdgeCleaningMode: true
[app2.js] hasSpotCleaningMode: true
[app2.js] hasSpotAreaCleaningMode: false
[app2.js] hasCustomAreaCleaningMode: false
[app2.js] hasMoppingSystem: false
[app2.js] hasVoiceReports: false

There has been no config for the model yet ...

Is this information correct?

"main_brush": true,
"spot_area": false,
"custom_area": false,
"mopping_system": true,
"voice_report": true,
"single_room": false,
"auto_empty_station": false

from ecovacs-deebot.js.

mrbungle64 avatar mrbungle64 commented on September 23, 2024

"main_brush": false,
"spot_area": true,
"custom_area": false,
"mopping_system": true,
"voice_report": false,
"single_room": false,
"auto_empty_station": false

"Add config for OZMO Slim 10 Series":
086b37b

from ecovacs-deebot.js.

mrbungle64 avatar mrbungle64 commented on September 23, 2024

@dsgrafiniert

You have to add the following event to get cleaning status:

vacbot.on("CleanReport", (value) => {
      console.log("CleanReport: " + value);
});

and you may need to run the following command:

setTimeout(() => {
      vacbot.run("GetCleanState");
}, 6000);

In the script app2.js you can see even more examples of events and commands.

@dsgrafiniert
Have you already tried if it works?

from ecovacs-deebot.js.

dsgrafiniert avatar dsgrafiniert commented on September 23, 2024

@dsgrafiniert
You have to add the following event to get cleaning status:

vacbot.on("CleanReport", (value) => {
      console.log("CleanReport: " + value);
});

and you may need to run the following command:

setTimeout(() => {
      vacbot.run("GetCleanState");
}, 6000);

In the script app2.js you can see even more examples of events and commands.

@dsgrafiniert
Have you already tried if it works?

Yes, it basically works.

However, it would be great if the MQTT messages <ctl td="CleanSt" a="000" s="2" l="0100" t="a"/> would trigger events as well.
I am able to interpret the parameters at least partly:
l="0100" is the time since starting the cleaning job in seconds
a="000" is the cleaned space of the current job in square meters

from ecovacs-deebot.js.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.