Bli medlem i Norsk elbilforening og støtt driften av Elbilforum. Som medlem får du i tillegg startpakke, medlemsfordeler og gode tips om elbil og lading. Du blir med i et fellesskap som jobber for mindre utslipp fra veitrafikken. Medlemskap koster 485 kroner per år. elbil.no/medlemskap

Sv: LEAF Manager - Android app til LEAF med klima-timerkontroll

Startet av BauDemo, onsdag 09. januar 2013, klokken 12:37

« forrige - neste »

hma

OVMS flashed with firmware v.2.3.2, installed temporarily in my Think.
Tested successful reading of SOC and GPS-position both in the OpenVehicle app and by SMS.

Next up is getting a C18 compiler running (for Mac), so I can edit the project and add some more parameters, like "chargestatus".
See attached screenshot of the iOS-app (image for Think-car is not yet available).
- Toyota Rav4 EV 2000 NiMH (06/2010), Tesla Model S75D (12/2018)
   (tidligere: Think Classic 2000 NiCd (06/2009-05/2012) - Think City 2010 Zebra (03/2012-10/2012) - Think City 2009 Zebra (05/2012-05/2014)  - Tesla Model S 2014 (06/2014-09/2017) - Nissan Leaf 2018 LE 40kWh (04/2018-12/2018) )
- Trondheim (Trøndelag Elbilforening 02/2012-04/2014)
- Ariens AMP 24 to-trinns snøfreser 48V litium 52,5Ahr (10/2012) - Bosch Rotaks 43 Li-Ion gressklipp

BauDemo

laddplats? -www.uppladdning.nu
nikometer? - www.evmonitor.info

habazot

Hi, I've just bought a Think City 2008 and are planning a series of "pimps" :)
This one looks interesting, so I'll join in on the development if possible, since I have some experience programming stuff like this. But first of all I have to order the HW..
I suspect I already have GSM/GPS antennas; what connectors do they use? Someone mentioned having found some converters, but I could not find any links..

Do we have any documentation on available parameters on the CAN bus?

On a possibly related side-note: are the parameters displayed in the trip counter (the ones enabled by holding it in while powering on) decoded and a reflection of what is available on the CAN bus?

(sorry for asking some stupid questions, still new to the CAN bus and it´s wonders..)
Bergen
- Think City 2008 - 43000km

hma

Great to hear that more people are joining :)
My purchaselist was:
- OVMS Car module V2 ($99 FastTech)
- PICKIT3 Programmer ($26 FastTech)
- OVMS Data Cable or similar DB9 ($9,5 FastTech) (I got two cables for some reason, so maybe there is one included with the OVMS module...?)
- SMA male to Fakra C male RG174 ($6)
http://www.ebay.com/itm/Fakra-SMB-C-5005-plug-to-SMA-male-6-RG174-pigtail-GPS-Telematics-Navigation-/320978360903?pt=LH_DefaultDomain_0&hash=item4abbcd1a47
- SMA male to Fakra D male RG174 ($6)
http://www.ebay.com/itm/Fakra-SMB-D-4004-male-plug-to-SMA-male-6-RG174-pigtail-cable-GSM-antenna-/320978361964?pt=LH_DefaultDomain_0&hash=item4abbcd1e6c
- SIM (SMS + gprs)

There are some info about the CAN-messages in the code (autorun.bas) for the new-Nikometer https://sites.google.com/site/theevmonitor/think-ev-monitor/download

Some hints in setting up the can for OVMS is setting up filters and masks for the specific messages you want to interrogate by the App or SMS.
I've made a simple testfile this evening, but have not compiled the project for testing in the ohms-unit. If successful I will publish here.
Looking forward to hear from your progress.
- Toyota Rav4 EV 2000 NiMH (06/2010), Tesla Model S75D (12/2018)
   (tidligere: Think Classic 2000 NiCd (06/2009-05/2012) - Think City 2010 Zebra (03/2012-10/2012) - Think City 2009 Zebra (05/2012-05/2014)  - Tesla Model S 2014 (06/2014-09/2017) - Nissan Leaf 2018 LE 40kWh (04/2018-12/2018) )
