Yes, it is installed. The rule is working with JSONPATH.
I am maintaining all items in text files. Adding Profiles seems not to trigger the recreation of the item. But this topic might not belong here.
Hello! I’m trying to connect the MyBMW binding to my Z4. I use the MyBMW app, which works great, after the BMWConnected app only worked sporadically.
Currently, I’m trying to get the binding to connect to my account, and it’s not connecting. I’ve selected the Prefer MyBMW API after entering my account info. I’m sure it’s user error on my part. Logs show–
2022-01-18 10:55:30.817 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'bmwconnecteddrive:account:f2bc880050' changed from UNKNOWN to OFFLINE (COMMUNICATION_ERROR): Forbidden
2022-01-18 10:55:30.820 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'bmwconnecteddrive:conv:f2bc880050:0b75b16c0c' changed from UNKNOWN to OFFLINE (BRIDGE_OFFLINE)
2022-01-18 10:55:35.861 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'bmwconnecteddrive:account:f2bc880050' changed from OFFLINE (COMMUNICATION_ERROR): Forbidden to UNKNOWN
2022-01-18 10:55:35.865 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'bmwconnecteddrive:conv:f2bc880050:0b75b16c0c' changed from OFFLINE (BRIDGE_OFFLINE) to UNKNOWN
==> /var/log/openhab/openhab.log <==
2022-01-18 10:55:38.257 [WARN ] [mmon.WrappedScheduledExecutorService] - Scheduled runnable ended with an exception:
at org.eclipse.jetty.util.UrlEncoded.decodeTo(UrlEncoded.java:238) ~[?:?]
at org.openhab.binding.bmwconnecteddrive.internal.handler.ConnectedDriveProxy.codeFromUrl(ConnectedDriveProxy.java:446) ~[?:?]
at org.openhab.binding.bmwconnecteddrive.internal.handler.ConnectedDriveProxy.updateToken(ConnectedDriveProxy.java:303) ~[?:?]
at org.openhab.binding.bmwconnecteddrive.internal.handler.ConnectedDriveProxy.getToken(ConnectedDriveProxy.java:252) ~[?:?]
at org.openhab.binding.bmwconnecteddrive.internal.handler.ConnectedDriveProxy.call(ConnectedDriveProxy.java:144) ~[?:?]
at org.openhab.binding.bmwconnecteddrive.internal.handler.ConnectedDriveProxy.get(ConnectedDriveProxy.java:177) ~[?:?]
at org.openhab.binding.bmwconnecteddrive.internal.handler.ConnectedDriveProxy.requestVehicles(ConnectedDriveProxy.java:185) ~[?:?]
at org.openhab.binding.bmwconnecteddrive.internal.handler.ConnectedDriveBridgeHandler.lambda$3(ConnectedDriveBridgeHandler.java:116) ~[?:?]
at java.util.Optional.ifPresent(Optional.java:183) ~[?:?]
at org.openhab.binding.bmwconnecteddrive.internal.handler.ConnectedDriveBridgeHandler.requestVehicles(ConnectedDriveBridgeHandler.java:116) ~[?:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) ~[?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:264) ~[?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
at java.lang.Thread.run(Thread.java:829) [?:?]
2022-01-18 10:56:17.075 [INFO ] [control.internal.WebSocketConnection] - Web Socket close 1005. Reason: null
2022-01-18 10:57:26.413 [INFO ] [control.internal.WebSocketConnection] - Web Socket close 1005. Reason: null
2022-01-18 10:58:35.756 [INFO ] [control.internal.WebSocketConnection] - Web Socket close 1005. Reason: null
2022-01-18 10:59:45.045 [INFO ] [control.internal.WebSocketConnection] - Web Socket close 1005. Reason: null
Yes I can confirm that login for US isn’t working anymore in BMW ConnecteDrive binding. In this thread we are discussing the first tests of the new MyBMW binding - the successor of the BMW ConnectedDrive binding which was introduced ~ 1.5 years ago. As you can see in the last posts many people are suffering due to more and more shutdowns of the old BMW API.
Fantastic-- thanks for the help! I’m still having some issues installing it, either through the marketplace (it tells me installation failed), and isn’t showing after manually putting the jar in the addons folder. I’m sure I have a configuration error someplace and will try to find it before I ask for more help.
As you can probably tell, I’m very new to openHAB, but so far, since installing it two days ago, I’ve interfaced it via Global Cache CC boxes with the 60 year old relays that run many of the lights in my house, and have it running on Astro events.
Edit: I figured it out-- strictly user error as I thought. Thanks again! It’s working perfectly!
I’m right now starting to create my own pages and added a widged with some items related to my car on the overview page. I wonder whether it is possible to show the location of the car instead of GPS coordiates. When I tested Home Assistant a month ago it was super easy to add a card showing the location of the car.
Go to Settings - Pages and Create Map View. In settings add a marker with the coordinates item. Add a circle marker with coordinates as center and range-radius as circle. Save the page and the Map view is ready.
If you want this in a widget just one trick needed. Open the created map view and copy the url. In your overview create a Web Frame Card. Paste URL as adress and the Map is shown inside.
One further enhancement request. I suggest to create a new channel ‘InMotion’ with Switch as type. As long as the car is changing coordinates between updates from the API the Switch should be ON. Once two updates in a row have the same coordinates, then the ‘InMotion’ switch channel should become off.
This would allow further logics to attach to this, i.e. if the car is not in motion and the doors are not locked, generate a notification to the user.
Unfortunately the BMW API (at least for my X1 PHEV) does not update the coordinates during driving. There are only certain events when the information are updated, like shutdown, start of charging, etc.
This issue is not related to the binding, but to the API or the car itself as the car or the API does not send this data. A 1m refresh period would just poll the same (not updated) information from the API more often.
I observed the same behavior like @schmidmuc Neither inMotion nor coordinates are changed during driving, regardless the poll intervall settings. Last update time only changes if some door states are changed or charging.
Sadly I didn’t found a hint so far in json reply if the car is supporting driving updates or not.
I have also been thinking of this. In my case I would like to disarm our alarm system (DSC1864) because when the alarm system is armed all the lights at our house are switched off, also in the garage. The problem is that how does OH know if the car is approaching the house or if it is leaving. Of course you don’t want OH to disarm the alarm system when you are leaving. So, I guess I would need to add some more logic.
I created a athome contact item. This will be set to closed when the distance from home is less than 10 meter and the doors are open or the car is not moving anymore. When athome is closed and the distance from home is more than 50 meters athome will change to open. I also use some global vars for distance from home, which I am setting to false if athome is closed.
With those item and vars it is easily possible to know if the car is approaching or leaving.
But to open the garage door the coordinates are still refreshed too seldom. Sometimes I would have to wait quite some time in front of the garage door until it would open automatically. And if I would set the geo fence too big I would also open the garage door even if I am just driving by.