Voor vragen over Virtual Devices.
Door KevinKusters
#881
Hallo,

In mijn nieuwe woning wil een robotstofzuiger gaan gebruiken, ik lees dat de Roomba van iRobot dit kan icm Fibaro (als virtual device). Hiervoor is wel een RooWifi chip nodig, deze is end of life want is nergens meer te verkrijgen.

Nu hebben veel Roomba’s tegenwoordig al wifi ingebouwd, is het mogelijk om de Roomba te koppelen met Fibaro met de ingebouwde wifichip? Of had de Roowifi nog iets extra’s aanboord waardoor het mogelijk was?

Of weet iemand een andere robotstofzuiger oplossing dat met Fibaro samenwerkt, hoeft niet perse de iRobot Roomba te zijn.

Alvast bedankt
Gebruikersavatar
Door MarTronics
#886
Hoi Kevin,

Ik heb deze pas gevonden, heb m nog niet kunnen testen ... maar denk dat de basis wel goed is :

-----------------------------------------------------------------------------

Following the steps shown below you can control your Roomba through Fibaro Home Center 2 and RooWifi:

Step 1
Create a virtual device, in this case we will call it Roomba:

Fibaro Home Center 2 Creating New Virtual Device for RooWifi Roomba Wi-Fi Adapter

Step 2
Create four simple buttons for Clean, Dock, Spot and to know the Charge status, let’s call it Status.

Step 3
The last step, then, the only that you need to do is attach the following scripts to the buttons created in the previous step and remember to change the IP 111.222.333.444 for the IP assigned that you assigned to your RooWifi: Wi-Fi Adapter and…That’s All!

Script for CLEAN Button
-- Setting up the connection data
ROOMBA = Net.FHttp("111.222.333.444", 80)

-- geting info about specific device
response = ROOMBA:GET("/roomba.cgi?button=CLEAN")

-- decoding json string to table
result = response;
Fibaro.log(result);
Script for DOCK Button
-- Setting up the connection data
ROOMBA = Net.FHttp("111.222.333.444", 80)

-- geting info about specific device
response = ROOMBA:GET("/roomba.cgi?button=DOCK")

-- decoding json string to table
result = response;
Fibaro.log(result);
Script for SPOT Button
-- Setting up the connection data
ROOMBA = Net.FHttp("111.222.333.444", 80)

-- geting info about specific device
response = ROOMBA:GET("/roomba.cgi?button=SPOT")

-- decoding json string to table
result = response;
Fibaro.log(result);
Script for STATUS Button (Charge Status)
-- Setting up the connection data
ROOMBA = Net.FHttp("111.222.333.444", 80)

-- geting info about specific device
response = ROOMBA:GET("/roomba.json")

-- decoding json string to table
extractedjson = json.decode(response)

-- Special usecase of [""] for json tree items with a - in it.
-- Be aware not to use a . infront of the [ !!
-- The following JSON codes can be extracted
-- All that needs to be done is replace the rX value and rename the variable to whatever you liek
--
-- "r0": "Bumps Wheeldrops"
-- "r1": "Wall"
-- "r2": "Cliff Left"
-- "r3": "Cliff Front Left"
-- "r4": "Cliff Front Right"
-- "r5": "'Cliff Right'"
-- "r6": "Virtual Wall"
-- "r7": "Motor Overcurrents"
-- "r8": "Dirt Detector - Left"
-- "r9": "Dirt Detector - Right"
-- "r10": "Remote Opcode"
-- "r11": "Buttons"
-- "r12": "Distance"
-- "r13": "'Angle'"
-- "r14": "Charging State"
-- "r15": "Voltage"
-- "r16": "Current"
-- "r17": "Temperature"
-- "r18": "Charge"
-- "r19": "Capacity"
motorovercurrents = extractedjson.response.r7.value
distance = extractedjson.response.r12.value
chargingstate = extractedjson.response.r14.value
voltage = extractedjson.response.r15.value
current = extractedjson.response.r16.value
temperature = extractedjson.response.r17.value
charge = extractedjson.response.r18.value
capacity = extractedjson.response.r19.value

-- output to resultline and globalvariable
fibaro:log(charge)
fibaro:setGlobal("roombacharge", charge);
This is how you can have a basic control of your Roomba with RooWifi integrated with Fibaro Home Center 2 easyly and working pretty well.
Door KevinKusters
#887
@MarTronics

Bedankt voor je reactie. Helaas wordt in het door jouw genoemde stappenplan gebruikt gemaakt van de Roowifi. Zoals ik in mijn “probleemomschrijving” al aangaf is deze end of life en dus niet meer leverbaar. :(
Door fkruis
#958
HI Kevin,

de Roowifi is nog steeds bestelbaar via hun website.
De kwaliteit van het product dat is een ander onderwerp.

Bypass is toch alleen bedoeld voor belastingen <[…]

Graag jullie advies: Ik heb meerdere fibaro v2 di[…]

Op zoek naar een Fibaro Shop?