- Trondheim (Trøndelag Elbilforening 02/2012-04/2014)
- Ariens AMP 24 to-trinns snøfreser 48V litium 52,5Ahr (10/2012) - Bosch Rotaks 43 Li-Ion gressklipp

hma

Installed the C 18 compiler in addition to Mplab X IDE and compiled a experimental hex-file, only with changes in vehicle_thinkcity.c , but the ohms-unit behaves the same way. No new parameters in the SMS (I was only expecting the chargstatus to be set 'true'.)
I also discovered that both the official 2.3.2 fw and my own version is not updating SOC during charging.
To get updated SOC , I think the key have to be set on for a second...
However SOC is updating correct during driving/discharge.
- Toyota Rav4 EV 2000 NiMH (06/2010), Tesla Model S75D (12/2018)
   (tidligere: Think Classic 2000 NiCd (06/2009-05/2012) - Think City 2010 Zebra (03/2012-10/2012) - Think City 2009 Zebra (05/2012-05/2014)  - Tesla Model S 2014 (06/2014-09/2017) - Nissan Leaf 2018 LE 40kWh (04/2018-12/2018) )
- Trondheim (Trøndelag Elbilforening 02/2012-04/2014)
- Ariens AMP 24 to-trinns snøfreser 48V litium 52,5Ahr (10/2012) - Bosch Rotaks 43 Li-Ion gressklipp

BauDemo

I had similar problem with the SOC value not updating, and after about 50 SMS-es I gave up on the issue.
I think the correct SOC is reported on the CAN bus, but the OVMS is hanging or not updating the values. There was some talk about data structures being overwritten on the OVMS dev list, but I never got the time to investigate further.

You can confirm if this is correct by having both the OVMS and the new nikometer connected to the CAN bus and observe the SOC value on the new nikometer screen while using the OVMS function to read it.
laddplats? -www.uppladdning.nu
nikometer? - www.evmonitor.info

hma

#36
I'm checking the SOC-update during charging now with the new Nikometer installed :)

It looks like the OVMS-unit behaved the same way as the analog SOC-gauge, which also does not update before key is on.

Both the OVMS and the Duinomite are now powered +12V "always hot".
I started charging from 82% SOC, waited an hour and checked both by SMS/App and by the Nikometer, and now shows 89% all places. Then waited some extra time and interrogated by SMS/App and got 92% SOC. Very strange (it works as expected!).
I will do some more testing this evening, leaving the car unplugged and check if SOC decreases.

In the attached picture is my cable loom also used with the new Nikometer.
- Toyota Rav4 EV 2000 NiMH (06/2010), Tesla Model S75D (12/2018)
   (tidligere: Think Classic 2000 NiCd (06/2009-05/2012) - Think City 2010 Zebra (03/2012-10/2012) - Think City 2009 Zebra (05/2012-05/2014)  - Tesla Model S 2014 (06/2014-09/2017) - Nissan Leaf 2018 LE 40kWh (04/2018-12/2018) )
- Trondheim (Trøndelag Elbilforening 02/2012-04/2014)
- Ariens AMP 24 to-trinns snøfreser 48V litium 52,5Ahr (10/2012) - Bosch Rotaks 43 Li-Ion gressklipp

hma

#37
[edit]: Latest firmware (hex file) is from now kept in my last thread in this post!

The OVMS is now up and running both on SMS and on the App, presenting charging parameters (line voltage and current), SOC, Charge state, battery temperature and GPS location.

The hex file which I've made (OVMS-ThinkCity_13082013_v1-0_hex.txt) is attached and can be used of all.
Please rename the file before use to OVMS-ThinkCity_13082013_v1-0.hex
The version is only tested on Zebra-Think with gen1-PCU, but I might think it will work on all cars ...
You can flash is from any computer (Win, Linux and Mac) with free MPLAB X IDE.
You don't need to know much about programming to flash it to a ovms-unit.

