NOOB - Just stumbling in the Dark - Help with HHTP Switch or Energenie Mi|Home (UK)


(Andrew Vint) #1

Hi All,

I have managed to install Raspian on my Pi and get started using the OpenHab product and all in all i feel i am making good progress, however as anyone starting with a new product i am struggling to understand my way around a few things so i am kindly asking for pointers from the more experienced userbase out there.

My ultimate aim is to setup a HAB panel which will be displayed on a touch screen monitor on my hall wall to control and manage the array of different smart items in my home.

Now my current struggle is controlling my Energenie Mi|Home (UK) devices which i currently have two options in front of me;

  1. Get a Energenie Mi | Home Binding in place and figure out how to work it
  2. Use IFTTT maker widget and HTTP Binding POST to control Mi Home

Now i tried to go with option 2 but i have absolutely no idea how to present these as a habpanel item in the button.

I created a /items/mihome.items file and put the following in it

Switch Mi_Char_Bed_Light {http=">[ON:POST:https://maker.ifttt.com/trigger/openhab_char_light_on/with/key/xxxxxx]" >[OFF:POST:https://maker.ifttt.com/trigger/openhab_char_light_off/with/key/xxxxxx]"}

I also created the following entry in the /services/http.cfg
Switch Mi_Char_Bed_Light {http=">[ON:POST:https://maker.ifttt.com/trigger/openhab_char_light_on/with/key/xxxxxx]" >[OFF:POST:https://maker.ifttt.com/trigger/openhab_char_light_off/with/key/xxxxxx]"}

Again neither appearing in my openhab items …. i have been looking at it too long now and i have no idea how to proceed.

Please help if you can


(Rich Koshak) #2

Where are you looking?


(Andrew Vint) #3

I am in HanPanel, I add a button widget and I’m looking in the drop down menu titled Openhab items


(Dave Garratt) #4

Do you see anyting in the Control section of the web page yet - like you I have only just started but as I’ve reinstalled about 6 times in 2 days I’m getting the hang of it now.

Add bindings
Add things
Add items
click on items to create links which then appear in the Control section.

You can turn stuff on and off from there. I’m using philips hue bulbs.

Dave


(Rich Koshak) #5

When you save the .items file where these two Items are defined, do you see any errors in the logs?

It’s hard to tell because of the lack of code fences but you might have messed up quotes in the http config for the items.


(Andrew Vint) #6

Stupid question but where do I find the logs lol


(Andrew Vint) #7

Hi Dave, i added the http binding, when going to add items it didn’t find anything so that’s me stuck


(Dave Garratt) #8

If you go to the default web page - at least on mine there is a option to view logs there.


(Dave Garratt) #9

With the philips hue I had to authorise the binding before it would discover the things itself. For me that meant pressing the big blue button on the philips hub - I wonder if your binding is waiting for something like that.


(Dave Garratt) #10

My raspberry pi is in a sulk at the moment and my mac mini already has a web app using the same ports as openHab wants to use. Tomorrow when I have one of them running i will try and do some screen dumps of what I have discovered myself so far.


(Andrew Vint) #11

Yeah cool, found the log file viewer on the opening screen of my openhab portal. Nothing in there but errors saying can’t find remaining battery time but that would be expected as no battery.


(Rich Koshak) #12

There shouldn’t be any battery error messages in openhab.log unless you’ve created a Thing or Item that is missconfigured and has battery in the name.

  1. Edit your config files using VSCode.

  2. With very few exceptions, ALL errors in openhab.log should be identified, explained, and in most cases fixed. Do not ignore errors.

  3. Like I said above, your Items file probably has syntax errors (which VSCode and openhab.log will point out when you save the file).


(Andrew Vint) #13

Thanks will give that a go and come back to you with what I find.