Tahoma Binding compatible with OH2

Somfy seems to have changed something. I was forced into a Tahoma update last night and now I receive an “Unauthorized” in OpenHab,

Same here. @Ondrej_Pecta what do you think?

I am running on firmware 2017.5.4-16 and everything works as expected. What firmware are you using?

2017.5.4-12

Hi,

Single shutter works fine for me but i have a problem with actiongroups.
I create a actiongroup in tahoma and i can find this in the inbox from openhab.
After add the actiongroup in have a switch with no function.
An error apers in the log:

 2018-01-12 13:19:35.215 [ome.event.ItemCommandEvent] - Item 'Buero50_SomfyActionGroupTrigger01' received command ON
 
 2018-01-12 13:19:35.249 [vent.ItemStateChangedEvent] - Buero50_SomfyActionGroupTrigger01 changed from OFF to ON
 
 2018-01-12 13:19:35.320 [ERROR] [nal.common.AbstractInvocationHandler] - An error occurred while calling method 'ThingHandler.handleCommand()' on 'org.openhab.binding.somfytahoma.handler.SomfyTahomaActionGroupHandler@128e8de': java.lang.String cannot be cast to java.lang.Double

Have anyone a solution for my problem?

Could you please try the latest snapshot? Execution of action groups was rewritten in December 2017.
Thanks.
https://openhab.jfrog.io/openhab/libs-pullrequest-local/org/openhab/binding/org.openhab.binding.somfytahoma/2.3.0-SNAPSHOT/org.openhab.binding.somfytahoma-2.3.0-SNAPSHOT.jar

Great

With this snapshot actiongroups are working fine.

Ondrej,

Can you clarify how the communication works?
I am about to install window shutters and consider the Somfy connexoon controller.
However, when reading the thread it looks as if every command is send to a Somfy server which sends it back to the connexoon box followed by the action.
It not only takes time, but also means that my private network requires ports to be opened for the server and it always require an active internet connection.

I like to remove all these dependencies and rather have a direct connection between OpenHab and the connexxoon box.

–Simon

It uses the same way how mobile application or tahomalink.com web portal communicates with your local tahoma/connexoon device.
No ports opening needed - only internet connection. So if your mobile application works, this binding will work too…

Hi Ondrej,

Thanks for the reply, this confirms my suspicion on how the system communicates with the local connexoon box.
The system will not work if you setup a firewall for the local network that blocks all incoming traffic, hence the reason to open a (network) port to allow the somfy server access to the connexoon box.
I guess there is currently no workaround for this.
I have seen remarks in other threads that people tried to control the blinds locally but without success, which means this is the only solution for the moment.

–Simon

You do not have to open any ports since the connection initiator is your box (it is a standard TCP outbound connection and your router is out of the box configured for such communication)
So it might work this way:

  • your box opens a connection to Somfy server
  • your box listens for any events which occur on Somfy sever
  • your box does the action according to the cought event

So - Somfy server does not connect to your box and you need no extra configuration to make it working.
You are right, there is an extra delay (100~200milliseconds in my case) before your command is executed, but I can assure you it works pretty well anyway :slight_smile:

Hi guys,

I’m currently waiting for my Connexoon box to arrive as I understood the this box is also using the same API as the much more expensive Tahoma box.

Will this binding get also an offical binding at some point?
Can I use the latest version from this thread …2.3.0.snapshot.jar also in a openHAB 2.2 version?

Best regards
Timmi

Hi,

yes it will work (of course you need to connect your box to internet and register it).
The 2.3.0-SNAPSHOT will work in openHAB 2.2

This binding is currently waiting for revision and until this is finished it can’t be found in official bindings repository.

Hi Ondrej,

thank you for the fast reply and the good work.

Best regards
Timmi

Hi Ondrej,

I finally received my Connexoon box and I’m running into issues quite early.