The only two things you need to make sure of is:
1) "Preserve EEPROM memory" is checked (otherwise you need to give all SMS-commands every time you reprogram)
2) Make your programmer (PICKIT 2 or PICKIT3) supply +5V to the OVMS module.

Preserve EEPROM and set +5V:
1) Start MPLAB X IDE -> Run -> Set Project Configuration -> Customize
2) Click on your programmer, drop down "Option Categories" = "Memories to Program"
3) Check "Preserve EEPOROM memory" -> Apply
4) Click on your programmer, drop down "Option Categories" = "Power"
5) Check "Power target circuit from PIKkit" and chose Voltage level 5.0
6) Apply -> OK


To flash your OVMS unit:
1) Start MPLAB X IDE, click "File" and then "Import Hex (Prebuilt)  Project"
2) Prebuilt filename : browse to your hex.file (OVMS-ThinkCity_13082013_v1-0.hex)
3) Family: "Advanced 8-bit MCUs (PIC18)
4) Device: PIC18F2685
5) Hardware tool: "click on your programming device, e.g. PICkit3
6) Next -> Next -> Finish
7) Check that programming was finished successful.





To get it running, simply follow this manual (for Tesla Roadster) in detail, it works for all vehicles:
https://raw.github.com/markwj/Open-Vehicle-Monitoring-System/master/docs/OVMS_UserGuide_TeslaRoadster.pdf
I strongly recommend you to write down all users and passwords according do page 6 in the document


The SMS registration needed to configure are the following commands (this is explained in the manual above):
REGISTER OVMS
PASS "your_ovms_modul_password" (the passord is set in this command) e.g. PASS OvModSecret123
MODULE "your self made Vehicle ID" K - TC  (TC = Think City, K = Km) e.g. MODULE NO5001 K - TC
SERVER 64.111.70.40 "your Open Vehicle Password" -  e.g. SERVER 64.111.70.40 OvServSecret123 -
GPRS "apn" - - (apn can be telenor or netcom or whatever your provider have) e.g. GPRS telenor - -

You can check if the GPRS-settings are OK by sending
GPRS?


Good luck, and please report back if someone tries this! :)

/Håkon
- Toyota Rav4 EV 2000 NiMH (06/2010), Tesla Model S75D (12/2018)
   (tidligere: Think Classic 2000 NiCd (06/2009-05/2012) - Think City 2010 Zebra (03/2012-10/2012) - Think City 2009 Zebra (05/2012-05/2014)  - Tesla Model S 2014 (06/2014-09/2017) - Nissan Leaf 2018 LE 40kWh (04/2018-12/2018) )
- Trondheim (Trøndelag Elbilforening 02/2012-04/2014)
- Ariens AMP 24 to-trinns snøfreser 48V litium 52,5Ahr (10/2012) - Bosch Rotaks 43 Li-Ion gressklipp

habazot

Great!! I will try this out as soon as I get my car back and my gizmoz in the mail, possibly this weekend...

Have you committed the changes back to the OVMS site? I'd love to get the source and built it myself as well.

What are the next logical steps?
What is missing or needs be improved?

At some point we should update the resource files in the iOS and Android apps to show some nice pictures of the correct car :)
Bergen
- Think City 2008 - 43000km

hma

I have not found out (yet) how to contribute on the git-hub, so there you'll find the default code only (presents SOC on SMS and the App).

Make a Github-account, click on the url and use the "fork" button to make your local copy of the master project.
The project is called OVMS.X
https://github.com/thinkcity/Open-Vehicle-Monitoring-System/tree/master/vehicle/OVMS.X

I have made a minor change in the net_msg.c file to trim the SMS printout (in the function net_prep_stat).
This function checks if the car_doors1 bits are set, to determine if charge is ongoing.
This is a common file for all vehicles, so I cannot upload my version.

