<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Mark,<br>
<br>
I do already support doors1 bit 7. Not bit 6 as it is labeled "hand
brake applied", and not the parking time as I thought that needs to
be a time value, not a simple second count. I'll try to add support
for these.<br>
<br>
So the App logic is only using the state of bit7 and the "parking"
info itself is correct then -- I just wasn't used to it, as the old
App never displayed it.<br>
<br>
Strange remains it showed a parking time a few times, but it hasn't
done so in a while and I can't remember any special condition that
might have caused this.<br>
<br>
Regards,<br>
Michael<br>
<br>
<br>
<div class="moz-cite-prefix">Am 30.01.2013 01:29, schrieb Mark
Webb-Johnson:<br>
</div>
<blockquote
cite="mid:E16B2407-12C8-4AE3-BD3C-43B9E45B91BF@webb-johnson.net"
type="cite">Michael,
<div><br>
</div>
<div>
<blockquote type="cite">
<div bgcolor="#FFFFFF" text="#000000">my parktime is always 0,
as I currently have no parking detection, but the App shows
it as parking.</div>
</blockquote>
<blockquote type="cite">
<div bgcolor="#FFFFFF" text="#000000">It shows "just now" most
of the time (also right now), but I also saw some "x
minutes" displays there. doors1 bit7 is set correctly by the
Twizy.<br>
</div>
</blockquote>
<br>
</div>
<div>I think the best way is for you to add support for car_doors1
[bit 7] and [bit 6] (the 'car on' and 'park' bits).</div>
<div><br>
</div>
<div>Because your firmware is always saying 'car off' (car_doors1
[bit 7] unset), the apps will think it is parked. And, as the
parking timer is not coded, the apps will also think 'parked
just now'.</div>
<div><br>
</div>
<div>The Apps don't use parktime to determine whether the car is
parked or not, they use car_doors1 [bit 7] (whether the car is
ON of OFF).</div>
<div><br>
</div>
<div>
<blockquote type="cite">
<div bgcolor="#FFFFFF" text="#000000">The USSD code entry only
allows digits, at least "*" and "#" also need to be allowed.<br>
</div>
</blockquote>
</div>
<div><br>
</div>
<div>OK.</div>
<div><br>
</div>
<div>Regards, Mark.</div>
<div><br>
</div>
<div>
<div>
<div>On 30 Jan, 2013, at 12:10 AM, Michael Balzer wrote:</div>
<br class="Apple-interchange-newline">
<blockquote type="cite">
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
<div bgcolor="#FFFFFF" text="#000000"> Mark,<br>
<br>
my parktime is always 0, as I currently have no parking
detection, but the App shows it as parking. It shows "just
now" most of the time (also right now), but I also saw
some "x minutes" displays there. doors1 bit7 is set
correctly by the Twizy.<br>
<br>
I found the joystick now, that could have passed as a
"hidden" feature ;-)<br>
The USSD code entry only allows digits, at least "*" and
"#" also need to be allowed.<br>
<br>
Regards,<br>
Michael<br>
<br>
<br>
<br>
<div class="moz-cite-prefix">Am 29.01.2013 02:37, schrieb
Mark Webb-Johnson:<br>
</div>
<blockquote
cite="mid:81AF1945-72D4-445D-BEB6-BEC392702499@webb-johnson.net"
type="cite">
<div><br>
</div>
<div>
<blockquote type="cite">
<div>- constantly shows "parking", although the
Twizy does not feed the parking timer<br>
</div>
</blockquote>
</div>
<div><br>
</div>
<div>I just tested on my Roadster, with both Android and
iOS Apps, and this seems to work as it should (for
me).</div>
<div><br>
</div>
<div>The logic in the Apps is that the car is parked if
"!carstarted and parktime>0".</div>
<div><br>
</div>
<div>Carstarted is:</div>
<div>
<div class="column">
<ul style="list-style-type: disc">
<li style="font-size: 12.000000pt; font-family:
'Symbol'">
<p><span style="font-size: 12.000000pt;
font-family: 'Helvetica'">unsigned char
car_doors1 [bit 7] </span></p>
<p><span style="font-size: 12.000000pt;
font-family: 'Helvetica'">A bit used to
signal whether the car is turned on or off.
Set to 1 if the car ignition switch is ON,
otherwise 0. </span></p>
</li>
</ul>
</div>
</div>
<div><br>
</div>
<div>There is a little bit of code in the
vehicle_voltampera to handle the parking timer. As we
don't know the 'car on' signal for the Volt/Ampera,
yet, we just use the gear selector PARK.</div>
<div><br>
</div>
<blockquote class="webkit-indent-blockquote"
style="margin: 0 0 0 40px; border: none; padding:
0px;">
<div>
<div> else if ((CANctrl & 0x07) == 5) //
Acceptance Filter 5 (RXF5) = CAN ID 135</div>
<div> {</div>
<div> if (can_databuffer[0] == 0)</div>
<div> { // Car is in PARK</div>
<div> car_doors1 |= 0x40; // NOT PARK</div>
<div> car_doors1 &= ~0x80; // CAR OFF</div>
<div> if (car_parktime == 0)</div>
<div> {</div>
<div> car_parktime = car_time-1; // Record
it as 1 second ago, so non zero report</div>
<div> net_req_notification(NET_NOTIFY_ENV);</div>
<div> }</div>
<div> }</div>
<div> else</div>
<div> { // Car is not in PARK</div>
<div> car_doors1 &= ~0x40; // PARK</div>
<div> car_doors1 |= 0x80; // CAR ON</div>
<div> if (car_parktime != 0)</div>
<div> {</div>
<div> car_parktime = 0; // No longer parking</div>
<div> net_req_notification(NET_NOTIFY_ENV);</div>
<div> }</div>
<div> }</div>
</div>
</blockquote>
<div><br>
</div>
<div>Also, initialise car_time to zero, and increment it
in the vehicle ticker1().</div>
<div><br>
</div>
<div>
<blockquote type="cite">
<div>
<blockquote type="cite">...as well as all the new
function and parameter settings.<br>
</blockquote>
I haven't seen a function call / parameter setup
utility -- is that a hidden feature, or no UI yet,
or a bug on my device?<br>
</div>
</blockquote>
</div>
<div><br>
</div>
The icon is not ideal at the moment. Go to settings,
then the little pencil icon to go to the car settings,
then press the icon that looks like a joystick in the
top right. That is the control menu. From there, we have
Features and Parameters.
<div><br>
</div>
<div>Regards, Mark.</div>
<div><br>
<div>
<div>On 24 Jan, 2013, at 10:29 PM, Michael Balzer
wrote:</div>
<br class="Apple-interchange-newline">
<blockquote type="cite">
<div>Mark,<br>
<br>
a short report for my HTC Desire HD / Android
2.3.5:<br>
</div>
</blockquote>
</div>
<br>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
OvmsDev mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:OvmsDev@lists.teslaclub.hk">OvmsDev@lists.teslaclub.hk</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a>
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Michael Balzer * Paradestr. 8 * D-42107 Wuppertal
Fon 0202 / 272 2201 * Handy 0176 / 206 989 26
</pre>
</div>
<span><dexter.vcf></span>_______________________________________________<br>
OvmsDev mailing list<br>
<a moz-do-not-send="true"
href="mailto:OvmsDev@lists.teslaclub.hk">OvmsDev@lists.teslaclub.hk</a><br>
<a class="moz-txt-link-freetext" href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a><br>
</blockquote>
</div>
<br>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
OvmsDev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:OvmsDev@lists.teslaclub.hk">OvmsDev@lists.teslaclub.hk</a>
<a class="moz-txt-link-freetext" href="http://lists.teslaclub.hk/mailman/listinfo/ovmsdev">http://lists.teslaclub.hk/mailman/listinfo/ovmsdev</a>
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Michael Balzer * Paradestr. 8 * D-42107 Wuppertal
Fon 0202 / 272 2201 * Handy 0176 / 206 989 26
</pre>
</body>
</html>