[Gta04-owner] Making sense of the sensors.

Michele Brocco ssj2micvm at gmail.com
Thu Aug 23 01:13:59 CEST 2012


On 8/11/12, Benjamin Deering <ben_deering at swissmail.org> wrote:
> On 08/10/2012 06:01 PM, Denis 'GNUtoo' Carikli wrote:
>> On Wed, 2012-08-08 at 20:12 -0400, Benjamin Deering wrote:
>>> I played a bit with valacompass on GTA04.  Libsensmon would need a
>>> BMA150 module for tilt compensation to work, but I commented out the
>>> accelerometer code in my build.
>>>
>>> The hmc5843 driver for the latest SHR kernel has the sysfs files in a
>>> different place.
>>>
>>> I changed .Sensmon/config to include:
>>> [Hmc5843Source]
>>> device=/sys/bus/i2c/devices/2-001e/iio:device0
>>>
>>> The sysfs file 'rate' seems to have changed to sampling_frequency.
>>>
>>> X,Y,and Z values come from separate files.  I'm not a vala programmer,
>>> but I can send what I did to get them.
>>>
>>> I had to adjust in_magn_range to get the Y axis to show anything but
>>> -4096.0
>> Hi, can you share the patches so I could try because I read your mail,
>> then I was told how to activate the sensors and I started to do the same
>> thing and forgot that you had the GUI working.
>> (I didn't sleep well last night and it's late right now...)
>>
>> Altough I've documented the 3.4 kernel interface here:
>> http://www.shr-project.org/trac/wiki/Devices/GTA04/Gta04Usage
>>
>> Denis.
>>
>>
>>
>>
> I've attached my changes to libsensmon.  The only change I made to
> sensmon was the default device path which is unused if .Sensmon/config
> is populated.  My valacompass changes are a mess and really it should be
> revisited after a GTA04 accelerometer is supported by libsensmon.
>
> Ben
>
thanks for your patch. I added support for the new kernel interface
for the digital compass now in libsensmon and sensmon itself. It is
now therewith possible to plot the x,y,z values of the magnetometer in
the gta04 using sensmon. I will add support to the bma module asap so
that we can try if valacompass also works. Valacompass has an offset
calibration in the initial phase. I will also want to check if the
external alignment of the smd on the gta04 is equal to the alignment
on the FRNB, because that may also be a possible source of errors when
indicating the magnetic north.


More information about the Gta04-owner mailing list