We should make a vehicle_thinkcity.c file which contain all SMS handeling, e.g. like in the vehicle_twizy.c

One lesson learned is that the global variables in ovms.h and ovms.c should not be changed.
The global variable car_tbattery is defined as 'signed char' in those files. When trying to send a 3-digit decimal number (unsigned int) to this variable, the temperature is presented incorrect, e.g. as 8 instead of 264.
My workaround is quick and dirty, simply by using the global variable 'car_trip', which is already defined as 'unsigned int'.

Further improvements would be:

- Adding car_thinkcity_red.png (and yellow, black and blue) to the App

- Adding more values to 'car_type', to distinguish between Zebra gen1 PCU, Zebra gen2 PCU and Enerdel gen2 PCU.

- Improving the handling of car_doors1 bit and 'charge enabled', so the SMS/App reflects correct charging state, for 80% 'top off' and 100% EOC detected - 'Charging Done'. I'm currently reading the 305 message and checking if bit 24 is set (charge enabled) ;  case 0x305: if ((can_databuffer[3] & 0x01) == 1)

- See if there is a way to correct transfer battery temperature to 'car_tbattery' and present it in the App.

- From the above; make one vehicle_thinkcity.c file, which contains can data-work and SMS/App interrogation, to be uploaded to Github :)
- Toyota Rav4 EV 2000 NiMH (06/2010), Tesla Model S75D (12/2018)
   (tidligere: Think Classic 2000 NiCd (06/2009-05/2012) - Think City 2010 Zebra (03/2012-10/2012) - Think City 2009 Zebra (05/2012-05/2014)  - Tesla Model S 2014 (06/2014-09/2017) - Nissan Leaf 2018 LE 40kWh (04/2018-12/2018) )
- Trondheim (Trøndelag Elbilforening 02/2012-04/2014)
- Ariens AMP 24 to-trinns snøfreser 48V litium 52,5Ahr (10/2012) - Bosch Rotaks 43 Li-Ion gressklipp

hma

#40
[edit]: Latest firmware (hex file) is from now kept in my last post!

Attached is an improved version (hex-file) for Think with Zebra (most parameters will also work on EnerDel).

In this version the charging state is reflected on SMS and on the App. When the car pauses at 80% SOC for OpenCircuitVoltage Measurement (30 mins), you can see "Charging, top off" and 230V/0A.

Still I have to make changes to more files than the vehicle_thinkcity.c , so it make no sense of publishing the source code on Github.

Remember to rename the file to OVMS-ThinkCity_Zebra_14082013_v1-1.hex
- Toyota Rav4 EV 2000 NiMH (06/2010), Tesla Model S75D (12/2018)
   (tidligere: Think Classic 2000 NiCd (06/2009-05/2012) - Think City 2010 Zebra (03/2012-10/2012) - Think City 2009 Zebra (05/2012-05/2014)  - Tesla Model S 2014 (06/2014-09/2017) - Nissan Leaf 2018 LE 40kWh (04/2018-12/2018) )
- Trondheim (Trøndelag Elbilforening 02/2012-04/2014)
- Ariens AMP 24 to-trinns snøfreser 48V litium 52,5Ahr (10/2012) - Bosch Rotaks 43 Li-Ion gressklipp

hma

#41
Latest fw (hex file) is attached here.

Changes:
- Chargelimit is displayed in the App (over the battery symbol during charging)
- PCU temperature is displayed in the "Car" section of the App as "PEM" (please ignore battery and motor temp in the App)
- Correct state detection at EndOfCharge. Charge symbol is present at EOC until charge connector is unplugged.

Any feedback is welcome :)

/Håkon
- Toyota Rav4 EV 2000 NiMH (06/2010), Tesla Model S75D (12/2018)
   (tidligere: Think Classic 2000 NiCd (06/2009-05/2012) - Think City 2010 Zebra (03/2012-10/2012) - Think City 2009 Zebra (05/2012-05/2014)  - Tesla Model S 2014 (06/2014-09/2017) - Nissan Leaf 2018 LE 40kWh (04/2018-12/2018) )
