[Ovmsdev] Nissan Leaf

Mark Webb-Johnson mark at webb-johnson.net
Fri Dec 27 15:00:52 HKT 2013


Robert,

The leafspy log is interesting, but not very useful.

What I am interested in is a raw can bus dump. This can be done from the OBDII adaptor using 'monitor all' mode.

I know how to do it with a terminal emulator and some AT commands, but does anyone know any simple software that Robert can use?

Regards, Mark.

On 21 Dec, 2013, at 10:38 pm, Robert Sharpe <robert.sharpe at evergreen-consulting.co.uk> wrote:

> Hi Mark,
> 
> Sorry it has taken a while to get back to you.  I only have access to LeafSpy via my wife's work phone and she has been out most of the week. 
> I only just realised that logging could probably be done through the OVMS :-( so will try that in the next few days as well.
> 
> Anyway, attached is sample LeafSpy Elm Trace.  Before I do lots of testing using this method can you confirm that this is useful.
> 
> Regards,
> Rob
> 
> ---- On Wed, 18 Dec 2013 01:57:50 +0100 Mark Webb-Johnson<mark at webb-johnson.net> wrote ---- 
> 
> Nikki,
> 
> Thanks for this.
> 
> Firstly, I'm glad the firmware is connecting back to the server ok. I broke that a few months ago (this new module meant I had to reorganise some low-level crypto stuff to make room), and am glad it is fixed again.
> 
> For the SOC, I'm really just guessing. Supposedly message 0x5b3 on car can bus has GIDs in B6bit0 and B7 - I just divided that by 3 to get a rough approximation of SOC, but it is obviously not working. I think this one shouldn't be too hard, but I don't have any CAN bus dumps of what the 0x5b3 message looks like. If I can see a dump, with matching known SOC / GIDs, then I am sure we can get this right. That said, active polling (which is what leafspy uses) seems to be a better way of getting this, as it gets us true GIDs off the EV can bus.
> 
> Glad about the parking indicator. I work off the parking brake for that one, and it is an important status flag for quite a few things.
> 
> I'm working on the polling mechanism at the moment. It is very similar to the OBDII VIN number polling mechanism we already have, and my recent work on the common vehicle.{h,c} polling code should make this relatively easy.
> 
> Regards, Mark.
> 
> On 18 Dec, 2013, at 6:22 am, Nikki Gordon-Bloomfield <nikki at aminorjourney.com> wrote:
> 
>> So here’s what I’ve learned from the alpha code so far… 
>> 
>> 1) It’s recording the parking status accurately, as far as I can tell. within a few minutes of parking, it’s noting that on the app screen. 
>> 
>> 2) It’s certainly sending me alerts as you might expect for low SOC warnings. 
>> 
>> 3) But sadly SOC isn’t working correctly with my car. For some reason, SOC is jumping all over the shop, with 22% SOC seemingly a favourite place for the OVMS code. On my quick trip just now to the shops, I noted it went from 76% SOC (which I think was fairly accurate given the number of bars I had) down to 22% when I parked up. 
>> 
>> Coming back, I got no update and ended up having to do a hard reboot to get the system to wake up. 
>> 
>> I haven’t been able to get any logs yet because I don’t have a splitter for the ODBII system. I’ll get that sorted later this week/early next. 
>> 
>> Nikki.
>> 
>> 
>> 
>> 
>> On 17 Dec 2013, at 20:06, Nikki Gordon-Bloomfield <nikki at aminorjourney.com> wrote:
>> 
>>> Okay guys. 
>>> 
>>> I’ve done a couple of quick tests with the new beta software. 
>>> 
>>> First up, it installs (Which is good, of course) Second up: I was able to drive around the block and see some SOC reports. What did appear to happen is that SOC dropped and then went back up again. I had values from 27% SOC down to 14% SOC to Empty and back up to 22% SOC.  I’d guesstimate my real SOC was nearer 45%.  (Although I didn’t check with LEAFSpy)
>>> 
>>> Of course, I need to check the other bits and bobs too — Park/Drive status seems to work with the car on — but with the module rebooted, it forgets what was previously on. This is a problem I believe with the LEAF CAN bus, which turns itself off when parked. I’m guessing we’ll need to figure out a way to wake up CAN and then switch back off again? (That said,I think it’s supposed to stay on when charging… and I’m currently charging)
>>> 
>>> I’ll play a little more tomorrow and throughout the rest of the week. I’ll also try and get some decent logs if I can. 
>>> 
>>> Nikki. 
>>> 
>>> 
>>> On 17 Dec 2013, at 14:16, Mark Webb-Johnson <mark at webb-johnson.net> wrote:
>>> 
>>>> 
>>>> Attached is a first-run at Nissan Leaf support, with a few values read from the bus passively:
>>>> 
>>>> Speed
>>>> Headlight status
>>>> Park / Drive status
>>>> SOC
>>>> 
>>>> I’ve also pushed this to github (along with a large number of other small changes).
>>>> 
>>>> The Nissan Leaf support is proving really hard for me. I don’t have the car, or much CAN bus data, and the public documentation is contradictory and incomplete. End result is that I am just guessing, and completely unable to test my guesses.
>>>> 
>>>> Anyway, please try it and let me know if any of those figures show up with any sense of accuracy at all.
>>>> 
>>>> Going forward, I really need some CAN bus dumps from a Nissan Leaf. Specifically:
>>>> 
>>>> Car idle
>>>> Car plugged in and charge started
>>>> Car charging
>>>> Charge interrupted
>>>> Driving
>>>> Driving as close to a constant speed of 10 kph as possible
>>>> Driving as close to a constant speed of 20 kph as possible
>>>> Driving as close to a constant speed of 30 kph as possible
>>>> Car parked, but on
>>>> Car parked, coming out of park into drive gear
>>>> Car stopped, coming out of drive gear into park
>>>> Car in park gear, then handbrake applied
>>>> 
>>>> For each of those, both with and without a T connector and LeafSpy running would be helpful.
>>>> 
>>>> I’m guessing the logs can be gotten from monitor-all mode with an OBDII adaptor. There is not too much data on the can bus and that should be fast enough.
>>>> 
>>>> If anyone can help with the above, please let me know.
>>>> 
>>>> Regards, Mark.
>>>> 
>>>> <OVMS.X.production.zip>
>>>> _______________________________________________
>>>> OvmsDev mailing list
>>>> OvmsDev at lists.teslaclub.hk
>>>> http://lists.teslaclub.hk/mailman/listinfo/ovmsdev
>>> 
>> 
>> _______________________________________________
>> OvmsDev mailing list
>> OvmsDev at lists.teslaclub.hk
>> http://lists.teslaclub.hk/mailman/listinfo/ovmsdev
> 
> _______________________________________________ 
> OvmsDev mailing list 
> OvmsDev at lists.teslaclub.hk 
> http://lists.teslaclub.hk/mailman/listinfo/ovmsdev 
> 
> <TRC_1312211426.txt>_______________________________________________
> OvmsDev mailing list
> OvmsDev at lists.teslaclub.hk
> http://lists.teslaclub.hk/mailman/listinfo/ovmsdev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.teslaclub.hk/pipermail/ovmsdev/attachments/20131227/efeb0197/attachment.html>


More information about the OvmsDev mailing list