New Plugin - BMW Connected Drive

Posted on
Sat May 29, 2021 3:51 pm
ryanbuckner offline
Posts: 1080
Joined: Oct 08, 2011
Location: Northern Virginia

Re: New Plugin - BMW Connected Drive

Is there a way to access the timestamp for the last time the connected API call was made? I think this is different than the device states like internalDataTimeUTC which only update when data changes.

Posted on
Sat May 29, 2021 4:03 pm
FlyingDiver online
User avatar
Posts: 7210
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: New Plugin - BMW Connected Drive

It's not available as a state, but it is a property of the account device (all updates are managed through the account device).

Code: Select all
acct = indigo.devices[ID OF ACCOUNT DEVICE]
last_update = acct.lastChanged


That gives a string time stamp.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Sat May 29, 2021 5:02 pm
ryanbuckner offline
Posts: 1080
Joined: Oct 08, 2011
Location: Northern Virginia

Re: New Plugin - BMW Connected Drive

Perfect, thanks. I feel it's easier to trigger my checks from this value changing since there doesn't appear to be a way to Trigger off any state change for a device.

Posted on
Tue Jun 01, 2021 12:57 am
macpro offline
User avatar
Posts: 765
Joined: Dec 29, 2005
Location: Third byte on the right

Re: New Plugin - BMW Connected Drive

Question: is it possible to get the tire pressure from all tires?
Our Mini is complaining about a low tire pressure, but the Mini Connected app doesn't show the tire pressure.

Posted on
Tue Jun 01, 2021 5:46 am
FlyingDiver online
User avatar
Posts: 7210
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: New Plugin - BMW Connected Drive

macpro wrote:
Question: is it possible to get the tire pressure from all tires?
Our Mini is complaining about a low tire pressure, but the Mini Connected app doesn't show the tire pressure.


I don't see tire pressure in the data for my BMW. You can check to be sure by using the menu command "Write Vehicle Data to Log".

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Tue Jun 01, 2021 5:51 am
macpro offline
User avatar
Posts: 765
Joined: Dec 29, 2005
Location: Third byte on the right

Re: New Plugin - BMW Connected Drive

Thanks. It's not there.

Posted on
Sat Aug 07, 2021 4:29 am
macpro offline
User avatar
Posts: 765
Joined: Dec 29, 2005
Location: Third byte on the right

Re: New Plugin - BMW Connected Drive

The 400 error is back. :(

Code: Select all
7 Aug 2021 at 12:21:45
   BMW Connected Drive Error       get_tokens AUTH call failed, response code = 400
   BMW Connected Drive Error       Error in plugin execution runConcurrentThread:

Traceback (most recent call last):
  File "plugin.py", line 140, in runConcurrentThread
  File "plugin.py", line 177, in updateVehicle
  File "/Library/Application Support/Perceptive Automation/Indigo 2021.1/Plugins/BMW ConnectedDrive.indigoPlugin/Contents/Server Plugin/bmwcdapi.py", line 179, in get_vehicle_data
TypeError: 'NoneType' object has no attribute '__getitem__'

   BMW Connected Drive Error       plugin runConcurrentThread function returned or failed (will attempt again in 10 seconds)


Posted on
Sat Aug 07, 2021 5:54 am
neilk offline
Posts: 715
Joined: Jul 13, 2015
Location: Reading, UK

Re: New Plugin - BMW Connected Drive

I suspect BMW have changed the authentication in the API, people with connected EV chargers reporting similar issues failing to connect to the API to get state of charge of the car.

Posted on
Sat Aug 07, 2021 8:13 am
FlyingDiver online
User avatar
Posts: 7210
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: New Plugin - BMW Connected Drive

Yeah, BMW broke this if and when the Python library I use for this is updated to address the issue, then I'll update the plugin. Until then it's dead.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Sat Aug 07, 2021 8:20 am
FlyingDiver online
User avatar
Posts: 7210
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: New Plugin - BMW Connected Drive

macpro wrote:
The 400 error is back. :(

Code: Select all
7 Aug 2021 at 12:21:45
   BMW Connected Drive Error       get_tokens AUTH call failed, response code = 400
   BMW Connected Drive Error       Error in plugin execution runConcurrentThread:

Traceback (most recent call last):
  File "plugin.py", line 140, in runConcurrentThread
  File "plugin.py", line 177, in updateVehicle
  File "/Library/Application Support/Perceptive Automation/Indigo 2021.1/Plugins/BMW ConnectedDrive.indigoPlugin/Contents/Server Plugin/bmwcdapi.py", line 179, in get_vehicle_data
TypeError: 'NoneType' object has no attribute '__getitem__'

   BMW Connected Drive Error       plugin runConcurrentThread function returned or failed (will attempt again in 10 seconds)



Looks like you're using an older version of the plugin that was using the old Python 2 library. That one will never be updated, the author has discontinued it. The more recent versions of the plugin use a Python 3 library, but it's also having an issue due to BMW changes. If/when this gets fixes, it'll be the new Python 3 version only.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Sat Aug 07, 2021 9:17 am
macpro offline
User avatar
Posts: 765
Joined: Dec 29, 2005
Location: Third byte on the right

Re: New Plugin - BMW Connected Drive

That's the 0.0.7 version of the plugin from the PluginStore. Made by... FlyingDiver.

Posted on
Sat Aug 07, 2021 9:20 am
FlyingDiver online
User avatar
Posts: 7210
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: New Plugin - BMW Connected Drive

macpro wrote:
That's the 0.0.7 version of the plugin from the PluginStore. Made by... FlyingDiver.


It's still an old version. There's multiple 1.0.X pre-release versions based on the new library. In any case, when and if this is fixed, it will only be in the 1.X version.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Sat Aug 07, 2021 9:26 am
macpro offline
User avatar
Posts: 765
Joined: Dec 29, 2005
Location: Third byte on the right

Re: New Plugin - BMW Connected Drive

I see. But if there is a newer version (which I just found on Github), why is the old version still in the Plugin Store? And why is the new version only available on Github?
That's a bit confusing.

Posted on
Sat Aug 07, 2021 9:27 am
FlyingDiver online
User avatar
Posts: 7210
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: New Plugin - BMW Connected Drive

macpro wrote:
I see. But if there is a newer version (which I just found on Github), why is the old version still in the Plugin Store? And why is the new version only available on Github?
That's a bit confusing.


Because it's a total re-write of the plugin and I was working with beta testers to iron out some issues. There are posts in this thread about testing the new version.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Sat Aug 07, 2021 9:48 am
macpro offline
User avatar
Posts: 765
Joined: Dec 29, 2005
Location: Third byte on the right

Re: New Plugin - BMW Connected Drive

Ok. Haven’t read the whole thread, so didn’t know that. Thanks for explaining.

Who is online

Users browsing this forum: No registered users and 3 guests