- Trondheim (Trøndelag Elbilforening 02/2012-04/2014)
- Ariens AMP 24 to-trinns snøfreser 48V litium 52,5Ahr (10/2012) - Bosch Rotaks 43 Li-Ion gressklipp

habazot

Ooh, great! Still waiting for my hw, shipment got stuck, restocking, bla bla..
Will at least get my car back tomorrow, and will experiment a bit with CAN dumping through other means while waiting. Will also see if I can get my RaspberryPi to talk CAN.
I have checked out the git fork you created, maybe time to commit the changes back.?.
Or send a zip file of the source, does not make sense to start from scratch when you have done so much nice work already..
I have also started gathering promo pictures (top and front/side) which can be used in the apps, still missing a few color options, but will get there eventually... Or maybe someone has a complete set (examples attached)?
Anyone experimented with HUD type displays btw? Considering a 7" HUD connected to my PI..
Bergen
- Think City 2008 - 43000km

hma

Looks like Mark Webb-Johnson already have managed to merge my source files to the project public (after a few changes), great - thanks! :)

I have not compiled it but will do so and test it as soon as possible.

He also gave some comments regarding SMS STAT which i quote here:

Regarding the SMS STAT message, and how to extend it, the correct way is via the vehicle_fn_smshandler hook. You can see vehicle_twizy.c for an example of how to implement this.

Given that the standard net_sms_stat does this:

    BOOL net_sms_stat(char* number)
      {
      char *p;

      if (sys_features[FEATURE_CARBITS]&FEATURE_CB_SOUT_SMS) return FALSE;

      delay100(2);
      net_send_sms_start(number);
      net_prep_stat(net_scratchpad);
      cr2lf(net_scratchpad);
      net_puts_ram(net_scratchpad);

      return TRUE;
      }

you should be able to replace it with your own thinkcity_sms_stat that does the same, but adds your own private data to the end of the standard SMS STAT response. You will need to provide a hook function (see vehicle_twizy for an example) to hook in and handle this in your vehicle_thinkcity module.


- Toyota Rav4 EV 2000 NiMH (06/2010), Tesla Model S75D (12/2018)
   (tidligere: Think Classic 2000 NiCd (06/2009-05/2012) - Think City 2010 Zebra (03/2012-10/2012) - Think City 2009 Zebra (05/2012-05/2014)  - Tesla Model S 2014 (06/2014-09/2017) - Nissan Leaf 2018 LE 40kWh (04/2018-12/2018) )
- Trondheim (Trøndelag Elbilforening 02/2012-04/2014)
- Ariens AMP 24 to-trinns snøfreser 48V litium 52,5Ahr (10/2012) - Bosch Rotaks 43 Li-Ion gressklipp

hma

#44
I've also made images in the correct size:
- Car front angle view 654x302  car_thinkcity_color.png
- Car x-ray view  304x606 ol_car_thinkcity_classicblack.png (black only)
- Car map images 96x96 map_car_thinkcity_classicblack.png (black only)

It remains making the background transparent on all images.
Anyone with PhotoShop?
- Toyota Rav4 EV 2000 NiMH (06/2010), Tesla Model S75D (12/2018)
   (tidligere: Think Classic 2000 NiCd (06/2009-05/2012) - Think City 2010 Zebra (03/2012-10/2012) - Think City 2009 Zebra (05/2012-05/2014)  - Tesla Model S 2014 (06/2014-09/2017) - Nissan Leaf 2018 LE 40kWh (04/2018-12/2018) )
- Trondheim (Trøndelag Elbilforening 02/2012-04/2014)
- Ariens AMP 24 to-trinns snøfreser 48V litium 52,5Ahr (10/2012) - Bosch Rotaks 43 Li-Ion gressklipp

© 2024, Norsk elbilforening   |   Personvern, vilkår og informasjonskapsler (cookies)   |   Organisasjonsnummer: 982 352 428 MVA