Created At

Oct 01, 2017

Last Update

Nov 02, 2017

Platforms

HC 2

Views

3076

Download

81

GARDENA smartsystem interface for Fibaro HC2:

Mowing the lawn, watering the garden, measuring light intensity, soil humidity and temperature. The GARDENA smart system enables you to sit back, relax and control your garden remotely. The GARDENA smart system Virtual Device for Fibaro HC2 enables you to extend your smart home to the garden and puts you in control of every corner of your property.

Prerequisites:

  • GARDENA smart gateway

Plus one or more of...

  • GARDENA smart sileno (+) robotic lawn mower
  • GARDENA smart sensor
  • GARDENA smart water control valve 

Developed and tested for use with:

  • GARDENA app version, web-release-sv_1.5.1-SGIT-SGITAW412-5
  • GARDENA backend API version, SGIT-SGITAPI347-8
  • GARDENA smart system gateway, firmware version 1.3.7

Supported functionality:

Scripts

This GARDENA smart system interface to Fibaro HC2 consists of:

  • A smart system status script which connects to the GARDENA cloud at regular intervals to retrieve information and status of all connected devices in your garden. 
  • A smart system command script which listens for and executes commands received from any installed and configured Fibaro virtual devices.

 

Virtual Devices

Virtual devices display status information retrieved by the status script and provide buttons to control the device. The gateway itself is not registered and managed as a virtual device.

 

GARDENA smart sileno (+) robotic lawn mower

 

gardena_smart_mower.jpggardena_smart_mower.png

 

Status information:

  • Device status, error messages, command execution status, operation status, start source,
  • Last time online, signal quality, radio link, connection status,
  • Battery level, battery health, charging status,
  • Ambient temperature,
  • Firmware status,
  • Scheduled next start and end times.

Commands:

  • Start mower, using override timer with 30 minute increments
  • Start mower, resume schedule
  • Park mower, until next scheduled event
  • Park mower, until further notice

 

GARDENA smart sensor

 

gardena_smart_sensor.jpggardena_smart_sensor.png

 

Status information:

  • Device status, error messages, command execution status, 
  • Last time online, signal quality, radio link, connection status,
  • Battery level, battery health, 
  • Ambient temperature, soil temperature, soil moisture, light intensity,
  • Frost warning,
  • Firmware status.

Commands:

  • Update ambient temperature
  • Update soil temperature
  • Update soli moisture
  • Update light intensity

 

GARDENA smart water control valve

 

GARDENA smart valve.jpggardena_smart_water_control.png

 

Status information:

  • Device status, command execution status, manual operation status, adaptive watering status,
  • Last time online, signal quality, radio link, connection status,
  • Battery level, battery health, 
  • Ambient temperature,
  • Frost warning,
  • Firmware status,
  • Scheduled next start and end times,
  • Manual operation time.

Commands:

  • Open valve, using override timer with 5 minute increments
  • Close valve

  

Installation and configuration:

  1. Download and extract the zip file provided below to a folder on your computer.
  2. Locate the GARDENA smart system command script in the folder and install by following the guidelines provided in the installation guide below. 
  3. Locate the GARDENA smart system status script in the folder and install by following the guidelines provided in the installation guide below. 
  4. Enter your GARDENA smart system credentials and switch on debugging in the status script.
  5. Start and stop the GARDENA smart system status script a number of times.
  6. Provided that your GARDENA smart system physical devices are setup and configured with the GARDENA smart gateway, the debug log will discover and show information on each physical device. 
  7. Note the device type and unique identifier. You will need this to…
  8. Create a corresponding virtual device in Fibaro HC2, by importing the relevant virtual device template, which you can download below.
  9. Enter the unique identifier – found in the Debug window of the status script – in the IP address field of the virtual device.
  10. Save the virtual device. Restart the status script if the status information does not update within one minute.

Icons for the virtual devices and for the scripts are provided in the download folder as well. Obviously you can remove and rearrange lables from the virtual devices to display only the information and buttons that are relevant for your smart garden setup.

Terms and conditions:

GARDENA, GARDENA smartsystem and the GARDENA smartsystem logo are trademarks of Husqvarna Group. The GARDENA smartsystem HTTP backend and web app API is a proprietary service provided by Husqvarna Group and governed by the terms and conditions imposed upon you by Husqvarna Group. Use of this interface may be illegal without obtaining prior written permission, or may be in disregard of Husqvarna Group terms of service. By downloading this Virtual Device you agree to be bound by Husqvarna Group terms and conditions of service. If you do not want to be bound by Husqvarna Group terms your only option is not to download the Virtual Device. 

