OSDN Git Service

add ONDA tablet iio.accelerometer tranformation matrix
[android-x86/device-generic-common.git] / init.sh
diff --git a/init.sh b/init.sh
index 9d6a12f..b287ec7 100644 (file)
--- a/init.sh
+++ b/init.sh
@@ -32,6 +32,10 @@ function init_hal_audio()
                *)
                        ;;
        esac
+
+       if [ "`cat /proc/asound/card0/id`" = "IntelHDMI" ]; then
+               [ -d /proc/asound/card1 ] || set_property ro.hardware.audio.primary hdmi
+       fi
 }
 
 function init_hal_bluetooth()
@@ -225,6 +229,12 @@ function init_hal_sensors()
                *i7Stylus*)
                        set_property hal.sensors.iio.accel.matrix 1,0,0,0,-1,0,0,0,-1
                        ;;
+               *ST70416-6*)
+                       set_property hal.sensors.iio.accel.matrix 0,-1,0,-1,0,0,0,0,-1
+                       ;;
+               *ONDATablet*)
+                       set_property hal.sensors.iio.accel.matrix 0,1,0,1,0,0,0,0,-1
+                       ;;
                *)
                        ;;
        esac
@@ -283,8 +293,10 @@ function init_ril()
                *TEGA*|*2010:svnIntel:*|*Lucid-MWE*)
                        set_property rild.libpath /system/lib/libhuaweigeneric-ril.so
                        set_property rild.libargs "-d /dev/ttyUSB2 -v /dev/ttyUSB1"
+                       set_property ro.radio.noril no
                        ;;
                *)
+                       set_property ro.radio.noril yes
                        ;;
        esac
 }