Nissan Leaf Plugin

Posted on
Sat Aug 11, 2018 12:06 pm
howartp offline
Posts: 3666
Joined: Jan 09, 2014
Location: West Yorkshire, UK

Re: Nissan Leaf Plugin

Thanks Thomas!

Just got round to updating my copy of the plugin for the new address and my 2018 Leaf.

Peter

Posted on
Fri Sep 14, 2018 3:37 pm
thomas-ja27 offline
Posts: 8
Joined: Jul 03, 2018
Location: Mosjøen, Norway

Re: Nissan Leaf Plugin

Is there someone else getting this error?
Leaf 2018

The plugin logging successfully in to the Nissan server, but when it updating the status this error appears..

Nissan Leaf Error Error in plugin execution runConcurrentThread:

Traceback (most recent call last):
File "plugin.py", line 171, in runConcurrentThread
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/indigo_leaf.py", line 146, in update_if_necessary
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/indigo_leaf.py", line 166, in request_and_update_status
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/indigo_leaf.py", line 295, in update_status
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/pycarwings2/pycarwings2.py", line 387, in get_latest_hvac_status
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/pycarwings2/responses.py", line 292, in __init__
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/pycarwings2/responses.py", line 50, in _set_cruising_ranges
KeyError: 'CruisingRangeAcOff'

Nissan Leaf Error plugin runConcurrentThread function returned or failed (will attempt again in 10 seconds)

Thomas

Posted on
Fri Sep 14, 2018 3:43 pm
thomas-ja27 offline
Posts: 8
Joined: Jul 03, 2018
Location: Mosjøen, Norway

Re: Nissan Leaf Plugin

Tride to login to my dads 2015 leaf, get an error on that too, but not the same:

Nissan Leaf Error Error in plugin execution runConcurrentThread:

Traceback (most recent call last):
File "plugin.py", line 171, in runConcurrentThread
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/indigo_leaf.py", line 146, in update_if_necessary
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/indigo_leaf.py", line 166, in request_and_update_status
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/indigo_leaf.py", line 295, in update_status
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/pycarwings2/pycarwings2.py", line 387, in get_latest_hvac_status
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/pycarwings2/responses.py", line 292, in __init__
File "/Library/Application Support/Perceptive Automation/Indigo 7/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/pycarwings2/responses.py", line 50, in _set_cruising_ranges
TypeError: list indices must be integers, not str

Nissan Leaf Error plugin runConcurrentThread function returned or failed (will attempt again in 10 seconds)

Thomas

Posted on
Fri Sep 14, 2018 4:07 pm
howartp offline
Posts: 3666
Joined: Jan 09, 2014
Location: West Yorkshire, UK

Re: Nissan Leaf Plugin

No errors here, though I’m getting 0.0 miles as a result for that value.

Try editing/resave your device?

Peter


Sent from my iPhone using Tapatalk Pro

Posted on
Fri Sep 14, 2018 4:33 pm
thomas-ja27 offline
Posts: 8
Joined: Jul 03, 2018
Location: Mosjøen, Norway

Re: Nissan Leaf Plugin

I have deleted the plugin and the device and installed it again, and changed the base url, but get the same error.
Have also tried on an different Mac with a fresh indigo install :?

Thomas

Posted on
Tue Feb 12, 2019 2:43 pm
dherren offline
Posts: 21
Joined: Nov 26, 2003
Location: Shoreham, VT USA

Re: Nissan Leaf Plugin

I am unable to get this plugin to work. Running Indigo 7.2 and plugin version 0.2.1

I get this error when I try to enable to plugin:

Feb 12, 2019, 3:36:43 PM
Installing and enabling plugin Nissan Leaf v0.2.1
Loading plugin "Nissan Leaf 0.2.1"
Starting plugin "Nissan Leaf 0.2.1" (pid 79042)
Nissan Leaf Error Error in plugin execution InitializeMain:

Traceback (most recent call last):
File "plugin.py", line 9, in <module>
File "/Library/Application Support/Perceptive Automation/Indigo 7.2/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/indigo_leaf.py", line 5, in <module>
File "/Library/Application Support/Perceptive Automation/Indigo 7.2/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/pycarwings2/__init__.py", line 2, in <module>
File "/Library/Application Support/Perceptive Automation/Indigo 7.2/Plugins/Nissan Leaf.indigoPlugin/Contents/Server Plugin/pycarwings2/pycarwings2.py", line 73, in <module>
ImportError: No module named Crypto.Cipher

Stopping plugin "Nissan Leaf 0.2.1" (pid 79042)
Stopped plugin "Nissan Leaf 0.2.1"

Any suggestions?

Posted on
Tue Feb 12, 2019 2:53 pm
dherren offline
Posts: 21
Joined: Nov 26, 2003
Location: Shoreham, VT USA

Re: Nissan Leaf Plugin

My server is running on 10.12.6

On my desktop, 10.13.4

Posted on
Wed Feb 13, 2019 11:15 am
dherren offline
Posts: 21
Joined: Nov 26, 2003
Location: Shoreham, VT USA

Re: Nissan Leaf Plugin

That looked like it was the problem, and I was encouraged, but:

