<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><br></div><div>OK. I've just committed v2.5.3 and pushed to github. I've also tagged it (as v2.5.3) and upload pre-built .hex files in the vehicle/firmware directory.</div><div><br></div><div>Short story: v2.5.3 is unlikely to blow up your car, but has probably got lots of bugs, and I need your help testing to find those bugs and fix them.</div><div><br></div><div>Big caveat: this is testing code, please don't use ACC if you _really_ need that charge to get to work / school / the beach / wherever. Don't blame me if your car doesn't start the charge as scheduled.</div><div><br></div><div>Warning: this is a long mail.</div><div><br></div><div>Firstly, the v2.5.x change log:</div><div><br></div><div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;"><div><div><font face="Andale Mono">2013-09-18 2.5.3 Firmware 2.5.3</font></div><div><font face="Andale Mono"> ## Updates to thinkcity</font></div><div><font face="Andale Mono"> ## Remove DIAG and add ACC to V1_Production build config</font></div><div><font face="Andale Mono"> ## Remove InternalGPS from V2_TR_Production build config, as not required</font></div><div><font face="Andale Mono"> ## Cooldown: safety check (only recycle if charging), and revise cooldown current to 13A</font></div><div><font face="Andale Mono"> ## Support definition of location in SMS commands</font></div><div><font face="Andale Mono"> ## Tesla Roadster: HVAC#1 should be 0x8F not 0x87</font></div><div><font face="Andale Mono"> ## Logging: Don't reserve a log slot if the respective logging option is disabled</font></div><div><font face="Andale Mono"> ## Improve cooldown status reporting on SMS STAT</font></div><div><font face="Andale Mono"> ## Tidy-up of minSOC</font></div><div><font face="Andale Mono"> ## Move chargelimit charge stop to common vehicle.c function (not acc)</font></div><div><font face="Andale Mono"> ## Tesla Roadster: Updates to Tom's charge-time-predictor, with thanks</font></div><div><font face="Andale Mono"> ## Log cooldown charges as mode=5, and fix excessive-logging-bug related to cooldown cycles</font></div><div><font face="Andale Mono"> ## Logging: Send log messages one-by-one, to avoid buffer overflows</font></div><div><font face="Andale Mono"> ## ACC: Number homelinks from 1..3</font></div><div><font face="Andale Mono"> ## Tesla Roadster: support for chargelimits</font></div><div><font face="Andale Mono"> ## Make SMS "RESET" reset the module completely</font></div><div><font face="Andale Mono"> ## Complete rework and expansion of checkpoint numbers</font></div><div><font face="Andale Mono"> ## Stop charge after cooldown, if no subsequent charge requested</font></div><div><font face="Andale Mono"> ## Report CAC as part of charge log record</font></div><div><font face="Andale Mono"> ## Typos in acc for net_state_enter</font></div><div><font face="Andale Mono"> ## Show debug checkpoint, for DIAG SMS with debugcrash</font></div><div><font face="Andale Mono"> ## Support vehicle_fn_minutestocharge</font></div><div><font face="Andale Mono"> ## Add a timezone parameter (-)HH:MM</font></div><div><font face="Andale Mono"> ## ACC: Support timed charges</font></div><div><font face="Andale Mono"> ## Move car_cooldown_wascharging to global, and make use of it in ACC</font></div><div><font face="Andale Mono"> ## Introduce some delays to allow car to wake up</font></div><div><font face="Andale Mono"><br></font></div><div><font face="Andale Mono">2013-08-27 2.5.2 Firmware 2.5.2</font></div><div><font face="Andale Mono"> ## Updates to vehicle_thinkcity.c (getting to a pretty usable vehicle module)</font></div><div><font face="Andale Mono"> ## Make car_tbattery signed integer, and integrate thinkcity changes</font></div><div><font face="Andale Mono"> ## Only report range and soc limits if >0</font></div><div><font face="Andale Mono"> ## Merge thinkcity changes: Think City AC-line voltage/current in SMS STAT SMS migrated from standard handler to vehicle_thinkcity.c</font></div><div><font face="Andale Mono"> ## Tesla Roadster: Don't stop charge after cooldown, if previously the car was already charging</font></div><div><font face="Andale Mono"> ## Log cooldown charges that become normal charges as two separate charges</font></div><div><font face="Andale Mono"> ## Tidy up diag, by removing temp test code T1 T2 T3</font></div><div><font face="Andale Mono"> ## Create individual configs for TeslaRoadster and RenaultTwizy (to allow all features for these cars)</font></div><div><font face="Andale Mono"> ## Add TRACK (type XX) vehicle that just tracks GPS</font></div><div><font face="Andale Mono"> ## string_to_mode utility function</font></div><div><font face="Andale Mono"> ## Rework vehicle inclusions. Tesla Roadster, Renault Twizy and Volt/Ampera are production. Everything else is experimental</font></div><div><font face="Andale Mono"> ## Add experimental vehicle Kyburz DXP</font></div><div><font face="Andale Mono"> ## Add HVAC message details</font></div><div><font face="Andale Mono"> ## Support HVAC bit in car_doors5, and cooldown cycles</font></div><div><font face="Andale Mono"> ## Range and charge limits handled by ACC</font></div><div><font face="Andale Mono"> ## Basic ACC implementation, but without timed charges</font></div><div><font face="Andale Mono"><br></font></div><div><font face="Andale Mono">2013-08-16 2.5.1 Firmware 2.5.1</font></div><div><font face="Andale Mono"> ## Framework to build logging module in experimental modes</font></div><div><font face="Andale Mono"> ## FIsLatLongClose utiliy function (courtesy of Tom Saxton)</font></div><div><font face="Andale Mono"> ## Twizy: Mi/Km conversions updated to new functions</font></div><div><font face="Andale Mono"> ## Switch to use macros, for clarity and maintainability</font></div><div><font face="Andale Mono"> ## ACC integration to build environment</font></div><div><font face="Andale Mono"> ## Parameter support for base64 encoded parameters</font></div><div><font face="Andale Mono"> ## utils support for mode display</font></div><div><font face="Andale Mono"> ## ACC support for net_sms</font></div><div><font face="Andale Mono"> ## Switch logging system to use new "h" historical data submission, with acknowledgement</font></div><div><font face="Andale Mono"> ## Go from 4->6 log records, based on free space</font></div><div><font face="Andale Mono"> ## Tesla Roadster: Notify server if charge limit is changed</font></div><div><font face="Andale Mono"> ## Tesla Roadster: Notify server if charge mode is changed</font></div><div><font face="Andale Mono"> ## v2.5.1 protocol guide</font></div><div><font face="Andale Mono"> ## Add core support for cooldown</font></div><div><font face="Andale Mono"> ## Tesla Roadster support for cooldown</font></div><div><font face="Andale Mono"> ## Stub implementation, with basic functionality, for ACC</font></div><div><font face="Andale Mono"> ## Zero logging records on init, plus other safety checks</font></div><div><font face="Andale Mono"> ## Only initialise logging on a normal power up</font></div><div><font face="Andale Mono"> ## Standardise 3 diag tests: T1, T2 and T3</font></div><div><font face="Andale Mono"> ## Only send logging msgs if link is connected</font></div><div><font face="Andale Mono"> ## Fix logging prefix and some logging tests</font></div><div><font face="Andale Mono"> ## Revisions to CAR_IS_CHARGING logic</font></div><div><font face="Andale Mono"> ## Misc bug-fixes for logging</font></div><div><font face="Andale Mono"> ## Report distance in miles (rather than 10ths of miles)</font></div><div><font face="Andale Mono"> ## Remove dr++ and cr++ sequence numbers, as not required</font></div><div><font face="Andale Mono"> ## Make ACC commands case insensitive</font></div><div><font face="Andale Mono"> ## Fix bug acknowledging log record #0</font></div><div><font face="Andale Mono"> ## Move digital speedo feature (Tesla Roadster) from experimental to fully supported, and implement opt-in feature bits</font></div><div><font face="Andale Mono"> ## Honour opt-in flags for logging</font></div><div><font face="Andale Mono"> ## Only report debug crash reason if not normal power up, and only report once</font></div></div></blockquote></div><div><br></div><div>As you can see, a lot has changed. The key points are:</div><div><br></div><div><ul class="MailOutline"><li>Some restructuring of the build targets:</li><ul><li><div><font face="Andale Mono">V1_production.hex V1 Hardware Module, production firmware</font></div></li><li><font face="Andale Mono">V2_experimental.hex V2 Hardware Module, experimental firmware</font></li><li><font face="Andale Mono">V2_production.hex V2 Hardware Module, production firmware</font></li><li><font face="Andale Mono">V2_RT_production.hex V2 Hardware Module, Renault Twizy full firmware</font></li><li><font face="Andale Mono">V2_TR_production.hex V2 Hardware Module, Tesla Roadster full firmware</font></li></ul><li>Support for LOGGING (charge and drive)</li><li>Support for ACC (Advanced Charge Control) - Tesla Roadster only at the moment</li><li>Lots of other little nice fixes and enhancements</li></ul></div><div><br></div><div>Apart from overall reliability testing (making sure it is stable in the cars), the two things I need help with are the LOGGING and ACC functions.</div><div><br></div><div><u><b>[1] Logging</b></u></div><div><br></div><div>The logging code is enabled by setting opt-in feature (#13) bit 1 (to log drives) and/or bit 2 (to log charges). Or, you can just set feature #13 to 255 and opt-in to everything :-)</div><div><br></div><div>Once you've opted in, whenever you complete a charge or drive, the car will submit a summary record to be stored on the server. You can then use the prototype HTTP API, or perl client, to retrieve those records for your own purposes.</div><div><br></div><div>Note that there is a privacy concern here, as both record types (drive and charge) store GPS locations - this is the reason why it is opt-in.</div><div><br></div><div>The testing I need done is just to ensure that this works for you, and that the resulting logged drives/charges match what you are expecting. It would also be useful to confirm if this works on all supported cars (which it should).</div><div><br></div><div><u><b>[2] Advanced Charge Control</b></u></div><div><br></div><div>The Advanced Charge Control system is designed to supplement the (aka take over from) vehicle's own charge scheduling. It should support any vehicle with charge control, but at the moment that means only Tesla Roadster. It has some pretty sophisticated features. For the moment, it is setup via SMS, but in future we will allow smartphone Apps to do this. Once setup, it runs autonomously, and doesn't even require a cellular connection.</div><div><br></div><div>ACC works from the concept of a 'charge location'. This is a geofenced location that is used for charging, and you can configure up to 4 of these (numbered #1 through #4). To define the car's current location as a 'charge location', sms "ACC HERE" to the car, and it will allocate a free slot and reply to you with it. You can use "ACC NOTHERE" to clear the current location.</div><div><br></div><div>If you want to clear a particular ACC location, you can sms "ACC CLEAR n" (to clear one location), or "ACC CLEAR" (to clear all locations).</div><div><br></div><div>You can show the ACC details for the current location by sms "ACC STAT" (or for a particular location by "ACC STAT n" - which is very useful if you have crappy cellular connectivity like I do).</div><div><br></div><div>The ACC parameters for a particular location are configured with the "ACC PARAMS" SMS. You can list a location number (1, 2, 3 or 4) as the first parameter - or don't specify location if you just want to configure the current location the car is at. After 'ACC PARAMS", you can set the parameters you would like, from the following:</div><div><br></div><div><ul class="MailOutline"><li>COOLDOWN - perform a cooldown charge (13A range mode, with cooling cycles) when the car is plugged in at this ACC location</li><li>NOCOOLDOWN - don't do a cooldown charge (default)</li><li>HOMELINK n - activate homelink when the vehicle drives to within 100m of an ACC location (the idea is to open our garage door / gate automatically as you approach)</li><li>NOHOMELINK - don't activate homelink (default)</li><li>CHARGEPLUGIN - charge the car on plugin (but after cooldown, if enabled)</li><li>CHARGEAT HH:MM - schedule charge to start at the specified time (hours:minutes, 24hour clock)</li><li>CHARGEBY HH:MM - schedule charge to complete by the specified time (hours:minutes 24hour clock)</li><li>NOCHARGE - don't charge (default)</li><li>LIMIT n - limit charge current to n Amps - must be specified for all CHARGE* actions</li><li>MODE m - set charge mode (where "m" is STA(NDARD), STO(RAGE), RAN(GE) or PER(FORMANCE)) - must be specified for all CHARGE* actions</li><li>STOPRANGE r - stop charge when range "r" is reached (specified in vehicle units, set to 0 (default) to not limit).</li><li>STOPSOC s - stop charge when SOC "s" is reached (specified as a percentage, set to 0 (default) to not limit).</li></ul></div><div><br></div><div>The actions to take at a particular ACC location must be enabled with "ACC ENABLE" (or "ACC ENABLE n") before they will work. You can also disable with "ACC DISABLE" (or "ACC DISABLE n").</div><div><br></div><div>If you are using CHARGEAT or CHARGEBY, you need to specify the timezone of the vehicle. This is parameter #23 and is specified as HH:MM offset from GmT (with an optional leading "-" if west of Greenwich).</div><div><br></div><div>The default temperature limit for cooldown is 31Celcius, and time limit is 60 minutes. If you want to change these, you can set parameter #15 to templimit:timelimit (e.g.; "31:60").</div><div><br></div><div>Note that you can also cooldown manually, while charging, with the SMS command "COOLDOWN", and see the status with SMS "STAT".</div><div><br></div><div>I've spent quite some time testing CHARGEPLUGIN, COOLDOWN, LIMIT, MODE, STOPRANGE and STOPSOC - hopefully those are ok now, but the control logic does need wider testing. I've spent almost no time testing CHARGEAT and CHARGEBY. I've also been unable to test HOMELINK and would be very interested to see if that works.</div><div><br></div><div><u><b>Some notes on cooldown on Tesla Roadster</b></u></div><div><br></div><div>The cooldown algorithm is to start a range mode charge at 13Amps, and to monitor the HVAC system of the car. Once the HVAC starts, runs for some time, then stops, we call it a 'cooling cycle'. We keep a record of how many such cycles have occurred.</div><div><br></div><div>Once we detect that the HVAC has stopped, we try to start it again. The logic at the moment is to switch to performance mode for ten seconds, then back to range mode, once every minute until the HVAC starts again. The _best_ way of starting the HVAC is to stop and start the charge, but that is painful on the contactors, so we don't do it. Switching Range->Performance->Range seems to be the second best, but I remain unconvinced that it makes much difference. In Hong Kong summer weather, I get one cooldown cycle every ten minutes or so. I can drop 6 to 8 celcius in one hour.</div><div><br></div><div>The cooldown will stop after either the desired temperature is hit (based on the temperature of the hottest brick in the battery) or the cooldown has been ongoing for the time limit.</div><div><br></div><div><u><b>Conclusions</b></u></div><div><br></div><div>I'm happy that the code is reasonably stable now, but really need help testing this in a larger number of cars. If you do see a problem, please get me (by eMail to OVMS developers mailing list, or my personal address):</div><div><br></div><div><ul class="MailOutline"><li>Output of "SMS STAT" for the specified location</li><li>Your vehicle id</li><li>Output of base64 parameter string (from the cellphone app) - copy-and-paste</li><li>Date/Time you entered the ACC location (with timezone)</li><li>Date/Time you plugged in at the ACC location (with timezone)</li><li>In the smartphone app, call up the Features and Parameters screens (so the server logs those, and I can check)</li><li>Description of the problem you have</li></ul></div><div><br></div><div>Please also share success stories. It is good to know what works.</div><div><br></div><div>Regards, Mark.</div><div><br></div></body></html>