[Ovmsdev] V3 size and arrangement

Mark Webb-Johnson mark at webb-johnson.net
Mon Jun 12 09:26:05 HKT 2017

Our current cables for Leaf have two can buses wired on them already, and both should work with OVMS v3.

I’m happy to make different cables for vehicles, if necessary. It is not too hard to arrange it here - the only issue is minimum order quantity usually 100 pieces or so.

Regarding the OTA update, yes it is scary. The ESP32 is standard ARM32 architecture. The OTA system is such that we have full control of the download and install of the firmware image. The 16MB flash is partitioned into three code areas (each 4MB in size) - factory, ota#1, and ota#2. The idea is the ‘factory’ contains the factory image. If you are running from ‘factory’ and do an OTA update, it goes to ota#1, then the system reboots and you are running in ‘ota#1’ now. Then, if you do another OTA update, that goes into ota#2, then the system reboots and you are running in ‘ota#2’ now. Next OTA update goes to ota#1. There is a consistency check system such that if the current OTA partition is corrupt, it goes back to factory. There are other ways of doing this, but that is the default approach.

The initial approach I am working on is to pull the OTA update via HTTPS, and use SSL certificate verification to ensure we are pulling from the correct location. Code signing would also be good to have, but I haven’t done it in the first version.

Regards, Mark.

> On 11 Jun 2017, at 9:21 AM, Tom Parker <tom at carrott.org> wrote:
> On 09/06/17 19:29, Mark Webb-Johnson wrote:
>> Yep, that’s the idea now. We’ll probably make another couple of ‘final’ boards to make sure all is ok. Check those, and if no problems then hand make another twenty or so for developers. If no problems reported, then make a large first production batch. Getting close now.
> I would be keen to get a developer board.
> The Leaf has 3 CAN buses (CAR, EV and Chademo) on the OBD2 connector and I really want to get the odometer value which isn't available on the EV bus we're on at the moment. I've also discovered that the 2016 model moved the TCU to the CAR bus, which may mean that we cannot do remote climate control on the EV bus -- the old messages on the EV bus don't work, I haven't had a chance to try them on the CAR bus.
> Are you going to make new cables for the OBD2 port now or later? I can make one up for the Leaf and verify it works on all the buses. I haven't looked at what is on the Chademo bus, but watching the battery current and voltage reported on the EV bus as we currently do seems sufficient for knowing what is going on during DC Quick charging. Hence I feel we should supply a cable for the CAR and EV bus, leaving the 3rd bus for future expansion, for example to MitM a component by connecting it to the 3rd bus and having the OVMS gateway messages to the rest of the car, or the currently discussed OBD2 HUD or other dongle.
> Can anyone recommend a source of low profile OBD2 plugs or a low profile extension cord that includes all the pins? I have plugs that are too big for use while driving and low profile extension cords that don't pass through all the pins :(
>>> I hope there will be fewer bugs on the software side…
>> At least those can be fixed by over-the-air software update. I’m more worried about the bugs that need a soldering iron to squash.
> We'll have to think very carefully about security for the code upload -- being careful not to implement risky functionality is moot when you can upload new code. The PIC's Harvard architecture and out of heap stack also made it pretty safe in the face of memory corruption bugs. Is the esp32 a von Neumann architecture? Is the stack in the same address space as the rest of system ram? Can pages be marked read only or no execute?
> _______________________________________________
> OvmsDev mailing list
> OvmsDev at lists.teslaclub.hk
> http://lists.teslaclub.hk/mailman/listinfo/ovmsdev

More information about the OvmsDev mailing list