2018-01-20 14:57:28.546 [ERROR] [oma.handler.SomfyTahomaBridgeHandler] - Cannot get login cookie!
java.io.IOException: Server returned HTTP response code: 403 for URL: https://www.tahomalink.com/enduser-mobile-web/externalAPI/json/login
	at sun.reflect.GeneratedConstructorAccessor411.newInstance(Unknown Source) [?:?]
	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) [?:?]
	at java.lang.reflect.Constructor.newInstance(Constructor.java:423) [?:?]
	at sun.net.www.protocol.http.HttpURLConnection$10.run(HttpURLConnection.java:1944) [?:?]
	at sun.net.www.protocol.http.HttpURLConnection$10.run(HttpURLConnection.java:1939) [?:?]
	at java.security.AccessController.doPrivileged(Native Method) ~[?:?]
	at sun.net.www.protocol.http.HttpURLConnection.getChainedException(HttpURLConnection.java:1938) [?:?]
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1508) [?:?]
	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492) [?:?]
	at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:263) [?:?]
	at org.openhab.binding.somfytahoma.handler.SomfyTahomaBridgeHandler.login(SomfyTahomaBridgeHandler.java:140) [234:org.openhab.binding.somfytahoma:2.3.0.201801112201]
	at org.openhab.binding.somfytahoma.handler.SomfyTahomaBridgeHandler.updateTahomaStates(SomfyTahomaBridgeHandler.java:425) [234:org.openhab.binding.somfytahoma:2.3.0.201801112201]
	at org.openhab.binding.somfytahoma.handler.SomfyTahomaBridgeHandler.access$0(SomfyTahomaBridgeHandler.java:422) [234:org.openhab.binding.somfytahoma:2.3.0.201801112201]
	at org.openhab.binding.somfytahoma.handler.SomfyTahomaBridgeHandler$1.run(SomfyTahomaBridgeHandler.java:98) [234:org.openhab.binding.somfytahoma:2.3.0.201801112201]
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:?]
	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:?]
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:?]
	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:?]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]
	at java.lang.Thread.run(Thread.java:748) [?:?]

It looks like I can’t login with my credentials which I have created via https://www.somfy-connect.com.
Also if I try to login through the website https://www.tahomalink.com . I’m receiving wrong user or password.

The mobile app is working fine for me with user and password.

Do you have any recommendation what to check?

Best regards
Timmi

Sorry my fault!!!

I’ve got the binding set up with some Venetian blinds and it all seems to work great. Thanks to those who made the binding it’s awesome.

I there a way to send a small increment to the blinds??? I can do this with the RTS remote or the app.

I want to be able to tilt the blinds and at the moment, I can either open fully or close fully or use the ‘my’ setting. It’s not enough as I want to have different amounts of tilt that I set based on the weather.

Thanks,

Ian

have you tried the “orientation” channel?
this channel should control the slats orientation…

Ondrej

The Orientation channel seems to only work as a switch. So it can be either “open” or “closed”. I tried it as a dimmer type but got the error

“2018-02-18 16:25:06.499 [ERROR] [oma.handler.SomfyTahomaBridgeHandler] - Cannot send apply command setOrientation with params [19]!
java.io.IOException: Server returned HTTP response code: 400 for URL: https://www.tahomalink.com/enduser-mobile-web/externalAPI/json/apply
at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(Unknown Source) [?:?]
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source) [?:?]
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(Unknown Source) [?:?]
at org.openhab.binding.somfytahoma.handler.SomfyTahomaBridgeHandler.sendDataToTahomaWithCookie(SomfyTahomaBridgeHandler.java:569) [239:org.openhab.binding.somfytahoma:2.3.0.2018011521
45]
at org.openhab.binding.somfytahoma.handler.SomfyTahomaBridgeHandler.sendCommandInternal(SomfyTahomaBridgeHandler.java:610) [239:org.openhab.binding.somfytahoma:2.3.0.201801152145]
at org.openhab.binding.somfytahoma.handler.SomfyTahomaBridgeHandler.sendCommand(SomfyTahomaBridgeHandler.java:593) [239:org.openhab.binding.somfytahoma:2.3.0.201801152145]
at org.openhab.binding.somfytahoma.handler.SomfyTahomaVenetianBlindHandler.handleCommand(SomfyTahomaVenetianBlindHandler.java:70) [239:org.openhab.binding.somfytahoma:2.3.0.2018011521
45]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[?:?]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[?:?]
at java.lang.reflect.Method.invoke(Unknown Source) ~[?:?]…”

Ian

OK, it seems that RTS venetian blinds use another command for the orientation setting. Can you please PM me your getSetup response (you can see it during binding initialization on DEBUG)
thanks
Ondrej