Barlow and Fibaro make no warranty, express or implied, and do not assume any legal liability or responsibility for the right to disclose and publish Husqvarna Group proprietarty information, nor for the  accuracy, completeness, usefulness, reliability, or timeliness of any documents or information contained on this website or for the suitability, functionality, or operation of this work.

Barlow and Fibaro shall not be liable to anyone for any decision made or action taken, or not taken, in reliance on the information found on or dowbloaded from this website.  Users are advised to do their own independent investigation before relying on or taking/not taking any action based on information found on this website. All information on this web site is subject to change or removal without notice.

Barlow and Fibaro do not represent that use of any documents or information on this website would not infringe privately or commercially owned rights.

The disclaimer of warranties and limitation of liability provided above shall be interpreted in a manner that, to the extent possible, most closely approximates an absolute disclaimer and waiver of all liability.

22 Comments,  Want to add comment please login
2865a9fcf585534e07a0b231d4e52dfd

THE FOLLOWING VARIABLES MUST BE SET MANUALY IF YOU GET AN ERROR IN LINE 170: gardena_token gardena_userid gardena_command gardena_parameters gardena_location

2865a9fcf585534e07a0b231d4e52dfd

It refers to line 170, here is the code for line 167 to 177. function gLocation() local token = fibaro:getGlobal('gardena_token') local user_id = fibaro:getGlobal('gardena_userid') local url = 'https://sg-api.dss.husqvarnagroup.net/sg-1/locations/?user_id=' .. user_id local http = net.HTTPClient() http:request(url, { options={ headers = {['Content-Type'] = 'application/json',['X-Session'] = token}, method = 'GET', timeout = 5000 }, Any errors that is easy to spot?

Baefdd9ad78dd8e19a5dcaa1901c7b36

I get same error as Terje Andersen. [ fatal] LUA error: /opt/fibaro/scenes/108.lua:170: attempt to concatenate local 'user_id' (a nil value)

2865a9fcf585534e07a0b231d4e52dfd

I must have done something wrong as this do not work. [DEBUG] 22:50:09: GARDENA smartsystem - Autostart [DEBUG] 22:50:09: This scene runs every: 1 minutes [DEBUG] 22:50:10: Authentication was succesful [DEBUG] 22:50:10: 2018-07-01 22:50:10.166098 [ fatal] LUA error: /opt/fibaro/scenes/108.lua:170: attempt to concatenate local 'user_id' (a nil value)

5916666dcf2543e21f399e558fd449fa

I just tried to add that feature and it seemed quite easy. If you want I can sent you my new setup.... [DEBUG] 15:20:17: * * * * * * * * * * * * * * * * * * * * * * * * * * * * * [DEBUG] 15:20:17: Found the following GARDENA gateway: [DEBUG] 15:20:17: Name: Gateway [DEBUG] 15:20:17: Identifier: xxxxx [DEBUG] 15:20:17: * * * * * * * * * * * * * * * * * * * * * * * * * * * * * [DEBUG] 15:20:17: Found the following GARDENA mower: [DEBUG] 15:20:17: Name: Sjakie [DEBUG] 15:20:17: Identifier: e6d48b54-f0a5-4e4e-948c-e2988750be99 [DEBUG] 15:20:17: Corresponding Fibaro virtual device is 111 [DEBUG] 15:20:17: Battery level is 89 % [DEBUG] 15:20:17: Charging: no [DEBUG] 15:20:17: Signal quality is 50 % [DEBUG] 15:20:17: Connection is alive [DEBUG] 15:20:17: Radio link is poor [DEBUG] 15:20:17: Manual operation: no [DEBUG] 15:20:17: Running time is 12 minutes [DEBUG] 15:20:17: Status is OK - cutting away the grass! [DEBUG] 15:20:17: Status is OK - cutting away the grass! [DEBUG] 15:20:17: Error message: all clear [DEBUG] 15:20:17: Source for next start is no source [DEBUG] 15:20:17: Override end time is on 05-05-2018 at 14:37 [DEBUG] 15:20:17: Firmware is up to date [DEBUG] 15:21:16: Authentication was succesful [DEBUG] 15:21:16: Locating GARDENA smartsystem devices in My Garden [DEBUG] 15:21:16: * * * * * * * * * * * * * * * * * * * * * * * * * * * * *