<html><head></head><body bgcolor="#FFFFFF"><div>I agree.  Losing the last charge data will not be that big a deal.  Under normal circumstances when you unplug and close the charge port door you are at the car and can look at the VDS charge history right?  Only if someone is messing with your car and you want to check remotely might this be a issue.  I say carry on with the fix to SMS STAT.</div><div><br></div><div>Jack<br><br>On Feb 26, 2012, at 1:21 AM, Sonny <<a href="mailto:email@sonnychen.com">email@sonnychen.com</a>> wrote:<br><br></div><div></div><blockquote type="cite"><div><p>Mark,</p>
<p>Great find.</p>
<p>I like the determine-by-charge-port-status method. Coincidentally, the Android app has already been doing it that way.</p>
<p>Best regards,</p>
<p>Sonny</p>
<div class="gmail_quote">On Feb 25, 2012 10:51 PM, "Mark Webb-Johnson" <<a href="mailto:mark@webb-johnson.net">mark@webb-johnson.net</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word"><div><br></div>I think I now understand what is happening.<div><br></div><div>The 0x95 message is the charge status for the current charge. For a normal charge in progress, that is fine. When the charge completes, the charge door is closed, and we are still ok. We still show the last charge status.</div>
<div><br></div><div>Now, the opening of the charge door signals the car to start a new charge, and the old data is lost. Hence 'preparing to charge'. Even closing the charge door leaves the charge status as 'preparing to charge'. That was the last charge status.</div>
<div><br></div><div>For the SMS STAT command, I think we're going to have to deal with this by if the car charge port is closed, then not showing any charge in progress (as opposed to the last charge status that we currently show).</div>
<div><br></div><div>From the App point of view, if the charge port door is closed, then we also won't show any current charge status</div><div><br></div><div>What we lose here is the status of the last charge, once the charge port is closed. But, perhaps that is the best way of doing things.</div>
<div><br></div><div>Thoughts?</div><div><br></div><div>Regards, Mark.</div><div><br></div><div><div><div><div>On 25 Feb, 2012, at 11:51 AM, Mark Webb-Johnson wrote:</div><br><blockquote type="cite"><div style="word-wrap:break-word">
<div><br></div><div>I'm seeing something strange, that I'd like to know if it is repeatable for others. I previously thought this was some sequence problem with the messages we were sending (specifically, sending a start charge command when the charge port is closed or cable not plugged in), but I can now repeat it with just a normal idle car.</div>
<div><br></div><div>Steps to reproduce:</div><div><br></div><div><ol><li>Charge the car as normal, and wait for "Charge done".</li><li>Remove the charge plug+cable and close the charge port door.</li><li>SMS STAT the car and you should get "Standard - Charging done" as the status. All good.</li>
<li>Now, with the car still off, open the charge port door, wait a few seconds, then close it.</li><li>SMS STAT the car and now we seem to get "Standard - Charging, Preparing". A check on the can bus shows charge state 13, sub-state 7 (preparing-to-charge, connect-pwr-cable). The iPhone App will show the battery with copper-coloured tops, as it seems to be expecting the car to be charging.</li>
</ol></div><div><br></div><div>This doesn't seem to happen with a car in 'stopped charge' state. The VDS shows nothing unusual (which implies that Tesla treat it specially, based on the charge door status).</div>
<div><br></div><div>Can some other people try this, and let me know what you get? If you can have an App connected at the time of your test (so the server gets the logs), then let me know your vehicle ID, the time you did the test and what the result was, that would be helpful.</div>
<div><br></div><div>It is not hard to handle as a special case in the code (both firmware and apps, or hacked in the firmware to detect the issue and put the state back to something more meaningful), but just seems a bit strange, as the state does not accurately reflect the car status.</div>
<div><br></div><div>Regards, Mark.</div><div><br></div></div>_______________________________________________<br>OvmsDev mailing list<br><a href="mailto:OvmsDev@lists.teslaclub.hk" target="_blank">OvmsDev@lists.teslaclub.hk</a><br>
<a href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev" target="_blank">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a><br></blockquote></div><br></div></div></div><br>_______________________________________________<br>

OvmsDev mailing list<br>
<a href="mailto:OvmsDev@lists.teslaclub.hk">OvmsDev@lists.teslaclub.hk</a><br>
<a href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev" target="_blank">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a><br>
<br></blockquote></div>
</div></blockquote><blockquote type="cite"><div><span>_______________________________________________</span><br><span>OvmsDev mailing list</span><br><span><a href="mailto:OvmsDev@lists.teslaclub.hk">OvmsDev@lists.teslaclub.hk</a></span><br><span><a href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a></span><br></div></blockquote></body></html>