idiomatrix:~ sysadmin$ sudo easy_install-2.6 pycrypto
Password:
Searching for pycrypto
Reading http://pypi.python.org/simple/pycrypto/
Couldn't find index page for 'pycrypto' (maybe misspelled?)
Scanning index of all packages (this may take a while)
Reading http://pypi.python.org/simple/
No local packages or download links found for pycrypto

I'm pretty inexperienced when it comes to installing such things. Was I to have downloaded something first?

Thanks for you help!

Posted on
Wed Feb 13, 2019 11:38 am
dherren offline
Posts: 21
Joined: Nov 26, 2003
Location: Shoreham, VT USA

Re: Nissan Leaf Plugin

OK, so new territory. I manually downloaded the source code to pycrypto. Then had to install the developer tools. Got the package compiled and installed.

This time around the plugin loaded. When I attempted to configure it, it generates the following error:

Error validating fields. Hover over the red field labels above to see the error reason.

There are no red labels. Using the same username and password I use for the Nissan Connect app on iPhone.

The Indigo log with debugging turned on for the plugin reports:

Feb 13, 2019 at 12:43:33 PM
Nissan Leaf Debug debug logging enabled
Nissan Leaf Debug using distance scale 'm'
Nissan Leaf Error Error in plugin execution UiValidate:

Traceback (most recent call last):
File "plugin.py", line 157, in validatePrefsConfigUi
KeyError: key username not found in dict

Posted on
Fri Mar 01, 2019 2:10 am
howartp offline
Posts: 3666
Joined: Jan 09, 2014
Location: West Yorkshire, UK

Re: Nissan Leaf Plugin

Hi dherren

Sorry I’ve missed your posts.

Glad Ian could help with pointing you to pycrypto; the original dev has disappeared so I’m going to look at rewriting the plugin on the same codebase as my Tesla plugin.

In the meantime can you delete the Leaf plugin, browse to the Indigo folder in Finder and find the Leaf plugin prefs file and delete it - sorry I don’t have path to hand right now.

Then reinstall plugin.

Peter


Sent from my iPhone using Tapatalk Pro

Posted on
Wed Jul 31, 2019 6:02 am
howartp offline
Posts: 3666
Joined: Jan 09, 2014
Location: West Yorkshire, UK

Re: Nissan Leaf Plugin

OK.

ALL USERS OF THIS PLUGIN:

As of two days ago, Nissan changed the API that users in UK and Europe used to connect. From reading forums it suggests that USA and Canada possibly changed months ago? UK/Europe certainly can’t connect at present, except by the official app.

Could anyone who uses, or used to but can’t, this plugin please respond below with:

Leaf or eNV200?
Battery (24, 30, 40, 62)?
Model year (2011, 2013, ..., 2018 or 2019)?
Region (UK, Europe, USA or Canada)?
Does the plugin currently work?
Which Nissan app do you use? (UK uses “NissanConnect EV” for pre-2019 and “NissanConnect Services” for 2019 onwards)
Does the app currently work?

I’m going to rewrite the plugin from scratch as by license I can’t modify Dusty’s original, and the base code is out of date anyway.

If anyone is willing to lend me their credentials by pm, that would be useful - my Leaf is UK 2019 which I know uses a different app to my old 2015 and 2018; I’ve not yet been able to prove if the API is different.

Peter



Sent from my iPhone using Tapatalk Pro

Posted on
Wed Jul 31, 2019 2:22 pm
howartp offline
Posts: 3666
Joined: Jan 09, 2014
Location: West Yorkshire, UK

Re: Nissan Leaf Plugin

Ok, so I now know my (2019 Leaf) credentials aren't going to work with the existing plugin, so I'm definitely going to need to borrow somebody's credentials if there's anyone out there willing to lend me them?

I have two sets of credentials for Tesla, and I've not yet summoned their Tesla to come to me, so I assure you I'm trustworthy!

Peter

Posted on
Sat Aug 03, 2019 7:11 am
durosity offline
User avatar
Posts: 3810
Joined: May 10, 2012
Location: Newcastle Upon Tyne, Ye Ol' England.

Re: Nissan Leaf Plugin

howartp wrote:
I have two sets of credentials for Tesla, and I've not yet summoned their Tesla to come to me, so I assure you I'm trustworthy!

Peter


He is! Those two Tesla’s on his driveway that he auto summoned totally are his!

On a side note you suggested you might be adding other cars to the plugin a while ago.. is that still the plan?

Computer says no.

Posted on
Sat Aug 03, 2019 7:14 am
howartp offline
Posts: 3666
Joined: Jan 09, 2014
Location: West Yorkshire, UK

Re: Nissan Leaf Plugin

Hehe!

Yep, I’ve got Volvo code written as scripts, just need to convert to Plugin.

Renault will be next if I can find any Scots willing to let me summon their Zoe whilst testing the code.


Sent from my iPhone using Tapatalk Pro

Posted on
Sat Aug 03, 2019 7:17 am
durosity offline
User avatar
Posts: 3810
Joined: May 10, 2012
Location: Newcastle Upon Tyne, Ye Ol' England.

Re: Nissan Leaf Plugin

Hehe. I’ll need to get onto Renault about that.. my login hasn’t worked for a while..


Sent from my iPhone using Tapatalk Pro

Computer says no.

Who is online

Users browsing this forum: No registered users and 0 guests