<br><div class="gmail_quote">On Mon, Aug 31, 2009 at 11:06 PM, Doug Turner <span dir="ltr"><<a href="mailto:doug.turner@gmail.com">doug.turner@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div style="word-wrap: break-word;">Thanks Dave for your comments.<div><br></div><div>I was thinking about update frequency.  right now, it is up to the UA (we are using 50ms).</div></div></blockquote><div><br>To give an explicit example, if you want to run a high pass (say to detect only sudden movements), you might code a simple k-order FIR filter of the form:<br>
<br>   y[n] = b0.x[n] + b1.x[n-1] + ... +  bk.x[n-k]<br><br>The coefficient values b0 ... bk are a function of the sampling rate ("update frequency") and hence needs to be settable or at least known to allow code portability.<br>
<br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div style="word-wrap: break-word;"><div><br></div><div>units -- yes.  in g.  This is best.</div>
<div><br></div><div>magnetometer -- but in a different API, right?  I do not see directly how you would combined the two.</div></div></blockquote><div><br>It's a different API, but (can be) closely related. You can present magnetometer information either as x, y, z of the magnetic field vector or as the special case of compass orientation. For example, Android has the same <a href="http://developer.android.com/reference/android/hardware/SensorEvent.html">SensorEvent</a> for both Sensor.TYPE_ACCELEROMETER and Sensor.TYPE_MAGNETIC_FIELD. Lots of interesting use-cases for compass ranging from map tile orientation, navigation, augmented reality, etc.<br>
<br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div style="word-wrap: break-word;"><div><div><br></div><div>Also see: <a href="http://dougt.org/wordpress/2009/08/orientation-update/" target="_blank">http://dougt.org/wordpress/2009/08/orientation-update/</a> for some demos.</div>
<div><br></div><font color="#888888"><div>Doug</div></font><div><div></div><div class="h5"><div><br><div><div>On Aug 31, 2009, at 2:54 PM, Dave Burke wrote:</div><br><blockquote type="cite">+1, I like this approach for its simplicity and familiarity. <br>
<br>As part of fleshing out, there are probably a few small but key additions that would greatly increase effectiveness:<br>  - update frequency (knowing the sample rate is crucial for even the most trivial DSP operations such as filtering)<br>
   - units (convention is in units of 'g', i.e 9.81 m/s^2)<br>  - magnetometer in addition to accelerometer (for heading)<br><br>Dave<br><br><div class="gmail_quote">On Mon, Aug 24, 2009 at 4:39 AM, Doug Turner <span dir="ltr"><<a href="mailto:doug.turner@gmail.com" target="_blank">doug.turner@gmail.com</a>></span> wrote:<br>
 <blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">I posted some thoughts and a strawman for orientation in Firefox:<br> <br> <a href="http://dougt.org/wordpress/2009/08/orientation/" target="_blank">http://dougt.org/wordpress/2009/08/orientation/</a><br>
 <br> Regards,<br><font color="#888888"> Doug Turner<br> <br> <br> <br> <br> </font></blockquote></div><br><br clear="all"><br>-- <br><br>Sent from Wandsworth, Greater London, United Kingdom</blockquote></div><br></div></div>
</div></div></div></blockquote></div><br><br clear="all"><br>-- <br><br>Sent from Zurich, Switzerland