Thank you,
i used the implementation you suggested. Now I have  a sensors.imx8.so 
compiled, and present in /vendor/lib/hw, but anyway no accelerometers were 
detected by android... what are the next steps? :(

Regards,
Gianmaria


Il giorno martedì 3 dicembre 2019 20:48:03 UTC+1, Tranphong Vu ha scritto:
>
> Hi Gianmaria,
> You need a HAL sensor implement to let Android system know that there is 
> sensor in kernel.
> You can refer to this HAL sensor implement 
> http://androidxref.com/9.0.0_r3/xref/hardware/invensense/65xx/
>
> Thanks,
> Vu Tran
>
> Vào Th 2, 2 thg 12, 2019 vào lúc 21:54 Gianmaria Iaculo <
> gianm...@nventa.it <javascript:>> đã viết:
>
>> Good morning,
>> I need a little help with accelerometer porting, I'm new to this task and 
>> right now I'm a little bit confused. I've read the documentation on Google 
>> Sensors Stack here: 
>> https://source.android.com/devices/sensors/sensor-stack
>> but I'm not able to go ahead. 
>>
>> Actually I've my accelerometer (Freescale MMA8451) connected to I2C and 
>> correctly working, my kernel drivers are loaded and i can see 
>> under /sys/class/input/input2  enable, name and so on. I can set enable = 1 
>> with cat and I can read values with getevent. 
>>
>> Now the hard part.. I have to add this to the HAL, cause android 
>> continues to say "no accelerometer connected". It's not clear to me what 
>> are the following steps.
>>
>> 1) What to add in sensors.h
>> 2)Do I need a sensor.cpp ? Or kernel drivers are enough?
>> 3) What else? 
>>
>>
>> Any help or hint will be appreciated. 
>>
>> Gianmaria 
>>
>> -- 
>> -- 
>> unsubscribe: android...@googlegroups.com <javascript:>
>> website: http://groups.google.com/group/android-porting
>>
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "android-porting" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to android...@googlegroups.com <javascript:>.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/android-porting/4751ca88-e0dd-4a88-8902-c6abdc3cce0b%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/android-porting/4751ca88-e0dd-4a88-8902-c6abdc3cce0b%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
-- 
unsubscribe: android-porting+unsubscr...@googlegroups.com
website: http://groups.google.com/group/android-porting

--- 
You received this message because you are subscribed to the Google Groups 
"android-porting" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-porting+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-porting/837982bc-f088-4d1f-a47f-b1b6fd1b4e58%40googlegroups.com.

Reply via email to