diff --git a/BoardConfig.mk b/BoardConfig.mk
index 1aa14cb..54635aa 100644
--- a/BoardConfig.mk
+++ b/BoardConfig.mk
@@ -1,19 +1,22 @@
-include device/samsung/u8500-common/BoardCommonConfig.mk
-TARGET_BOARD_INFO_FILE := device/samsung/janice/board-info.txt
+TARGET_OTA_ASSERT_DEVICE := janice,i9070,GT-I9070
+
+# Kernel
+TARGET_KERNEL_SOURCE := kernel/samsung/u8500
+TARGET_KERNEL_CONFIG := cyanogenmod_i9070_defconfig
# Bluetooth
BOARD_BLUETOOTH_BDROID_BUILDCFG_INCLUDE_DIR := device/samsung/janice/bluetooth
# Vibrator
-#BOARD_HAS_VIBRATOR_IMPLEMENTATION := ../../device/samsung/janice/vibrator/vibrator.c
+BOARD_HAS_VIBRATOR_IMPLEMENTATION := ../../device/samsung/janice/vibrator/vibrator.c
-# Kernel
-TARGET_KERNEL_SOURCE := kernel/samsung/u8500
-TARGET_KERNEL_CONFIG := cyanogenmod_i9070_defconfig
+# Recovery
+TARGET_RECOVERY_FSTAB := device/samsung/janice/rootdir/fstab.samsungjanice
-# Assert
-TARGET_OTA_ASSERT_DEVICE := janice,i9070,GT-I9070
+# Hardware tunables (device parts replacement)
+BOARD_HARDWARE_CLASS := device/samsung/janice/cmhw
-# Inherit from the proprietary version
--include vendor/samsung/janice/BoardConfigVendor.mk
+# Disable legacy sensors using because janice has gyro
+BOARD_USE_LEGACY_SENSORS_FUSION := false
diff --git a/DeviceSettings/Android.mk b/DeviceSettings/Android.mk
deleted file mode 100644
index 7225f50..0000000
--- a/DeviceSettings/Android.mk
+++ /dev/null
@@ -1,15 +0,0 @@
-LOCAL_PATH:= $(call my-dir)
-include $(CLEAR_VARS)
-
-LOCAL_MODULE_TAGS := optional
-
-LOCAL_STATIC_JAVA_LIBRARIES := android-support-v13
-
-LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
-LOCAL_PACKAGE_NAME := GalaxyS2Settings
-LOCAL_CERTIFICATE := platform
-
-include $(BUILD_PACKAGE)
-
-include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/DeviceSettings/AndroidManifest.xml b/DeviceSettings/AndroidManifest.xml
deleted file mode 100644
index 676922e..0000000
--- a/DeviceSettings/AndroidManifest.xml
+++ /dev/null
@@ -1,31 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/DeviceSettings/res/drawable-hdpi/ic_launcher.png b/DeviceSettings/res/drawable-hdpi/ic_launcher.png
deleted file mode 100644
index c0cefa1..0000000
Binary files a/DeviceSettings/res/drawable-hdpi/ic_launcher.png and /dev/null differ
diff --git a/DeviceSettings/res/drawable-mdpi/ic_launcher.png b/DeviceSettings/res/drawable-mdpi/ic_launcher.png
deleted file mode 100644
index 6e90f18..0000000
Binary files a/DeviceSettings/res/drawable-mdpi/ic_launcher.png and /dev/null differ
diff --git a/DeviceSettings/res/drawable-xhdpi/ic_launcher.png b/DeviceSettings/res/drawable-xhdpi/ic_launcher.png
deleted file mode 100644
index a7f789b..0000000
Binary files a/DeviceSettings/res/drawable-xhdpi/ic_launcher.png and /dev/null differ
diff --git a/DeviceSettings/res/drawable-xxhdpi/ic_launcher.png b/DeviceSettings/res/drawable-xxhdpi/ic_launcher.png
deleted file mode 100644
index 4bb6210..0000000
Binary files a/DeviceSettings/res/drawable-xxhdpi/ic_launcher.png and /dev/null differ
diff --git a/DeviceSettings/res/drawable/ic_launcher_cmdevicesettings.png b/DeviceSettings/res/drawable/ic_launcher_cmdevicesettings.png
deleted file mode 100755
index 66de9c3..0000000
Binary files a/DeviceSettings/res/drawable/ic_launcher_cmdevicesettings.png and /dev/null differ
diff --git a/DeviceSettings/res/layout/top.xml b/DeviceSettings/res/layout/top.xml
deleted file mode 100755
index 744b568..0000000
--- a/DeviceSettings/res/layout/top.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
diff --git a/DeviceSettings/res/menu/device_settings.xml b/DeviceSettings/res/menu/device_settings.xml
deleted file mode 100644
index 70f8954..0000000
--- a/DeviceSettings/res/menu/device_settings.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
diff --git a/DeviceSettings/res/values-de/arrays.xml b/DeviceSettings/res/values-de/arrays.xml
deleted file mode 100644
index 04797c6..0000000
--- a/DeviceSettings/res/values-de/arrays.xml
+++ /dev/null
@@ -1,69 +0,0 @@
-
-
-
- - Kamera (Standard)
- - Video
- - Video warm
- - Video kalt
- - UI
- - Navigation
- - Gallerie
- - VT
-
-
-
- - Standard
- - Dynamisch
- - Natürlich
- - Film
-
-
-
- - Normal
- - Invertiert
-
-
-
- - Deaktiviert
- - Aktiviert
-
-
-
- - 2.2 (Standard)
- - 1.9
-
-
-
- - 10
- - 20
- - 30
- - 50 (Standard)
- - 70
- - 100
-
-
-
- - 0%
- - 25%
- - 50% (Standard)
- - 75%
- - 100%
-
-
-
- - Nur UMTS
- - Nur HSDPA
- - HSDPA + HSUPA
-
-
-
- - Niemals
- - 1 Sekunde
- - 2 Sekunden
- - 3 Sekunden (Standard)
- - 4 Sekunden
- - 5 Sekunden
- - 6 Sekunden
-
-
-
diff --git a/DeviceSettings/res/values-de/strings.xml b/DeviceSettings/res/values-de/strings.xml
deleted file mode 100644
index 95fd558..0000000
--- a/DeviceSettings/res/values-de/strings.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-
-
- Galaxy S Advance Einstellungen
-
- Bildschirm
- Farben
- mDNIe-Szenario
- mDNIe-Szenario auswählen
- mDNIe-Modus
- mDNIe-Modus auswählen
- Negativ
- Farben invertieren an/aus
- Outdoor
- Outdoor-Modus an/aus
- Gamma
- Gamma Wert
-
- Touchscreen
- Empfindlichkeit
- Berührungs-Empfindlichkeit
-
- Touchkeys
- Beleuchtung
- Touchkeys leuchten auf während das Display aktiv ist
- Beleuchtungs-Timeout
- Zeit für die autom. Abschaltung der Touchkey-Beleuchtung
-
- Sensoren
- Beschleunigungssensor
- Kalibierungsdaten
- Kalibrierungswerte verwenden\nNach Aktivierung bitte Kalibrierung ausführen
- Kalibrieren
- Sensor kalibrieren\nZum Starten das Telefon auf eine horizontale, ebene Fläche legen
- Kalibrierung beendet
- Der Beschleunigungssensor wurde kalibriert
-
- Haptik
- Vibration
- Intensität
- Vibrations-Intensität
-
- Mobilfunk
- HSPA
- HSDPA/HSUPA an/aus
-
- Dock
- Audio
- USB-Dock Audio
- Passive Audio-Ausgabe des USB-Docks verwenden
-
diff --git a/DeviceSettings/res/values-es/arrays.xml b/DeviceSettings/res/values-es/arrays.xml
deleted file mode 100644
index 0c8a697..0000000
--- a/DeviceSettings/res/values-es/arrays.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-
-
- - 2.2 (por defecto)
- - 1.9
-
-
- - 10
- - 20
- - 30
- - 50 (por defecto)
- - 70
- - 100
-
-
- - 0%
- - 25%
- - 50% (por defecto)
- - 75%
- - 100%
-
-
- - Solo UMTS
- - Solo HSDPA
- - HSDPA + HSUPA
-
-
- - Nunca
- - 1 segundo
- - 2 segundos
- - 3 segundos (por defecto)
- - 4 segundos
- - 5 segundos
- - 6 segundos
-
-
diff --git a/DeviceSettings/res/values-es/strings.xml b/DeviceSettings/res/values-es/strings.xml
deleted file mode 100644
index c8c453b..0000000
--- a/DeviceSettings/res/values-es/strings.xml
+++ /dev/null
@@ -1,43 +0,0 @@
-
-
- "Ajustes Galaxy S Advance"
- "Pantalla"
- "Colores"
- "Escenario"
- "Establecer escenario mDNIe"
- "Modo"
- "Establecer modo mDNIe"
- "Modo negativo"
- "Habilitar/deshabilitar colores invertidos"
- "Modo al aire libre"
- "Habilitar/deshabilitar modo al aire libre"
- "Gamma"
- "Establece el valor Gamma de la pantalla"
- "Pantalla táctil"
- "Sensibilidad táctil"
- "Establecer la sensibilidad del panel táctil"
- "Teclas táctiles"
- "Habilitar retroiluminación de teclas táctiles"
- "Retroiluminación teclas táctiles cuando la pantalla está activa"
- "Tiempo de espera de retroiluminación"
- "Tiempo tras pulsar una tecla antes de apagar la retroiluminación"
- "Sensores"
- "Acelerómetro"
- "Usar datos de calibración"
- "Usar los valores de calibración del acelerómetro. ¡Realizar una calibración después de habilitar esta funcionalidad!"
- "Calibrar"
- "Poner el teléfono sobre una superficie plana, y presionar este menú para calibrar de nuevo"
- "Calibración realizada"
- "El sensor ha sido calibrado satisfactoriamente"
- "Háptica"
- "Vibración"
- "Intensidad de vibración"
- "Establecer la intensidad de vibración"
- "Radio"
- "HSPA"
- "Habilitar HSDPA/HSUPA"
- "Conector"
- "Audio"
- "Usar el conector de audio USB"
- "Usar la salida de audio pasiva cuando el conector USB esté activado"
-
diff --git a/DeviceSettings/res/values-fi/arrays.xml b/DeviceSettings/res/values-fi/arrays.xml
deleted file mode 100644
index 6db9aa8..0000000
--- a/DeviceSettings/res/values-fi/arrays.xml
+++ /dev/null
@@ -1,69 +0,0 @@
-
-
-
- - Kamera (Oletus)
- - Video
- - Video(Lämmin)
- - Video(Kylmä)
- - Käyttöliittymä
- - Navigointi
- - Galleria
- - VT
-
-
-
- - Standardi (Oletus)
- - Dynaaminen
- - Luonnollinen
- - Elokuva
-
-
-
- - Normaali
- - Käänteinen
-
-
-
- - Pois päältä (Oletus)
- - Päällä
-
-
-
- - 2.2 (Oletus)
- - 1.9
-
-
-
- - 10
- - 20
- - 30
- - 50 (Oletus)
- - 70
- - 100
-
-
-
- - 0%
- - 25%
- - 50% (Oletus)
- - 75%
- - 100%
-
-
-
- - Vain UMTS
- - Vain HSDPA
- - HSDPA + HSUPA
-
-
-
- - Never
- - 1 second
- - 2 seconds
- - 3 seconds (Oletus)
- - 4 seconds
- - 5 seconds
- - 6 seconds
-
-
-
diff --git a/DeviceSettings/res/values-fi/strings.xml b/DeviceSettings/res/values-fi/strings.xml
deleted file mode 100644
index 36578bd..0000000
--- a/DeviceSettings/res/values-fi/strings.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-
-
- Galaxy S Advance-asetukset
-
- Näyttö
- Värit
- Skenaario
- Vaihda mDNIe-skenaario
- Tila
- Vaihda mDNIe-tila
- Negatiivi-tila
- Käytä käänteisiä värejä
- Ulkoilma-tila
- Ota ulkoilma-tila käyttöön
- Näytön gamma
- Säädä näytön gamma-arvo
-
- Kosketusnäyttö
- Kosketuksen herkkyys
- Säädä näytön herkkyyttä
-
- Kosketusnäppäimet
- Ota näppäinten taustavalo käyttöön
- Näytön ollessa päällä valot syttyvät
- Taustavalon aikakatkaisu
- Säädä taustavalon sammumisen aikaväliä kosketuksesta
-
- Sensorit
- Kiihtyvyysanturi
- Käytä kalibrointitietoja
- Käytä kiihtyvyysanturin kalibrointiarvoja. Kalibroi merkattuasi tämän!
- Kalibroi
- Aseta puhelin tasaiselle alustalle ja paina tätä kalibroidaksesi
- Kalibrointi valmis
- Sensori kalibroitu onnistuneesti
-
- Haptinen
- Värinä
- Värinän voimakkuus
- Säädä värinän voimakkuutta
-
- Radio
- HSPA
- Ota HSDPA/HSUPA käyttöön
-
- Telakka
- Audio
- Käytä USB-audiotelakkaa
- Käytä telakan audioulostuloa
-
diff --git a/DeviceSettings/res/values-hu/arrays.xml b/DeviceSettings/res/values-hu/arrays.xml
deleted file mode 100644
index bab1ea5..0000000
--- a/DeviceSettings/res/values-hu/arrays.xml
+++ /dev/null
@@ -1,69 +0,0 @@
-
-
-
- - Kamera (Alapbeállítás)
- - Videó
- - Videó (Meleg árnyalat)
- - Videó (Hideg árnyalat)
- - Felhasználói felület
- - Navigáció
- - Galéria
- - VT
-
-
-
- - Hagyományos (Alapbeállítás)
- - Dinamikus
- - Természetes
- - Film
-
-
-
- - Hagyományos
- - Fordított
-
-
-
- - Kikapcsolva (Alapbeállítás)
- - Bekapcsolva
-
-
-
- - 2.2 (Alapbeállítás)
- - 1.9
-
-
-
- - 10
- - 20
- - 30
- - 50 (Alapbeállítás)
- - 70
- - 100
-
-
-
- - 0%
- - 25%
- - 50% (Alapbeállítás)
- - 75%
- - 100%
-
-
-
- - UMTS
- - HSDPA
- - HSDPA + HSUPA
-
-
-
- - Soha
- - 1 másodperc
- - 2 másodperc
- - 3 másodperc (Alapbeállítás)
- - 4 másodperc
- - 5 másodperc
- - 6 másodperc
-
-
-
diff --git a/DeviceSettings/res/values-hu/strings.xml b/DeviceSettings/res/values-hu/strings.xml
deleted file mode 100644
index 5e852b2..0000000
--- a/DeviceSettings/res/values-hu/strings.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-
-
- Galaxy S Advance Beállítások
-
- Kijelző
- Színek
- Megjelenítés
- mDNIe megjelenítési beállítások
- Üzemmód
- mDNIe üzemmódok
- Negatív üzemmód
- Fordított színek ki/be
- Szabadtéri üzemmód
- Szabadtéri üzemmód ki/be
- Kijelző gamma-értéke
- Kijelző gamma-érték beállítása
-
- Érintőképernyő
- Érzékenység
- Érintőképernyő érzékenységének beállítása
-
- Érintőgombok
- Érintőgombok háttérvilágítása
- Bekapcsolja az érintőgombok háttérvilágítását bekapcsolt képernyőnél
- Háttérvilágítás időkorlátja
- Háttérvilágítás késleltetése
-
- Szenzorok
- Giroszkóp
- Kalibrálási érték használata
- Kalibrálási érték használata. Érdemes újra kalibrálni, ha ez a funkció használatban van!
- Kalibrálás
- Kalibráláshoz a telefont vízszintes felületre kell helyezni, és megérinteni ezt a gombot
- Kalibrálás befejezve
- Az érzékelő sikeresen bekalibrálva.
-
- Érintési visszajelzés
- Rezgés
- Rezgés erőssége
- Rezgés erősségének beállítása
-
- GSM Rádió
- HSPA
- HSDPA/HSUPA engedélyezése
-
- Dokkoló
- Dokkoló hangszórók
- Dokkoló hangszóróinak használata
- Használja a dokkoló passzív hangkimenetét
-
diff --git a/DeviceSettings/res/values-it/strings.xml b/DeviceSettings/res/values-it/strings.xml
deleted file mode 100644
index ed70318..0000000
--- a/DeviceSettings/res/values-it/strings.xml
+++ /dev/null
@@ -1,44 +0,0 @@
-
-
- Impostazioni Galaxy S Advance
- Schermo
- Colori
- Scenario
- Imposta lo scenario mDNIe
- Modalità
- Imposta la modalità mDNIe
- Negativo
- Abilita/disabilita i colori invertiti
- Esterno
- Abilita/disabilita la modalità esterno
- Gamma schermo
- Imposta il valore gamma dello schermo
- Schermo tattile
- Sensibilità tocco
- Imposta la sensibilità al tocco dello schermo
- Tasti a sfioramento
- Retroilluminazione
- Abilita la retroilluminazione dei tasti a sfioramento quando lo schermo è attivo
- Timer retroilluminazione
- Imposta l\'intervallo dopo cui la retroilluminazione dei tasti si spegne
- Sensori
- Accelerometro
- Usa dati di calibrazione
- Usa i valori di calibrazione dell\'accelerometro. Effettuare una calibrazione dopo aver attivato questa impostazione!
- Calibrazione
- Posizionare il telefono su una superficie orizzontale piana e premere per effettuare la calibrazione
- Calibrazione effettuata
- Il sensore è stato correttamente calibrato.
- Feedback tattile
- Vibratore
- Intensità vibrazione
- Imposta l\'intensità della vibrazione
- Radio
- HSPA
- Abilita HSDPA/HSUPA
- Dock
- Audio
- Usa USB audio in dock
- Usa l\'uscita audio passiva quando in dock
-
-
diff --git a/DeviceSettings/res/values-nl/arrays.xml b/DeviceSettings/res/values-nl/arrays.xml
deleted file mode 100644
index 3e15c11..0000000
--- a/DeviceSettings/res/values-nl/arrays.xml
+++ /dev/null
@@ -1,75 +0,0 @@
-
-
-
-
- - Camera (standaard)
- - Video
- - Video (warm)
- - Video (koud)
- - Uiterlijk
- - Navigatie
- - Galerij
- - VT
-
-
- - Standaard
- - Dynamisch
- - Natuurlijk
- - Film
-
-
- - Normaal
- - Omgedraaid
-
-
- - Uit (standaard)
- - Aan
-
-
- - 2,2 (standaard)
- - 1,9
-
-
- - 10
- - 20
- - 30
- - 50 (standaard)
- - 70
- - 100
-
-
- - 0%
- - 25%
- - 50% (standaard)
- - 75%
- - 100%
-
-
- - Alleen UMTS
- - Alleen HSDPA
- - HSDPA & HSUPA
-
-
- - Nooit
- - 1 seconde
- - 2 seconden
- - 3 seconden (standaard)
- - 4 seconden
- - 5 seconden
- - 6 seconden
-
-
diff --git a/DeviceSettings/res/values-nl/strings.xml b/DeviceSettings/res/values-nl/strings.xml
deleted file mode 100644
index 82ee12c..0000000
--- a/DeviceSettings/res/values-nl/strings.xml
+++ /dev/null
@@ -1,65 +0,0 @@
-
-
-
- Galaxy S Advance-instellingen
-
- Kleuren
- Scherm
- Scenario
- mDNIe-scenario instellen
- Modus
- mDNIe-modus instellen
- Negatieve modus
- Negatieve kleuren in-/uitschakelen
- Buitenmodus
- Buitenmodus in-/uitschakelen
- Schermgamma
- Schermgammawaarden instellen
-
- Aanraakscherm
- Aanraakgevoeligheid
- Gevoeligheid aanraakscherm instellen
-
- Aanraakknop
- Achtergrondlicht bij knoppen inschakelen
- Aanraakknoppen oplichten indien scherm aan is
- Time-out achtergrondlicht
- Vertraging na druk op een knop voor uitschakelen achtergrondlicht
-
- Sensoren
- Gyroscoop
- Kalibratiegegevens gebruiken
- Kalibratiewaarden van de gyroscoop gebruiken. Voer hierna a.u.b. een kalibratie uit.
- Kalibreren
- Plaats de telefoon op een vlakke ondergrond en tik hier om te kalibreren
- Kalibratie afgerond
- De sensor is succesvol gekalibreerd.
-
- Trillen
- Trillen
- Trilintensiteit
- Trilintensiteit instellen
-
- Radio
- HSPA
- HSDPA/HSUPA inschakelen
-
- Dock
- Geluid
- USB-geluidsdock
- Passieve geluidsuitgang van het dock gebruiken
-
diff --git a/DeviceSettings/res/values-pt-rBR/arrays.xml b/DeviceSettings/res/values-pt-rBR/arrays.xml
deleted file mode 100755
index 3e634d0..0000000
--- a/DeviceSettings/res/values-pt-rBR/arrays.xml
+++ /dev/null
@@ -1,60 +0,0 @@
-
-
-
- - Câmera (Padrão)
- - Vídeo
- - Vídeo Quente
- - Vídeo Frio
- - IU
- - Navegação
- - Galeria
- - VT
-
-
- - Padrão
- - Dinâmico
- - Natural
- - Filme
-
-
- - Normal
- - Invertido
-
-
- - Desligado (Padrão)
- - Ligado
-
-
- - 2.2 (Padrão)
- - 1.9
-
-
- - 10
- - 20
- - 30
- - 50 (Padrão)
- - 70
- - 100
-
-
- - 0%
- - 25%
- - 50% (Padrão)
- - 75%
- - 100%
-
-
- - Somente UMTS
- - Somente HSDPA
- - HSDPA + HSUPA
-
-
- - Nunca
- - 1 segundo
- - 2 segundos
- - 3 segundos (padrão)
- - 4 segundos
- - 5 segundos
- - 6 segundos
-
-
\ No newline at end of file
diff --git a/DeviceSettings/res/values-pt-rBR/strings.xml b/DeviceSettings/res/values-pt-rBR/strings.xml
deleted file mode 100755
index 0058f36..0000000
--- a/DeviceSettings/res/values-pt-rBR/strings.xml
+++ /dev/null
@@ -1,43 +0,0 @@
-
-
- Config. Galaxy S Advance
- Cores
- Cenário
- Define o Cenário mDNIe
- Modo
- Define o Modo mDNIe
- Modo Negativo
- Ativa/Desativa cores invertidas
- Modo Ao Ar Livre
- Ativa/Desativa modo ao ar livre
- Gama da Tela
- Define valor da gama da tela
- Tela sensível ao toque
- Sensitividade do toque
- Define a sensitividade do toque na tela
- Tecla sensível ao toque
- Ativar luz de fundo das teclas
- Acender as teclas sensíveis ao toque quando a tela estiver ligada
- Tempo limite da luz de fundo
- Quanto tempo a luz de fundo irá ficar acesa depois do botão ser pressionado
- Sensores
- Resposta Tátil
- Vibração
- Intensidade da Vibração
- Define a intensidade da vibração
- Rádio
- HSPA
- Ativa HSDPA/HSUPA
- Tela
- Acelerômetro
- Usar dados de calibragem
- Usa os valores dos dados de calibragem. Calibre após marcar isto!
- Calibrar
- Coloque seu telefone em uma superfície plana, e pressione isto para calibrar
- Calibragem terminada
- O sensor foi calibrado com sucesso.
- Dock
- Áudio
- Usar Áudio USB do Dock
- Usar o áudio de saída passivo no dock
-
\ No newline at end of file
diff --git a/DeviceSettings/res/values-sw600dp/dimens.xml b/DeviceSettings/res/values-sw600dp/dimens.xml
deleted file mode 100644
index 44f01db..0000000
--- a/DeviceSettings/res/values-sw600dp/dimens.xml
+++ /dev/null
@@ -1,8 +0,0 @@
-
-
-
-
-
diff --git a/DeviceSettings/res/values-sw720dp-land/dimens.xml b/DeviceSettings/res/values-sw720dp-land/dimens.xml
deleted file mode 100644
index 61e3fa8..0000000
--- a/DeviceSettings/res/values-sw720dp-land/dimens.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
- 128dp
-
-
diff --git a/DeviceSettings/res/values-v11/styles.xml b/DeviceSettings/res/values-v11/styles.xml
deleted file mode 100644
index 3c02242..0000000
--- a/DeviceSettings/res/values-v11/styles.xml
+++ /dev/null
@@ -1,11 +0,0 @@
-
-
-
-
-
-
diff --git a/DeviceSettings/res/values-v14/styles.xml b/DeviceSettings/res/values-v14/styles.xml
deleted file mode 100644
index a91fd03..0000000
--- a/DeviceSettings/res/values-v14/styles.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-
-
-
-
-
-
diff --git a/DeviceSettings/res/values-zh-rCN/arrays.xml b/DeviceSettings/res/values-zh-rCN/arrays.xml
deleted file mode 100644
index d9e9a34..0000000
--- a/DeviceSettings/res/values-zh-rCN/arrays.xml
+++ /dev/null
@@ -1,69 +0,0 @@
-
-
-
- - 照相 (默认)
- - 影片
- - 影片 (温)
- - 影片 (冷)
- - 界面
- - 导航
- - 图库
- - VT
-
-
-
- - 标准 (默认)
- - 动态
- - 自然
- - 电影
-
-
-
- - 正常
- - 反色
-
-
-
- - 禁用 (默认)
- - 启用
-
-
-
- - 2.2 (默认)
- - 1.9
-
-
-
- - 10
- - 20
- - 30
- - 50 (默认)
- - 70
- - 100
-
-
-
- - 0%
- - 25%
- - 50% (默认)
- - 75%
- - 100%
-
-
-
- - 仅使用 UMTS
- - 仅使用 HSDPA
- - 使用 HSDPA + HSUPA
-
-
-
- - 从不
- - 1 秒
- - 2 秒
- - 3 秒 (默认)
- - 4 秒
- - 5 秒
- - 6 秒
-
-
-
diff --git a/DeviceSettings/res/values-zh-rCN/strings.xml b/DeviceSettings/res/values-zh-rCN/strings.xml
deleted file mode 100644
index 3603584..0000000
--- a/DeviceSettings/res/values-zh-rCN/strings.xml
+++ /dev/null
@@ -1,50 +0,0 @@
-
-
- Galaxy S Advance 设置
-
- 屏幕
- 颜色
- 场景
- 设置 mDNIe 场景
- 模式
- 设置 mDNIe 模式
- 负极模式
- 启用/禁用反色
- 户外模式
- 启用/禁用户外模式
- 屏幕珈玛
- 设置屏幕珈玛
-
- 触摸屏
- 触摸屏灵敏度
- 设置触摸屏灵敏度
-
- 触摸键
- 启用触摸键背光灯
- 屏幕开启时触摸键将会点亮
- 背光灯超时
- 设置背光灯超时时间
-
- 感应器
- 加速规
- 使用校准数据
- 使用加速规的校准数据. 请在检查此之后重新校准!
- 校准
- 把手机放在平面上,然后点击此按键进行校准
- 校准完成
- 感应器已被成功的校准.
-
- 振动
- 振动器
- 振动器强度
- 设置振动器强度
-
- 无线电
- HSPA
- 启用 HSDPA/HSUPA
-
- 基座
- 音频
- 使用基座的 USB 音频
- 使用基座上的被动音频输出
-
diff --git a/DeviceSettings/res/values/arrays.xml b/DeviceSettings/res/values/arrays.xml
deleted file mode 100644
index d2d3f1f..0000000
--- a/DeviceSettings/res/values/arrays.xml
+++ /dev/null
@@ -1,115 +0,0 @@
-
-
-
- - 600 ms
- - 400 ms
- - 350 ms (default)
- - 200 ms
- - 100 ms
-
-
- - 600
- - 400
- - 350
- - 200
- - 100
-
-
- - 750 mAh *WARNING*
- - 600 mAh (fast charge)
- - 450 mAh
-
-
- - 750
- - 600
- - 450
-
-
-
- - State 5
- - State 4
- - State 3 (default)
-
-
- - 5
- - 4
- - 3
-
-
- - 750 mAh *WARNING*
- - 600 mAh (default)
- - 450 mAh
-
-
- - 750
- - 600
- - 450
-
-
- - 2.2 (Default)
- - 1.9
-
-
- - 0
- - 1
-
-
- - 10
- - 20
- - 30
- - 50 (Default)
- - 70
- - 100
-
-
- - 10
- - 20
- - 30
- - 50
- - 70
- - 100
-
-
- - 0%
- - 25%
- - 50% (default)
- - 75%
- - 100%
-
-
- - 0
- - 25
- - 50
- - 75
- - 100
-
-
- - UMTS Only
- - HSDPA Only
- - HSDPA + HSUPA
-
-
- - 21
- - 22
- - 23
-
-
- - Never
- - 1 second
- - 2 seconds
- - 3 seconds (default)
- - 4 seconds
- - 5 seconds
- - 6 seconds
-
-
- - 0
- - 1
- - 2
- - 3
- - 4
- - 5
- - 6
-
-
-
diff --git a/DeviceSettings/res/values/dimens.xml b/DeviceSettings/res/values/dimens.xml
deleted file mode 100644
index 55c1e59..0000000
--- a/DeviceSettings/res/values/dimens.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
- 16dp
- 16dp
-
-
diff --git a/DeviceSettings/res/values/strings.xml b/DeviceSettings/res/values/strings.xml
deleted file mode 100644
index e1651b7..0000000
--- a/DeviceSettings/res/values/strings.xml
+++ /dev/null
@@ -1,65 +0,0 @@
-
-
- Galaxy S Advance Settings
-
-
- General
-
- Radio mode
- HSPA
- Enable HSDPA/HSUPA
-
- Vibrator
- Vibrator Intensity
- Set vibrator intensity
-
- Advanced
- Deepest sleep state
- Specify the highest deep sleep level
-
- Screen
-
- Colors
- Screen Gamma
- Set screen gamma value
-
- Touchscreen
- Touch sensitivity
- Set touch panel sensitivity
-
- Touchkeys
- Enable keys backlight
- Light up touchkeys when screen is on
- Backlight timeout
- Delay after a keypress before backlight turns off
-
- CRT-OFF Effect
- FB Early Suspend Delay
- Enable / Disable framebuffer early suspend delay, it will enable the crt-off effect
- Delay in ms
- Amount in milliseconds to wait before the screen turns off
-
- Accelerometer
- Use calibration data
- Use the accelerometer calibration values. Do a calibration after checking this!
- Calibrate
- Put your phone on a flat surface, and press this to calibrate
- Calibration done
- The sensor has been successfully calibrated.
-
- Usb
-
- USB OTG Settings
- USB-OTG Power
- Enables output voltage to the USB port
-
- Charger control
-
- Wall charger currency
- Wall charger currency in mAh, low levels protect battery but takes longer to charge, high levels may damage the battery life
-
- USB cable currency
- USB cable currency in mAh, useful to implement Fast Charge, low levels protect battery but takes longer to charge, high levels may damage the battery life
-
-
-
diff --git a/DeviceSettings/res/values/styles.xml b/DeviceSettings/res/values/styles.xml
deleted file mode 100644
index 6ce89c7..0000000
--- a/DeviceSettings/res/values/styles.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-
-
-
-
-
-
-
-
-
diff --git a/DeviceSettings/res/xml/general_preferences.xml b/DeviceSettings/res/xml/general_preferences.xml
deleted file mode 100644
index 6c8b6c1..0000000
--- a/DeviceSettings/res/xml/general_preferences.xml
+++ /dev/null
@@ -1,53 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/DeviceSettings/res/xml/screen_preferences.xml b/DeviceSettings/res/xml/screen_preferences.xml
deleted file mode 100644
index 73819ed..0000000
--- a/DeviceSettings/res/xml/screen_preferences.xml
+++ /dev/null
@@ -1,71 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/DeviceSettings/res/xml/usb_preferences.xml b/DeviceSettings/res/xml/usb_preferences.xml
deleted file mode 100644
index bad9016..0000000
--- a/DeviceSettings/res/xml/usb_preferences.xml
+++ /dev/null
@@ -1,38 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/DeviceSettings/src/com/cyanogenmod/settings/device/ChargerCurrency.java b/DeviceSettings/src/com/cyanogenmod/settings/device/ChargerCurrency.java
deleted file mode 100644
index 3ab19a6..0000000
--- a/DeviceSettings/src/com/cyanogenmod/settings/device/ChargerCurrency.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Copyright (C) 2012 The CyanogenMod Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.cyanogenmod.settings.device;
-
-import android.content.Context;
-import android.util.AttributeSet;
-import android.content.SharedPreferences;
-import android.preference.Preference;
-import android.preference.ListPreference;
-import android.preference.Preference.OnPreferenceChangeListener;
-import android.preference.PreferenceManager;
-
-public class ChargerCurrency extends ListPreference implements OnPreferenceChangeListener {
-
- public ChargerCurrency(Context context, AttributeSet attrs) {
- super(context, attrs);
- this.setOnPreferenceChangeListener(this);
- }
-
- private static final String FILE = "/sys/module/abb_charger/parameters/max_ac_current";
-
- public static boolean isSupported() {
- return Utils.fileExists(FILE);
- }
-
- /**
- * Restore currency setting from SharedPreferences. (Write to kernel.)
- * @param context The context to read the SharedPreferences from
- */
- public static void restore(Context context) {
- if (!isSupported()) {
- return;
- }
-
- SharedPreferences sharedPrefs = PreferenceManager.getDefaultSharedPreferences(context);
- Utils.writeValue(FILE, sharedPrefs.getString(DeviceSettings.KEY_AC_CURRENCY, "600"));
- }
-
- public boolean onPreferenceChange(Preference preference, Object newValue) {
- Utils.writeValue(FILE, (String) newValue);
- return true;
- }
-
-}
diff --git a/DeviceSettings/src/com/cyanogenmod/settings/device/DeepestSleepState.java b/DeviceSettings/src/com/cyanogenmod/settings/device/DeepestSleepState.java
deleted file mode 100644
index 018f4d6..0000000
--- a/DeviceSettings/src/com/cyanogenmod/settings/device/DeepestSleepState.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Copyright (C) 2012 The CyanogenMod Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.cyanogenmod.settings.device;
-
-import android.content.Context;
-import android.util.AttributeSet;
-import android.content.SharedPreferences;
-import android.preference.Preference;
-import android.preference.ListPreference;
-import android.preference.Preference.OnPreferenceChangeListener;
-import android.preference.PreferenceManager;
-
-public class DeepestSleepState extends ListPreference implements OnPreferenceChangeListener {
-
- public DeepestSleepState(Context context, AttributeSet attrs) {
- super(context, attrs);
- this.setOnPreferenceChangeListener(this);
- }
-
- private static final String FILE = "/d/cpuidle/deepest_state";
-
- public static boolean isSupported() {
- return Utils.fileExists(FILE);
- }
-
- /**
- * Restore deepest sleep state from SharedPreferences.
- * @param context The context to read the SharedPreferences from
- */
- public static void restore(Context context) {
- if (!isSupported()) {
- return;
- }
-
- SharedPreferences sharedPrefs = PreferenceManager.getDefaultSharedPreferences(context);
- Utils.writeValue(FILE, sharedPrefs.getString(DeviceSettings.KEY_DEEPEST_SLEEP_STATE, "3"));
- }
-
- public boolean onPreferenceChange(Preference preference, Object newValue) {
- Utils.writeValue(FILE, (String) newValue);
- return true;
- }
-
-}
diff --git a/DeviceSettings/src/com/cyanogenmod/settings/device/DeviceSettings.java b/DeviceSettings/src/com/cyanogenmod/settings/device/DeviceSettings.java
deleted file mode 100644
index 1219d1d..0000000
--- a/DeviceSettings/src/com/cyanogenmod/settings/device/DeviceSettings.java
+++ /dev/null
@@ -1,172 +0,0 @@
-/*
- * Copyright (C) 2012 The CyanogenMod Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.cyanogenmod.settings.device;
-
-import android.app.ActionBar;
-import android.app.ActionBar.Tab;
-import android.app.Activity;
-import android.app.Fragment;
-import android.app.FragmentTransaction;
-import android.content.Context;
-import android.os.Bundle;
-import android.support.v4.app.FragmentActivity;
-import android.support.v13.app.FragmentPagerAdapter;
-import android.support.v4.view.ViewPager;
-import android.view.MenuItem;
-
-import java.util.ArrayList;
-
-import com.cyanogenmod.settings.device.R;
-
-public class DeviceSettings extends FragmentActivity {
-
- public static final String SHARED_PREFERENCES_BASENAME = "com.cyanogenmod.settings.device";
- public static final String ACTION_UPDATE_PREFERENCES = "com.cyanogenmod.settings.device.UPDATE";
- public static final String KEY_PANEL_GAMMA = "panel_gamma";
- public static final String KEY_HSPA = "hspa";
- public static final String KEY_USE_ACCELEROMETER_CALIBRATION = "use_accelerometer_calibration";
- public static final String KEY_CALIBRATE_ACCELEROMETER = "calibrate_accelerometer";
- public static final String KEY_TOUCHSCREEN_SENSITIVITY = "touchscreen_sensitivity";
- public static final String KEY_TOUCHKEY_LIGHT = "touchkey_light";
- public static final String KEY_TOUCHKEY_TIMEOUT = "touchkey_timeout";
- public static final String KEY_VIBRATOR_INTENSITY = "vibrator_intensity";
- public static final String KEY_USE_DOCK_AUDIO = "dock_audio";
- public static final String KEY_USB_OTG_POWER = "usb_otg_power";
- public static final String KEY_FB_EARLYSUSPEND_DELAY = "fb_earlysuspend_delay";
- public static final String KEY_FB_EARLYSUSPEND_DELAY_MS = "fb_earlysuspend_delay_ms";
- public static final String KEY_DEEPEST_SLEEP_STATE = "deepest_sleep_state";
- public static final String KEY_AC_CURRENCY = "ac_currency";
- public static final String KEY_USB_CURRENCY = "usb_currency";
-
- ViewPager mViewPager;
- TabsAdapter mTabsAdapter;
-
- @Override
- protected void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
-
- mViewPager = new ViewPager(this);
- mViewPager.setId(R.id.viewPager);
- setContentView(mViewPager);
-
- final ActionBar bar = getActionBar();
- bar.setNavigationMode(ActionBar.NAVIGATION_MODE_TABS);
- bar.setDisplayOptions(ActionBar.DISPLAY_SHOW_TITLE, ActionBar.DISPLAY_SHOW_TITLE);
- bar.setTitle(R.string.app_name);
- bar.setDisplayHomeAsUpEnabled(true);
-
- mTabsAdapter = new TabsAdapter(this, mViewPager);
- mTabsAdapter.addTab(bar.newTab().setText(R.string.category_general_title),
- GeneralFragmentActivity.class, null);
- mTabsAdapter.addTab(bar.newTab().setText(R.string.category_screen_title),
- ScreenFragmentActivity.class, null);
- mTabsAdapter.addTab(bar.newTab().setText(R.string.category_usb_title),
- USBFragmentActivity.class, null);
-
- if (savedInstanceState != null) {
- bar.setSelectedNavigationItem(savedInstanceState.getInt("tab", 0));
- }
- }
-
- @Override
- protected void onSaveInstanceState(Bundle outState) {
- super.onSaveInstanceState(outState);
- outState.putInt("tab", getActionBar().getSelectedNavigationIndex());
- }
-
- public static class TabsAdapter extends FragmentPagerAdapter
- implements ActionBar.TabListener, ViewPager.OnPageChangeListener {
- private final Context mContext;
- private final ActionBar mActionBar;
- private final ViewPager mViewPager;
- private final ArrayList mTabs = new ArrayList();
-
- static final class TabInfo {
- private final Class> clss;
- private final Bundle args;
-
- TabInfo(Class> _class, Bundle _args) {
- clss = _class;
- args = _args;
- }
- }
-
- public TabsAdapter(Activity activity, ViewPager pager) {
- super(activity.getFragmentManager());
- mContext = activity;
- mActionBar = activity.getActionBar();
- mViewPager = pager;
- mViewPager.setAdapter(this);
- mViewPager.setOnPageChangeListener(this);
- }
-
- public void addTab(ActionBar.Tab tab, Class> clss, Bundle args) {
- TabInfo info = new TabInfo(clss, args);
- tab.setTag(info);
- tab.setTabListener(this);
- mTabs.add(info);
- mActionBar.addTab(tab);
- notifyDataSetChanged();
- }
-
- @Override
- public int getCount() {
- return mTabs.size();
- }
-
- @Override
- public Fragment getItem(int position) {
- TabInfo info = mTabs.get(position);
- return Fragment.instantiate(mContext, info.clss.getName(), info.args);
- }
-
- public void onPageScrolled(int position, float positionOffset, int positionOffsetPixels) {
- }
-
- public void onPageSelected(int position) {
- mActionBar.setSelectedNavigationItem(position);
- }
-
- public void onPageScrollStateChanged(int state) {
- }
-
- public void onTabSelected(Tab tab, FragmentTransaction ft) {
- Object tag = tab.getTag();
- for (int i=0; i
+ *
+ * As convenience, implementations should set the download interval to the half of the
+ * validity of the downloaded data.
+ *
+ * @return long The download interval in milliseconds
+ */
+ public static long getDownloadInterval() { return DOWNLOAD_INTERVAL_DEFAULT; }
+
+}
diff --git a/cmhw/org/cyanogenmod/hardware/VibratorHW.java b/cmhw/org/cyanogenmod/hardware/VibratorHW.java
new file mode 100644
index 0000000..cdb93af
--- /dev/null
+++ b/cmhw/org/cyanogenmod/hardware/VibratorHW.java
@@ -0,0 +1,112 @@
+/*
+ * Copyright (C) 2013 The CyanogenMod Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.cyanogenmod.hardware;
+
+import org.cyanogenmod.hardware.util.FileUtils;
+import java.io.File;
+
+/*
+ * Vibrator intensity adjustment
+ *
+ * Exports methods to get the valid value boundaries, the
+ * default and current intensities, and a method to set
+ * the vibrator.
+ *
+ * Values exported by min/max can be the direct values required
+ * by the hardware, or a local (to VibratorHW) abstraction that's
+ * internally converted to something else prior to actual use. The
+ * Settings user interface will normalize these into a 0-100 (percentage)
+ * scale before showing them to the user, but all values passed to/from
+ * the client (Settings) are in this class' scale.
+ */
+
+/* This would be just "Vibrator", but it conflicts with android.os.Vibrator */
+public class VibratorHW {
+
+ private static final String PATH = "/sys/vibrator/pwm_value";
+
+ /*
+ * All HAF classes should export this boolean.
+ * Real implementations must, of course, return true
+ */
+
+ public static boolean isSupported() {
+ return new File(PATH).exists();
+ }
+
+ /*
+ * Set the vibrator intensity to given integer input. That'll
+ * be a value between the boundaries set by get(Max|Min)Intensity
+ * (see below), and it's meant to be locally interpreted/used.
+ */
+
+ public static boolean setIntensity(int intensity) {
+
+ int finalValue = intensity - 60;
+ if (finalValue < 0) { finalValue *= -1;}
+
+ return FileUtils.writeLine(PATH, String.valueOf(finalValue));
+ }
+
+ /*
+ * What's the maximum integer value we take for setIntensity()?
+ */
+
+ public static int getMaxIntensity() {
+ return 60; // 0
+ }
+
+ /*
+ * What's the minimum integer value we take for setIntensity()?
+ */
+
+ public static int getMinIntensity() {
+ return 0; // 60
+ }
+
+ /*
+ * Is there a value between the 2 above which is considered
+ * the safe max? If not, return anything < 0
+ */
+
+ public static int getWarningThreshold() {
+ return 50; // 10
+ }
+
+ /*
+ * What's the current intensity value?
+ */
+
+ public static int getCurIntensity() {
+ int finalValue = Integer.parseInt(FileUtils.readOneLine(PATH));
+
+ // Invert the max / min returned values
+
+ finalValue *= -1;
+ finalValue += 60;
+
+ return finalValue;
+ }
+
+ /*
+ * What's the shipping intensity value?
+ */
+
+ public static int getDefaultIntensity() {
+ return 50; //10
+ }
+}
diff --git a/configs/adm.sqlite-u8500 b/configs/adm.sqlite-u8500
new file mode 100644
index 0000000..91dd26d
Binary files /dev/null and b/configs/adm.sqlite-u8500 differ
diff --git a/configs/compass b/configs/compass
new file mode 100644
index 0000000..99893be
--- /dev/null
+++ b/configs/compass
@@ -0,0 +1,14 @@
+#!/system/bin/sh
+
+# Default values for compass calibration,
+# this is a workaround only, to make it
+# work from the first boot without calibrating
+# it manually.
+
+cfg_path="/data/system/yas.cfg"
+
+if [ ! -f $cfg_path ]
+then
+ echo -n "-1,-3,9,256815,32824,-972243,3,127,127,127,2147483647,2147483647,2147483647,0," > $cfg_path
+ chmod 0644 $cfg_path
+fi
diff --git a/configs/gps.conf b/configs/gps.conf
new file mode 100644
index 0000000..1381cb4
--- /dev/null
+++ b/configs/gps.conf
@@ -0,0 +1,7 @@
+NTP_SERVER=north-america.pool.ntp.org
+XTRA_SERVER_1=http://xtra1.gpsonextra.net/xtra.bin
+XTRA_SERVER_2=http://xtra2.gpsonextra.net/xtra.bin
+XTRA_SERVER_3=http://xtra3.gpsonextra.net/xtra.bin
+SUPL_HOST=supl.google.com
+SUPL_PORT=7276
+
diff --git a/configs/manuf_id.cfg b/configs/manuf_id.cfg
deleted file mode 100644
index 6c55b3f..0000000
--- a/configs/manuf_id.cfg
+++ /dev/null
@@ -1 +0,0 @@
-ST-Ericsson
diff --git a/configs/model_id.cfg b/configs/model_id.cfg
deleted file mode 100644
index 94b77a4..0000000
--- a/configs/model_id.cfg
+++ /dev/null
@@ -1 +0,0 @@
-GT-I9070
diff --git a/configs/sirfgps.conf b/configs/sirfgps.conf
new file mode 100644
index 0000000..edee41e
--- /dev/null
+++ b/configs/sirfgps.conf
@@ -0,0 +1,38 @@
+#CSR SiRF plc
+#PROJECT_NAME : white Space is not allowed
+#UART_DRIVER : Uart Driver Path
+#RESET_GPIO : Reset GPIO Driver Path
+#ONOFF_GPIO : OnOff GPIO Driver Path
+#EXTERNAL_LNA : 1 - use External LNA, 0 - use Internal LNA only
+#REF_CLOCK_26MHZ: 1 - use 26MHz TCXO, 0 - use 16.369MHz TCXO
+#UART_BAUD_RATE : 0 - 115200bps 1 - 230400, 2 - 460800, 3 - 57600
+#FREQUENCY_AIDING : 0 - Disable, 1 - Enable
+#SENSOR_AIDING : 0 - Disable, 1 - Enable
+#SET_ID_IMSI : 1 - Use IMSI for SET ID, 0 - Use MSISDN for SET ID, especially for Japan Network Operators
+#DEBUGGING_FILES : 0 - no log file, 1 - log files enabled
+#SSL_ENABLED : 0 - SSL Disabled, 1 - SSL Enabled
+#CERTI_VERSION : 0 - TLSv1 , 1 - SSLv3 , 2 - SSLv23
+#CP_RESPONSETIME : 0 - no priority, 1 - resposne priority time, 2 - resposne priority position ,3 - resposne priority use entire response time
+#REAIDING=20
+#CONTROL_PLANE : 1 - CP Enabled, 0 - CP Disabled, for MP3 player or PND
+#ATT_NETWORK_OPERATOR : 1 - for AT&T, 0 - for other network operator
+PROJECT=SAMSUNG_STE
+UART_DRIVER=/dev/ttyAMA1
+RESET_GPIO=/sys/class/sec/gps/GPS_nRST/value
+ONOFF_GPIO=/sys/class/sec/gps/GPS_ON_OFF/value
+EXTERNAL_LNA=1
+REF_CLOCK_26MHZ=1
+UART_BAUD_RATE=2
+FREQUENCY_AIDING=0
+SENSOR_AIDING=0
+SET_ID_IMSI=1
+DEBUGGING_FILES=0
+STE=1
+SSL_ENABLED=0
+CERTI_VERSION=0
+CP_RESPONSETIME=2
+CONTROL_PLANE=1
+ATT_NETWORK_OPERATOR=0
+EMC_ENABLE=0
+SGEE=0
+LOG_PATH=/data
\ No newline at end of file
diff --git a/configs/ste_modem.sh b/configs/ste_modem.sh
new file mode 100644
index 0000000..decafb2
--- /dev/null
+++ b/configs/ste_modem.sh
@@ -0,0 +1,106 @@
+#!/system/bin/sh
+
+MCE_CFG=/modemfs/CONF/MCE/MCE.CFG
+PMST_CFG=/modemfs/PERM/PLAIN/PMST.CFG
+TRACE_AUTO_CONF=/modemfs/trace_auto.conf
+JIG_SMD=/sys/class/usb_switch/FSA_SWITCH/jig_smd
+
+if cat /sys/class/usb_switch/FSA_SWITCH/jig_smd ; then
+ echo "[JIG USB] detected";
+ echo "[Boot Mode] SMD";
+ echo "[MODEM] local mode";
+ echo -en "\x01" > $MCE_CFG
+ echo "[MODEM] non sleep mode";
+ echo -en "\xff\xff\x60\x60" > $PMST_CFG
+else
+ echo "[JIG USB] Not detected";
+ if ls /linuxrc > /dev/null ; then
+ echo "[Boot Mode] HATS";
+ echo "[modem] local mode";
+ echo -en "\x01" > /mnt$MCE_CFG
+ echo "[MODEM] non sleep mode";
+ echo -en "\xff\xff\x60\x60" > /mnt$PMST_CFG
+# rm /mnt/modemfs/RFHAL/*
+# cp -r /mnt/modemfs/RFHAL_const/* /mnt/modemfs/RFHAL/
+ else
+ echo "[Boot Mode] Normal";
+ echo "[modem] normal mode.";
+ echo -en "\x00" > $MCE_CFG
+ echo "[modem] sleep mode";
+ echo -en "\xff\xff\xff\xff" > $PMST_CFG
+ fi
+fi
+
+# chown for test application
+if ls $MCE_CFG > /dev/null ; then
+ chown radio.radio $MCE_CFG
+fi
+if ls $PMST_CFG > /dev/null ; then
+ chown radio.radio $PMST_CFG
+fi
+if ls $TRACE_AUTO_CONF > /dev/null ; then
+chown radio.radio $TRACE_AUTO_CONF
+fi
+if ls $JIG_SMD > /dev/null ; then
+ chown radio.radio $JIG_SMD
+fi
+
+# Start CSPSA2NWM which uses CSPSA server to copy radio parameters
+# from CSPSA and store them as files in the file system in the way expected
+# by NWM. Note that this process does not background itself, but rather
+# blocks until the copying has completed.
+
+#echo "Synchronizing modem parameters from CSPSA to file system"
+#mv /modemfs/guardfile /modemfs/GUARDFIL
+#/system/bin/cspsa2nwm -r / -u 0xfffffffd:0 -g /modemfs/GUARDFIL -p /modemfs/RFHAL CSPSA0
+
+# This is a initial script for copying a default calibration data.
+# After device downloading, phone calibration data is erased.
+# so it is necessary to copy a backup data.
+
+echo "Synchronizing modem parameter & CAL data";
+
+MODEMFS_GUARD=/modemfs/GUARDFIL
+MODEMFS_RFHAL=/modemfs/RFHAL
+EFS_GUARD=/efs/GUARDFIL
+EFS_RFHAL=/efs/RFHAL
+
+if ! ls $MODEMFS_GUARD > /dev/null ; then
+ if ! ls $EFS_GUARD > /dev/null ; then
+ echo "There is no CAL data. Copy the default modem CAL data to modemfs partition.";
+ if ! ls $MODEMFS_RFHAL > /dev/null ; then
+ cp -r /efs/RFHAL.DEF /modemfs/RFHAL
+# else
+# cp -r /efs/RFHAL.DEF/* /modemfs/RFHAL/
+ fi
+ else
+ echo "modemfs partition is erased. Copy the previous CAL data to modemfs partition.";
+ if ! ls $MODEMFS_RFHAL > /dev/null ; then
+ cp -r /efs/RFHAL /modemfs/RFHAL
+ else
+ cp -r /efs/RFHAL/* /modemfs/RFHAL/
+ fi
+ echo 0 > /modemfs/GUARDFIL
+ fi
+else
+ if ! ls $EFS_GUARD > /dev/null ; then
+ if ! ls $EFS_RFHAL > /dev/null ; then
+ cp -r /modemfs/RFHAL /efs/RFHAL
+ else
+ cp -r /modemfs/RFHAL/* /efs/RFHAL/
+ fi
+ echo 0 > /efs/GUARDFIL
+ fi
+fi
+
+# Flushing MCE.CFG and PMST.CFG before executing MSA
+echo "Sync for MCE.CFG and PMST.CFG";
+sync
+
+# Finally start Modem Storage Agent, serving files system requests from the
+# modem. It is important that this process does not background itself since
+# Androids init will restart this script once this command returns. The
+# necessary device nodes were created by /system/etc/ste_audio_mknods.sh
+# prior to executing this command.
+echo "Starting Modem Storage Agent"
+exec /system/bin/logwrapper /system/bin/msa -l stdout
diff --git a/configs/system_id.cfg b/configs/system_id.cfg
deleted file mode 100644
index 6d46bf7..0000000
--- a/configs/system_id.cfg
+++ /dev/null
@@ -1 +0,0 @@
-Not Available
diff --git a/janice.mk b/janice.mk
index af6ee0f..b5598f8 100644
--- a/janice.mk
+++ b/janice.mk
@@ -6,25 +6,41 @@ LOCAL_PATH := device/samsung/janice
# Overlay
DEVICE_PACKAGE_OVERLAYS += $(LOCAL_PATH)/overlay
-# This device is HDPI
-PRODUCT_AAPT_CONFIG := normal hdpi
-PRODUCT_AAPT_PREF_CONFIG := hdpi
+# STE
+PRODUCT_COPY_FILES += \
+ $(LOCAL_PATH)/configs/ste_modem.sh:system/etc/ste_modem.sh
+
+# Enable AAC 5.1 output
+PRODUCT_PROPERTY_OVERRIDES += \
+ media.aac_51_output_enabled=true
+
+# GPS
+PRODUCT_COPY_FILES += \
+ $(LOCAL_PATH)/configs/gps.conf:system/etc/gps.conf \
+ $(LOCAL_PATH)/configs/sirfgps.conf:system/etc/sirfgps.conf
-# Packages
-PRODUCT_PACKAGES += \
- GalaxyS2Settings
+# Compass workaround
+PRODUCT_COPY_FILES += \
+ $(LOCAL_PATH)/configs/compass:system/etc/init.d/compass
+
+$(call inherit-product, device/common/gps/gps_eu_supl.mk)
+
+# Init files
+PRODUCT_COPY_FILES += \
+ $(LOCAL_PATH)/rootdir/device_tunables.rc:root/device_tunables.rc \
+ $(LOCAL_PATH)/rootdir/fstab.samsungjanice:root/fstab.samsungjanice \
+ $(LOCAL_PATH)/rootdir/init.samsungjanice.rc:root/init.samsungjanice.rc \
+ $(LOCAL_PATH)/rootdir/init.recovery.samsungjanice.rc:root/init.recovery.samsungjanice.rc \
+ $(LOCAL_PATH)/rootdir/ueventd.samsungjanice.rc:root/ueventd.samsungjanice.rc
-# RIL
+# Permissions
PRODUCT_COPY_FILES += \
- $(LOCAL_PATH)/configs/manuf_id.cfg:/system/etc/AT/manuf_id.cfg \
- $(LOCAL_PATH)/configs/model_id.cfg:/system/etc/AT/model_id.cfg \
- $(LOCAL_PATH)/configs/system_id.cfg:/system/etc/AT/system_id.cfg
+ frameworks/native/data/etc/android.hardware.sensor.gyroscope.xml:system/etc/permissions/android.hardware.sensor.gyroscope.xml \
+ frameworks/native/data/etc/android.hardware.sensor.light.xml:system/etc/permissions/android.hardware.sensor.light.xml
-# Keylayout
+# Audio
PRODUCT_COPY_FILES += \
- $(LOCAL_PATH)/usr/keylayout/gpio-keys.kl:system/usr/keylayout/gpio-keys.kl \
- $(LOCAL_PATH)/usr/keylayout/janice-kp.kl:system/usr/keylayout/janice-kp.kl \
- $(LOCAL_PATH)/usr/keylayout/Vendor_04e8_Product_7021.kl:system/usr/keylayout/Vendor_04e8_Product_7021.kl
+ $(LOCAL_PATH)/configs/adm.sqlite-u8500:system/etc/adm.sqlite-u8500
# Use non-open-source parts if present
-$(call inherit-product-if-exists, vendor/samsung/janice/janice-vendor.mk)
+$(call inherit-product-if-exists, vendor/samsung/u8500-common/janice/janice-vendor-blobs.mk)
diff --git a/overlay/frameworks/base/core/res/res/values/config.xml b/overlay/frameworks/base/core/res/res/values/config.xml
new file mode 100644
index 0000000..aa654b1
--- /dev/null
+++ b/overlay/frameworks/base/core/res/res/values/config.xml
@@ -0,0 +1,87 @@
+
+
+
+
+
+
+
+ true
+
+
+
+ - 7
+ - 75
+ - 1000
+ - 10000
+
+
+
+
+ - 20
+ - 30
+ - 110
+ - 175
+ - 255
+
+
+
+
+ - 255
+ - 255
+ - 255
+ - 0
+ - 0
+
+
+
+ 4
+
+
+
+ true
+
+
diff --git a/overlay/frameworks/base/core/res/res/xml/power_profile.xml b/overlay/frameworks/base/core/res/res/xml/power_profile.xml
new file mode 100644
index 0000000..76031be
--- /dev/null
+++ b/overlay/frameworks/base/core/res/res/xml/power_profile.xml
@@ -0,0 +1,35 @@
+
+
+ - 0
+ - 75
+ - 17
+ - 0.3
+ - 201
+ - 0.3
+ - 83
+ - 52
+ - 34
+ - 265
+ - 242
+ - 82
+ - 1
+
+ 2.7
+ 3
+
+
+ 10000000
+ 800000
+ 400000
+ 200000
+
+ - 2
+ - 15
+
+ 408
+ 249
+ 110
+ 55
+
+ - 1500
+
diff --git a/overlay/packages/apps/Mms/res/xml/mms_config.xml b/overlay/packages/apps/Mms/res/xml/mms_config.xml
new file mode 100644
index 0000000..008ee3a
--- /dev/null
+++ b/overlay/packages/apps/Mms/res/xml/mms_config.xml
@@ -0,0 +1,61 @@
+
+
+ true
+
+
+ 307200
+
+
+ 768
+
+
+ 1024
+
+
+ 500
+
+
+ 50
+
+
+ 10
+
+
+ 5000
+
+
+ http://wap.samsungmobile.com/uaprof/GT-I9070.xml
+
+
+ -1
+
+
+ 4
+
+
+ true
+
+
+ false
+
+
+ true
+
+
+ -1
+
+
+ Samsung GT-i9070 (Samsung Galaxy S Advance)
+
diff --git a/recovery.fstab b/recovery.fstab
deleted file mode 100644
index 7c803b7..0000000
--- a/recovery.fstab
+++ /dev/null
@@ -1,11 +0,0 @@
-/system ext4 /dev/block/mmcblk0p3
-/cache ext4 /dev/block/mmcblk0p4
-/data ext4 /dev/block/mmcblk0p5
-/efs ext4 /dev/block/mmcblk0p7
-/preload ext4 /dev/block/mmcblk0p9
-
-/sdcard vfat /dev/block/mmcblk0p8
-/external_sd vfat /dev/block/mmcblk1p1
-
-/boot emmc /dev/block/mmcblk0p15
-#kernel2 emmc /dev/block/mmcblk0p17
diff --git a/rootdir/device_tunables.rc b/rootdir/device_tunables.rc
new file mode 100644
index 0000000..ee37b37
--- /dev/null
+++ b/rootdir/device_tunables.rc
@@ -0,0 +1,56 @@
+on property:sys.boot_completed=1
+ # System permissions for NovaThor Settings package and CyanogenMod Hardware Abstraction Framework
+ chown system system /proc/sys/net/ipv4/tcp_congestion_control
+ chown system system /sys/block/mmcblk0/queue/read_ahead_kb
+ chown system system /sys/class/camera/flash/burning_led
+ chown system system /sys/kernel/s6e63m0/color/main_R
+ chown system system /sys/kernel/s6e63m0/color/main_G
+ chown system system /sys/kernel/s6e63m0/color/main_B
+ chown system system /sys/devices/system/cpu/sched_mc_power_savings
+ chown system system /sys/kernel/abb-charger/charger_curr
+ chown system system /sys/kernel/abb-charger/max_ac_c
+ chown system system /sys/kernel/abb-charger/max_usb_c
+ chown system system /sys/kernel/abb-codec/addiggain2
+ chown system system /sys/kernel/abb-codec/anagain3
+ chown system system /sys/kernel/abb-codec/chargepump
+ chown system system /sys/kernel/abb-codec/classdhpg
+ chown system system /sys/kernel/abb-codec/classdwg
+ chown system system /sys/kernel/abb-codec/eardiggain
+ chown system system /sys/kernel/abb-codec/hsdaclowpow
+ chown system system /sys/kernel/abb-codec/hshpen
+ chown system system /sys/kernel/abb-codec/hsldiggain
+ chown system system /sys/kernel/abb-codec/hslowpow
+ chown system system /sys/kernel/abb-codec/hsrdiggain
+ chown system system /sys/kernel/abb-codec/lpa_mode
+ chown system system /sys/kernel/abb-fg/fg_cyc
+ chown system system /sys/kernel/abb-fg/fg_refresh
+ chown system system /sys/kernel/abb-ponkey/emulator
+ chown system system /sys/kernel/abb-regu/VOTG
+ chown system system /sys/kernel/debug/cpuidle/deepest_state
+ chown system system /sys/kernel/fsync/mode
+ chown system system /sys/kernel/liveopp/arm_step00
+ chown system system /sys/kernel/liveopp/arm_step01
+ chown system system /sys/kernel/liveopp/arm_step02
+ chown system system /sys/kernel/liveopp/arm_step03
+ chown system system /sys/kernel/liveopp/arm_step04
+ chown system system /sys/kernel/liveopp/arm_step05
+ chown system system /sys/kernel/liveopp/arm_step06
+ chown system system /sys/kernel/liveopp/arm_step07
+ chown system system /sys/kernel/liveopp/arm_step08
+ chown system system /sys/kernel/liveopp/arm_step09
+ chown system system /sys/kernel/liveopp/arm_step10
+ chown system system /sys/kernel/mali/mali_auto_boost
+ chown system system /sys/kernel/mali/mali_boost_delay
+ chown system system /sys/kernel/mali/mali_boost_high
+ chown system system /sys/kernel/mali/mali_boost_low
+ chown system system /sys/kernel/mali/mali_dvfs_config
+ chown system system /sys/kernel/mali/mali_gpu_clock
+ chown system system /sys/kernel/mali/mali_gpu_fullspeed
+ chown system system /sys/kernel/mxt224e/sweep2wake
+ chown system system /sys/kernel/mxt224e/threshold_t48
+ chown system system /sys/module/dhd/parameters/dhdpm_fast
+ chown system system /sys/module/mali/parameters/mali_l2_max_reads
+ chown system system /sys/module/mali/parameters/pre_allocated_memory_size_max
+ chown system system /sys/module/mmc_core/parameters/use_spi_crc
+ chown system system /sys/vibrator/pwm_value
+ write /sys/kernel/mxt224e/threshold_t48 on
diff --git a/rootdir/fstab.samsungjanice b/rootdir/fstab.samsungjanice
new file mode 100644
index 0000000..34384cb
--- /dev/null
+++ b/rootdir/fstab.samsungjanice
@@ -0,0 +1,22 @@
+# Android fstab file.
+# The filesystem that contains the filesystem checker binary (typically /system) cannot
+# specify MF_CHECK, and must come before any filesystems that do specify MF_CHECK
+# Data partition must be located at the bottom for supporting device encryption
+
+#
+/dev/block/mmcblk0p3 /system ext4 ro,noatime,errors=panic wait
+/dev/block/mmcblk0p2 /modemfs ext4 noatime,nosuid,nodev,journal_async_commit,errors=panic wait,check
+/dev/block/mmcblk0p4 /cache ext4 noatime,nosuid,nodev,journal_async_commit,errors=panic wait,check
+/dev/block/mmcblk0p7 /efs ext4 noatime,nosuid,nodev,journal_async_commit,errors=panic wait,check
+/dev/block/mmcblk0p9 /preload ext4 ro,noatime,errors=panic wait
+/dev/block/mmcblk0p5 /data ext4 noatime,nosuid,nodev,discard,noauto_da_alloc,journal_async_commit,errors=panic wait,check,encryptable=/efs/metadata
+
+# Vold managed volumes
+/devices/sdi2/mmc_host/mmc0/mmc0 auto auto defaults voldmanaged=sdcard0:8,nonremovable,noemulatedsd
+/devices/sdi0/mmc_host/mmc1/mmc1 auto auto defaults voldmanaged=sdcard1:auto
+
+# Recovery
+/dev/block/mmcblk0p15 /boot emmc defaults recoveryonly
+
+# ZRAM
+/dev/block/zram0 none swap defaults zramsize=104857600
diff --git a/rootdir/init.recovery.samsungjanice.rc b/rootdir/init.recovery.samsungjanice.rc
new file mode 100644
index 0000000..ffe530d
--- /dev/null
+++ b/rootdir/init.recovery.samsungjanice.rc
@@ -0,0 +1,40 @@
+on init
+ write /sys/devices/platform/ab8500-i2c.0/ab8500-usb.0/boot_time_device 1
+
+on early-fs
+ mount ext4 /dev/block/mmcblk0p3 /system noatime wait
+
+ mkdir /efs
+ mount ext4 /dev/block/mmcblk0p7 /efs nosuid nodev noatime wait
+
+ # J4FS(lfs) mount points.
+ mkdir /mnt 0775 root root
+ mkdir /mnt/.lfs 0755 root root
+
+ # Install Kernel Module
+ insmod /system/lib/modules/j4fs.ko
+ insmod /system/lib/modules/param.ko
+
+ mount j4fs /dev/block/mmcblk0p1 /mnt/.lfs wait
+
+# Always start adbd on userdebug and eng builds
+# In recovery, always run adbd as root.
+on property:ro.debuggable=1
+ write /sys/class/android_usb/android0/enable 0
+ write /sys/class/android_usb/android0/idVendor 04e8
+ write /sys/class/android_usb/android0/idProduct 6860
+ write /sys/class/android_usb/android0/functions adb
+ write /sys/class/android_usb/android0/enable 1
+ write /sys/class/android_usb/android0/iManufacturer $ro.product.manufacturer
+ write /sys/class/android_usb/android0/iProduct $ro.product.model
+ write /sys/class/android_usb/android0/iSerial $ro.serialno
+ write /sys/devices/platform/ab8500-i2c.0/ab8500-usb.0/boot_time_device 1
+ start adbd
+ setprop service.adb.root 1
+
+# Restart adbd so it can run as root
+on property:service.adb.root=1
+ write /sys/class/android_usb/android0/enable 0
+ restart adbd
+ write /sys/class/android_usb/android0/enable 1
+ write /sys/devices/platform/ab8500-i2c.0/ab8500-usb.0/boot_time_device 1
diff --git a/rootdir/init.samsungjanice.rc b/rootdir/init.samsungjanice.rc
new file mode 100644
index 0000000..e013ac4
--- /dev/null
+++ b/rootdir/init.samsungjanice.rc
@@ -0,0 +1,152 @@
+import /init.u8500.rc
+
+on fs
+
+ mount_all /fstab.samsungjanice
+ swapon_all /fstab.samsungjanice
+
+on post-fs
+
+ chown radio radio /modemfs/APPL
+ mkdir /modemfs/APPL
+ chmod 0755 /modemfs/APPL
+ mkdir /modemfs/BOOT
+ chown radio radio /modemfs/BOOT
+ chmod 0755 /modemfs/BOOT
+ mkdir /modemfs/DO
+ chown radio radio /modemfs/DO
+ chmod 0755 /modemfs/DO
+ mkdir /modemfs/LOG
+ chown radio radio /modemfs/LOG
+ chmod 0755 /modemfs/LOG
+ mkdir /modemfs/TMP
+ chown radio radio /modemfs/TMP
+ chmod 0755 /modemfs/TMP
+
+ mkdir /data/mediaserver 0740 media media
+
+ # Samsung Device permissions
+ chown root system /dev/mmc328x
+ chown root system /dev/bma222
+ chown root system /dev/ecompass_ctrl
+ chmod 0666 /dev/mmc328x
+ chmod 0666 /dev/bma222
+ chmod 0666 /dev/ecompass_ctrl
+
+ # Change the permission sensor chips
+ chown root root /dev/rn5t592
+ chmod 777 /dev/rn5t592
+
+ # Change permission for touchscreen and touch key
+ chown system system /sys/class/sec/sec_touchkey/touch_sensitivity
+ chown system system /sys/class/sec/tsp_noise_test/disp_all_refdata
+ chown system system /sys/class/sec/tsp_noise_test/disp_all_deltadata
+ chown system system /sys/class/sec/sec_touchscreen/tsp_threshold
+
+ # Samsung: ensure read/write access to sensor control device files
+ chmod 0666 /dev/gp2a_prox
+ chmod 0666 /dev/gp2a_light
+ chmod 0666 /dev/mpu60x0_gyro
+ chmod 0666 /dev/mpu60x0_accel
+ chmod 0666 /dev/mmc3280
+
+ # Change permission for gyro_sensor
+ chown system system /sys/class/sensors/gyro_sensor/temperature
+
+on post-fs-data
+
+ mkdir /data/media 0770 media_rw media_rw
+ chown media_rw media_rw /data/media
+ # give system access to wpa_supplicant.conf for backup and restore
+ mkdir /data/misc/bluetoothd 0770 bluetooth bluetooth
+ mkdir /data/misc/bluetooth 0770 system system
+ mkdir /data/misc/wifi 0770 wifi wifi
+ mkdir /data/misc/wifi/sockets 0770 wifi wifi
+ mkdir /data/misc/dhcp 0775 dhcp dhcp
+ chmod 0770 /data/misc/wifi
+ chmod 0660 /data/misc/wifi/wpa_supplicant.conf
+ chmod 0660 /data/misc/wifi/p2p_supplicant.conf
+ mkdir /data/misc/wifi/hostapd.sockets 0770 wifi wifi
+
+ mkdir /data/misc/dhcp 0775 dhcp dhcp
+ chown dhcp dhcp /data/misc/dhcp
+ chown system system /efs/wifi/.mac.info
+ chmod 0664 /efs/wifi/.mac.info
+
+ # After we setup wireless subsystem, let dnsmasq create files for soft ap
+ chown dhcp system /data/misc/dhcp
+
+ # Set indication (checked by vold) that we have finished this action
+ setprop vold.post_fs_data_done 1
+
+on boot
+
+ # Set timeout value for rmnet stats.
+ write /sys/devices/virtual/net/rmnet0/timeout_suspend 5000000
+
+ chown system system /sys/class/backlight/pri_lcd_bl/brightness
+ chown system system /sys/class/backlight/pwm-backlight/brightness
+ chown system system /sys/class/backlight/pwm-backlight/device/lcd_power
+ chown system system /sys/class/backlight/pwm-backlight/device/panel_id
+ chown system system /sys/class/backlight/pwm-backlight/device/acl_set
+ chown system system /sys/class/lcd/panel/device/gamma_mode
+ chown system system /sys/class/lcd/panel/device/gamma_table
+ chown system system /sys/class/leds/button-backlight/brightness
+
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-005c/enable
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-0029/power_state
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-0068/range
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-0068/datarate
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-0068/powermode
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-001e/mode
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-001e/range
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-001e/rate
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-0018/range
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-0018/mode
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-0018/rate
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-0018/sleep_wake
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-0019/mode
+ chown system system /sys/devices/platform/nmk-i2c.2/i2c-2/2-0019/range
+ chown system system /sys/devices/platform/sim-detect.0/voltage
+
+ # Vibetonz
+ chmod 0660 /dev/tspdrv
+ chown root shell /dev/tspdrv
+
+ # Bluetooth MAC address programming
+ chown bluetooth bluetooth /system/etc/bt_addr
+
+ # Permissions for LCD
+ chown system system /sys/class/backlight/panel/auto_brightness
+ chown system media_rw /sys/class/lcd/panel/power_reduce
+ chown system system /sys/class/sec/sec_touchkey/brightness
+
+ # Define TCP buffer sizes for various networks
+ # ReadMin, ReadInitial, ReadMax, WriteMin, WriteInitial, WriteMax,
+ setprop net.tcp.buffersize.default 4096,87380,704512,4096,16384,110208
+ setprop net.tcp.buffersize.lte 4096,87380,1220608,4096,16384,563200
+ setprop net.tcp.buffersize.umts 4096,87380,563200,4096,16384,110208
+ setprop net.tcp.buffersize.hspa 4096,87380,704512,4096,16384,110208
+ setprop net.tcp.buffersize.hsupa 4096,87380,704512,4096,16384,262144
+ setprop net.tcp.buffersize.hsdpa 4096,87380,704512,4096,16384,262144
+ setprop net.tcp.buffersize.hspap 4096,87380,1220608,4096,16384,393216
+ setprop net.tcp.buffersize.edge 4096,26280,35040,4096,16384,35040
+ setprop net.tcp.buffersize.gprs 4096,8760,11680,4096,8760,11680
+ setprop net.tcp.buffersize.evdo 4096,87380,563200,4096,16384,262144
+ setprop net.tcp.buffersize.evdo_b 4096,87380,704512,4096,16384,262144
+
+service mtpd /system/bin/mtpd
+ socket mtpd stream 600 system system
+ user vpn
+ group vpn net_admin net_raw
+ disabled
+ oneshot
+
+on property:ro.data.large_tcp_window_size=true
+ # We enable receiving of high-speed conections via ipv4
+ write /proc/sys/net/ipv4/tcp_adv_win_scale 1
+
+service hostapd_bin /system/bin/hostapd -dd /data/misc/wifi/hostapd.conf
+ socket wpa_wlan0 dgram 660 wifi wifi
+ disabled
+ oneshot
diff --git a/rootdir/ueventd.samsungjanice.rc b/rootdir/ueventd.samsungjanice.rc
new file mode 100644
index 0000000..8134ffb
--- /dev/null
+++ b/rootdir/ueventd.samsungjanice.rc
@@ -0,0 +1,62 @@
+# NMF CM devices
+/dev/cm_channel 0660 media system
+/dev/cm_control 0660 media system
+/dev/cm_sia_trace 0444 media system
+/dev/cm_sva_trace 0444 media system
+
+
+# XTI trace device
+/dev/stm 0660 media system
+
+# modem driver - CS-Call
+/dev/modemaudio 0660 audio audio
+
+# camera and flash devices
+/dev/mmio_camera 0660 media system
+/dev/camera_flash 0660 media system
+
+# Sensor i2c
+/dev/i2c-2 0660 media system
+/dev/i2c-4 0660 system system
+
+# PWR QOS devices
+/dev/ape_opp 0660 media system
+/dev/ddr_opp 0660 media system
+
+# hwmem driver
+/dev/hwmem 0666 media system
+
+# Mali 3D IP
+/dev/mali 0666 system graphics
+
+# B2R2 device
+/dev/b2r2_blt 0666 system graphics
+
+# overlay device
+/dev/disp0 0666 system graphics
+
+# overlay device
+/dev/comp0 0666 system graphics
+
+# AT USB device - used by ATC
+/dev/ttyGS0 0060 root radio
+
+#permission for dun
+/dev/dun 0660 system system
+
+# modem storage pipe
+/dev/rpc 0600 radio radio
+
+# Trusted Eexecution Engine
+/dev/tee 0666 root system
+
+/dev/socket/cops.socket 0777 nobody nobody
+/dev/socket/cspsa_socket_CSPSA0 0666 root root
+/dev/db8500-modem-trace 0600 root root
+/dev/dbx500_mloader_fw 0600 root root
+/dev/block/mmcblk0p19 0660 system system
+
+# Sensors
+/dev/mpu 0660 system system
+/dev/mpuirq 0660 system system
+/dev/timerirq 0660 system system
diff --git a/system.prop b/system.prop
index 1705cd4..71121e4 100644
--- a/system.prop
+++ b/system.prop
@@ -8,16 +8,9 @@ rild.libargs=-d /dev/ttyS0
ro.sf.lcd_density=240
ro.lcd_min_brightness=30
-# disable hw vsync
-debug.hwui.render_dirty_regions=false
-debug.sf.no_hw_vsync=1
-
# STE: Low power audio - enable ULP mode
ste.nmf.autoidle=1
-# STE: Address of DBus STE bus
-ste.dbus.bus.address=unix:path=/dev/socket/dbus_ste
-
# STE: UNSOL_CALL_RING is only sent once from RIL.
# Android needs to generate more rings if needed.
ro.telephony.call_ring.multiple=false
@@ -37,3 +30,11 @@ ste.cam.back.orientation=90
# STE: Camera file path configuration
ste.cam.ext.cfg.path.secondary=/system/usr/share/camera/config_file/samsung_s5k4ecgx_janice.dat
+
+# Hardware info
+ro.device.chipset=ST-Ericsson NovaThor U8500 (45nm)
+ro.device.cpu=ARMv7 1GHz Dual-core ARM Cortex-A9
+ro.device.gpu=Mali-400MP Single Core
+ro.device.rear_cam=5 Mpix (2592x1944)
+ro.device.front_cam=1.3 Mpix (1280x1024)
+ro.device.screen_res=4,0' 800x480 pixels ( ~233 ppi)
diff --git a/usr/keylayout/Vendor_04e8_Product_7021.kl b/usr/keylayout/Vendor_04e8_Product_7021.kl
deleted file mode 100644
index 3bb638c..0000000
--- a/usr/keylayout/Vendor_04e8_Product_7021.kl
+++ /dev/null
@@ -1,374 +0,0 @@
-# Copyright (C) 2010 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-# Samsung Mobile Keyboard for Android
-#
-key 1 BACK
-key 2 1
-key 3 2
-key 4 3
-key 5 4
-key 6 5
-key 7 6
-key 8 7
-key 9 8
-key 10 9
-key 11 0
-key 12 MINUS
-key 13 EQUALS
-key 14 DEL
-key 15 TAB
-key 16 Q
-key 17 W
-key 18 E
-key 19 R
-key 20 T
-key 21 Y
-key 22 U
-key 23 I
-key 24 O
-key 25 P
-key 26 LEFT_BRACKET
-key 27 RIGHT_BRACKET
-key 28 ENTER
-key 29 CTRL_LEFT
-key 30 A
-key 31 S
-key 32 D
-key 33 F
-key 34 G
-key 35 H
-key 36 J
-key 37 K
-key 38 L
-key 39 SEMICOLON
-key 40 APOSTROPHE
-key 41 GRAVE
-key 42 SHIFT_LEFT
-key 43 BACKSLASH
-key 44 Z
-key 45 X
-key 46 C
-key 47 V
-key 48 B
-key 49 N
-key 50 M
-key 51 COMMA
-key 52 PERIOD
-key 53 SLASH
-key 54 SHIFT_RIGHT
-key 55 NUMPAD_MULTIPLY
-key 56 ALT_LEFT
-key 57 SPACE
-key 58 CAPS_LOCK
-key 59 F1
-key 60 F2
-key 61 F3
-key 62 F4
-key 63 F5
-key 64 F6
-key 65 F7
-key 66 F8
-key 67 F9
-key 68 F10
-key 69 NUM_LOCK
-key 70 SCROLL_LOCK
-key 71 NUMPAD_7
-key 72 NUMPAD_8
-key 73 NUMPAD_9
-key 74 NUMPAD_SUBTRACT
-key 75 NUMPAD_4
-key 76 NUMPAD_5
-key 77 NUMPAD_6
-key 78 NUMPAD_ADD
-key 79 NUMPAD_1
-key 80 NUMPAD_2
-key 81 NUMPAD_3
-key 82 NUMPAD_0
-key 83 NUMPAD_DOT
-# key 84 (undefined)
-# key 85 "KEY_ZENKAKUHANKAKU"
-key 86 BACKSLASH
-key 87 F11
-key 88 F12
-# key 89 "KEY_RO"
-# key 90 "KEY_KATAKANA"
-# key 91 "KEY_HIRAGANA"
-# key 92 "KEY_HENKAN"
-# key 93 "KEY_KATAKANAHIRAGANA"
-# key 94 "KEY_MUHENKAN"
-key 95 NUMPAD_COMMA
-key 96 NUMPAD_ENTER
-key 97 CTRL_RIGHT
-key 98 NUMPAD_DIVIDE
-key 99 SYSRQ
-key 100 ALT_GR
-# key 101 "KEY_LINEFEED"
-key 102 MOVE_HOME
-key 103 DPAD_UP
-key 104 PAGE_UP
-key 105 DPAD_LEFT
-key 106 DPAD_RIGHT
-key 107 MOVE_END
-key 108 DPAD_DOWN
-key 109 PAGE_DOWN
-key 110 INSERT
-key 111 FORWARD_DEL
-# key 112 "KEY_MACRO"
-key 113 VOLUME_MUTE
-key 114 VOLUME_DOWN
-key 115 VOLUME_UP
-key 116 POWER WAKE
-key 117 NUMPAD_EQUALS
-# key 118 "KEY_KPPLUSMINUS"
-key 119 BREAK
-# key 120 (undefined)
-key 121 NUMPAD_COMMA
-# key 122 "KEY_HANGEUL"
-# key 123 "KEY_HANJA"
-# key 124 "KEY_YEN"
-key 125 META_LEFT
-key 126 META_RIGHT
-key 127 MENU WAKE_DROPPED
-key 128 MEDIA_STOP
-# key 129 "KEY_AGAIN"
-# key 130 "KEY_PROPS"
-# key 131 "KEY_UNDO"
-# key 132 "KEY_FRONT"
-# key 133 "KEY_COPY"
-# key 134 "KEY_OPEN"
-# key 135 "KEY_PASTE"
-# key 136 "KEY_FIND"
-# key 137 "KEY_CUT"
-# key 138 "KEY_HELP"
-key 139 MENU WAKE_DROPPED
-# key 140 "KEY_CALC"
-# key 141 "KEY_SETUP"
-# key 142 "KEY_SLEEP"
-# key 143 "KEY_WAKEUP"
-# key 144 "KEY_FILE"
-# key 145 "KEY_SENDFILE"
-# key 146 "KEY_DELETEFILE"
-# key 147 "KEY_XFER"
-# key 148 "KEY_PROG1"
-# key 149 "KEY_PROG2"
-key 150 EXPLORER
-# key 151 "KEY_MSDOS"
-key 152 POWER WAKE
-# key 153 "KEY_DIRECTION"
-# key 154 "KEY_CYCLEWINDOWS"
-key 155 EMAIL
-key 156 BOOKMARK
-# key 157 "KEY_COMPUTER"
-key 158 BACK WAKE_DROPPED
-key 159 FORWARD
-key 160 MEDIA_CLOSE
-key 161 MEDIA_EJECT
-key 162 MEDIA_EJECT
-key 163 MEDIA_NEXT
-key 164 MEDIA_PLAY_PAUSE
-key 165 MEDIA_PREVIOUS
-key 166 MEDIA_STOP
-key 167 MEDIA_RECORD
-key 168 MEDIA_REWIND
-key 169 CALL
-# key 170 "KEY_ISO"
-# key 171 "KEY_CONFIG"
-key 172 HOME
-# key 173 "KEY_REFRESH"
-# key 174 "KEY_EXIT"
-# key 175 "KEY_MOVE"
-# key 176 "KEY_EDIT"
-key 177 PAGE_UP
-key 178 PAGE_DOWN
-key 179 NUMPAD_LEFT_PAREN
-key 180 NUMPAD_RIGHT_PAREN
-# key 181 "KEY_NEW"
-# key 182 "KEY_REDO"
-# key 183 F13
-# key 184 F14
-# key 185 F15
-# key 186 F16
-# key 187 F17
-# key 188 F18
-# key 189 F19
-# key 190 F20
-# key 191 F21
-# key 192 F22
-# key 193 F23
-# key 194 F24
-# key 195 (undefined)
-# key 196 (undefined)
-# key 197 (undefined)
-# key 198 (undefined)
-# key 199 (undefined)
-key 200 MEDIA_PLAY
-key 201 MEDIA_PAUSE
-# key 202 "KEY_PROG3"
-# key 203 "KEY_PROG4"
-# key 204 (undefined)
-# key 205 "KEY_SUSPEND"
-# key 206 "KEY_CLOSE"
-key 207 MEDIA_PLAY
-key 208 MEDIA_FAST_FORWARD
-# key 209 "KEY_BASSBOOST"
-# key 210 "KEY_PRINT"
-# key 211 "KEY_HP"
-key 212 CAMERA
-# key 213 "KEY_SOUND"
-# key 214 "KEY_QUESTION"
-key 215 ENVELOPE
-# key 216 "KEY_CHAT"
-key 217 SEARCH
-# key 218 "KEY_CONNECT"
-# key 219 "KEY_FINANCE"
-# key 220 "KEY_SPORT"
-# key 221 "KEY_SHOP"
-# key 222 "KEY_ALTERASE"
-# key 223 "KEY_CANCEL"
-key 224 BRIGHTNESS_DOWN
-key 225 BRIGHTNESS_UP
-key 226 HEADSETHOOK
-key 227 STAR
-key 228 POUND
-key 229 SOFT_LEFT
-key 230 SOFT_RIGHT
-key 231 CALL
-key 232 DPAD_CENTER
-key 233 HEADSETHOOK
-# key 234 "KEY_0_5" or "KEY_SAVE"
-# key 235 "KEY_2_5" or "KEY_DOCUMENTS"
-# key 236 "KEY_SWITCHVIDEOMODE" or "KEY_BATTERY"
-# key 237 "KEY_KBDILLUMTOGGLE"
-# key 238 "KEY_KBDILLUMDOWN"
-# key 239 "KEY_KBDILLUMUP"
-# key 240 "KEY_UNKNOWN"
-key 304 BUTTON_A
-key 305 BUTTON_B
-key 306 BUTTON_C
-key 307 BUTTON_X
-key 308 BUTTON_Y
-key 309 BUTTON_Z
-key 310 BUTTON_L1
-key 311 BUTTON_R1
-key 312 BUTTON_L2
-key 313 BUTTON_R2
-key 314 BUTTON_SELECT
-key 315 BUTTON_START
-key 316 BUTTON_MODE
-key 317 BUTTON_THUMBL
-key 318 BUTTON_THUMBR
-# key 352 "KEY_OK"
-# key 353 "KEY_SELECT"
-# key 354 "KEY_GOTO"
-# key 355 "KEY_CLEAR"
-# key 356 "KEY_POWER2"
-# key 357 "KEY_OPTION"
-# key 358 "KEY_INFO"
-# key 359 "KEY_TIME"
-# key 360 "KEY_VENDOR"
-# key 361 "KEY_ARCHIVE"
-key 362 GUIDE
-# key 363 "KEY_CHANNEL"
-# key 364 "KEY_FAVORITES"
-# key 365 "KEY_EPG"
-key 366 DVR
-# key 367 "KEY_MHP"
-# key 368 "KEY_LANGUAGE"
-key 368 LANG
-# key 369 "KEY_TITLE"
-# key 370 "KEY_SUBTITLE"
-# key 371 "KEY_ANGLE"
-# key 372 "KEY_ZOOM"
-# key 373 "KEY_MODE"
-# key 374 "KEY_KEYBOARD"
-# key 375 "KEY_SCREEN"
-# key 376 "KEY_PC"
-key 377 TV
-# key 378 "KEY_TV2"
-# key 379 "KEY_VCR"
-# key 380 "KEY_VCR2"
-# key 381 "KEY_SAT"
-# key 382 "KEY_SAT2"
-# key 383 "KEY_CD"
-# key 384 "KEY_TAPE"
-# key 385 "KEY_RADIO"
-# key 386 "KEY_TUNER"
-# key 387 "KEY_PLAYER"
-# key 388 "KEY_TEXT"
-# key 389 "KEY_DVD"
-# key 390 "KEY_AUX"
-# key 391 "KEY_MP3"
-# key 392 "KEY_AUDIO"
-# key 393 "KEY_VIDEO"
-# key 394 "KEY_DIRECTORY"
-# key 395 "KEY_LIST"
-# key 396 "KEY_MEMO"
-# key 397 "KEY_CALENDAR"
-# key 398 "KEY_RED"
-# key 399 "KEY_GREEN"
-# key 400 "KEY_YELLOW"
-# key 401 "KEY_BLUE"
-key 402 CHANNEL_UP
-key 403 CHANNEL_DOWN
-# key 404 "KEY_FIRST"
-# key 405 "KEY_LAST"
-# key 406 "KEY_AB"
-# key 407 "KEY_NEXT"
-# key 408 "KEY_RESTART"
-# key 409 "KEY_SLOW"
-# key 410 "KEY_SHUFFLE"
-# key 411 "KEY_BREAK"
-# key 412 "KEY_PREVIOUS"
-# key 413 "KEY_DIGITS"
-# key 414 "KEY_TEEN"
-# key 415 "KEY_TWEN"
-# key 448 "KEY_DEL_EOL"
-# key 449 "KEY_DEL_EOS"
-# key 450 "KEY_INS_LINE"
-# key 451 "KEY_DEL_LINE"
-key 464 FUNCTION
-key 465 ESCAPE FUNCTION
-key 466 F1 FUNCTION
-key 467 F2 FUNCTION
-key 468 F3 FUNCTION
-key 469 F4 FUNCTION
-key 470 F5 FUNCTION
-key 471 F6 FUNCTION
-key 472 F7 FUNCTION
-key 473 F8 FUNCTION
-key 474 F9 FUNCTION
-key 475 F10 FUNCTION
-key 476 F11 FUNCTION
-key 477 F12 FUNCTION
-key 478 1 FUNCTION
-key 479 2 FUNCTION
-key 480 D FUNCTION
-key 481 E FUNCTION
-key 482 F FUNCTION
-key 483 S FUNCTION
-key 484 B FUNCTION
-# key 497 KEY_BRL_DOT1
-# key 498 KEY_BRL_DOT2
-# key 499 KEY_BRL_DOT3
-# key 500 KEY_BRL_DOT4
-# key 501 KEY_BRL_DOT5
-# key 502 KEY_BRL_DOT6
-# key 503 KEY_BRL_DOT7
-# key 504 KEY_BRL_DOT8
-key 704 RECENTAPPS
-key 705 APPLICATION
-key 706 SIP_ON_OFF
-key 707 VOICESEARCH
-key 708 QPANEL_ON_OFF
diff --git a/usr/keylayout/gpio-keys.kl b/usr/keylayout/gpio-keys.kl
deleted file mode 100644
index 7014d5c..0000000
--- a/usr/keylayout/gpio-keys.kl
+++ /dev/null
@@ -1,4 +0,0 @@
-key 115 VOLUME_UP WAKE
-key 114 VOLUME_DOWN WAKE
-key 116 POWER WAKE
-key 172 HOME WAKE
diff --git a/usr/keylayout/janice-kp.kl b/usr/keylayout/janice-kp.kl
deleted file mode 100644
index fb97e54..0000000
--- a/usr/keylayout/janice-kp.kl
+++ /dev/null
@@ -1,87 +0,0 @@
-key 399 GRAVE
-key 2 1
-key 3 2
-key 4 3
-key 5 4
-key 6 5
-key 7 6
-key 8 7
-key 9 8
-key 10 9
-key 11 0
-key 158 BACK
-key 230 SOFT_RIGHT WAKE
-key 60 SOFT_RIGHT WAKE
-key 107 ENDCALL
-key 62 ENDCALL
-key 229 MENU
-key 59 MENU
-key 139 MENU
-key 127 SEARCH
-key 228 POUND
-key 227 STAR
-key 231 CALL
-key 61 CALL
-key 232 DPAD_CENTER
-key 108 DPAD_DOWN
-key 103 DPAD_UP
-key 102 HOME WAKE
-key 105 DPAD_LEFT
-key 106 DPAD_RIGHT
-key 115 VOLUME_UP WAKE
-key 114 VOLUME_DOWN WAKE
-key 116 POWER WAKE
-key 211 FOCUS
-key 212 CAMERA
-
-key 16 Q
-key 17 W
-key 18 E
-key 19 R
-key 20 T
-key 21 Y
-key 22 U
-key 23 I
-key 24 O
-key 25 P
-key 26 LEFT_BRACKET
-key 27 RIGHT_BRACKET
-key 43 BACKSLASH
-
-key 30 A
-key 31 S
-key 32 D
-key 33 F
-key 34 G
-key 35 H
-key 36 J
-key 37 K
-key 38 L
-key 39 SEMICOLON
-key 40 APOSTROPHE
-key 14 DEL
-
-key 44 Z
-key 45 X
-key 46 C
-key 47 V
-key 48 B
-key 49 N
-key 50 M
-key 51 COMMA
-key 52 PERIOD
-key 53 SLASH
-key 28 DPAD_CENTER
-
-key 56 ALT_LEFT WAKE
-key 100 ALT_RIGHT WAKE
-key 42 SHIFT_LEFT WAKE
-key 54 SHIFT_RIGHT WAKE
-key 15 TAB
-key 57 SPACE
-key 150 EXPLORER
-key 155 ENVELOPE
-
-key 12 MINUS
-key 13 EQUALS
-key 215 AT
diff --git a/vendorsetup.sh b/vendorsetup.sh
new file mode 100644
index 0000000..59ad938
--- /dev/null
+++ b/vendorsetup.sh
@@ -0,0 +1,2 @@
+add_lunch_combo cm_janice-eng
+add_lunch_combo cm_janice-userdebug
diff --git a/vibrator/vibrator.c b/vibrator/vibrator.c
index 086d25b..05ebbd8 100644
--- a/vibrator/vibrator.c
+++ b/vibrator/vibrator.c
@@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-#include
#include "qemu.h"
#include
@@ -21,11 +20,6 @@
#include
#include
-
-#ifdef USE_ALTERNATIVE_VIBRATOR
-extern int sendit(int timeout_ms);
-#else
-
#define THE_DEVICE "/sys/class/timed_output/vibrator/enable"
int vibrator_exists()
@@ -33,42 +27,32 @@ int vibrator_exists()
int fd;
fd = open(THE_DEVICE, O_RDWR);
- if(fd != 0)
- return 1;
+ if(fd < 0)
+ return 0;
close(fd);
- return 0;
+ return 1;
}
-static int sendit(int timeout_ms)
+int sendit(int timeout_ms)
{
int nwr, ret, fd;
char value[20];
+ if (timeout_ms == 0) {
+ /* Called from from vibrator_off(), checks if the device is vibrating,
+ if it's vibrating stop, if not, do nothing */
+ return (vibrator_exists() == 0) ? 0 : 1;
+ }
+
fd = open(THE_DEVICE, O_RDWR);
if(fd < 0)
return errno;
- nwr = sprintf(value, "%d\n", timeout_ms);
+ /* timeout_ms < 0 means constant on, up to maximum allowed time */
+ nwr = sprintf(value, "%d\n", (timeout_ms < 0)?15000:timeout_ms);
ret = write(fd, value, nwr);
close(fd);
return (ret == nwr) ? 0 : -1;
}
-
-
-int vibrator_on(int timeout_ms)
-{
- /* constant on, up to maximum allowed time */
- if(timeout_ms < 0)
- return sendit(5000);
- return sendit(timeout_ms);
-}
-
-int vibrator_off()
-{
- /* checks if the device is vibrating, if it's vibrating stop, if not, do nothing */
- return (vibrator_exists() == 0) ? 0 : 1;
-}
-
-#endif