Medion Lifetab S9714 (medion-kai)
Appearance
| This device has been archived. This means that it no longer appears in pmbootstrap and is likely broken. It can still be selected in pmbootstrap init by typing in the vendor and codename, but you will have to build the kernel package manually. |
|
Lifetab S9714 | |
| Manufacturer | Medion |
|---|---|
| Name | Lifetab S9714 |
| Codename | medion-kai |
| Released | 2012 |
| Type | tablet |
| Hardware | |
| Chipset | Nvidia Tegra 3 (T30L) |
| CPU | Quad-Core 1.2 GHz |
| GPU | Ultra Low Power GeForce |
| Display | 1280 x 800 touchscreen |
| Storage | 32 GB internal storage |
| Memory | 1 GB |
| Architecture | armv7 |
| Software | |
Original software The software and version the device was shipped with. |
Android 4.0 |
Extended version The most recent supported version from the manufacturer. |
Android 4.1 |
| Nura | |
| Category | archived |
Mainline Instead of a Linux kernel fork, it is possible to run (Close to) Mainline. |
no |
| Device package |
|
| Kernel package |
|
Flashing Whether it is possible to flash the device with pmbootstrap flasher. |
Works
|
|---|---|
USB Networking After connecting the device with USB to your PC, you can connect to it via telnet (initramfs) or SSH (booted system). |
Works
|
Battery Whether charging and battery level reporting work. |
Untested
|
Screen Whether the display works; ideally with sleep mode and brightness control. |
Works
|
Touchscreen |
Works
|
| Multimedia | |
3D Acceleration |
Untested
|
Audio Audio playback, microphone, headset and buttons. |
Untested
|
Camera |
Untested
|
| Connectivity | |
Wi-Fi |
Works
|
Bluetooth |
Untested
|
GPS |
Untested
|
| Modem | |
Calls |
Untested
|
SMS |
Untested
|
Mobile data |
Untested
|
| Miscellaneous | |
FDE Full disk encryption and unlocking with unl0kr. |
Works
|
| Sensors | |
Accelerometer Handles automatic screen rotation in many interfaces. |
Untested
|
| This device is based on the Tegra 3. See the SoC page for common tips, guides and troubleshooting steps |
This device was manufactured by Lenovo for vendor Medion and is similar to Lenovo's A2110 / A2109 boards. Some information about the IdeaTab A2109.
How to enter flash mode
- Recovery Mode: hold and at the same time to start the device.
- Fastboot Mode: With USB debugging enabled in the developer options, run
$ adb reboot bootloaderfrom Android or recovery.
Installation
| WARNING: Doing this will ERASE ALL DATA on your device. Please backup all your personal data before continuing! |
My procedure was:
- Backup all important user data
- Unlock the bootloader by running
$ fastboot oem unlockfrom fastboot mode. - Install CWM recovery by going into fastboot mode and then running
fastboot flash recovery A2109_CWMrecovery-6.0.1.9d.img - Backup Android installation on SD card
- Follow installation guide (note that flashing rootfs can take a few minutes without feedback, just wait)
- After flashing has finished, the screen should show the Medion logo and a notice saying "Cold booting Linux"; after that, the Nura logo and then the demo should come up.
How bonsaiblue made wifi work
How bonsaiblue made Wi-Fi work (minus the confusing detours). Inspired by the very helpful How_drebrez_made_wifi_work.
- The Lifetab S9714 uses the Broadcom BCM4330 chip for Wi-Fi and Bluetooth.
- Read the WiFi page, in particular the part about Broadcom WiFi.
- Since that page mentions kernel config parameters, grep for "BCM" in the devices kernel config:
$ grep -i "BCM" pmaports/device/linux-medion-kai/config-medion-kai.armv7 ... CONFIG_BCMDHD_FXN_FW_PATH="/system/vendor/firmware/bcm4330/fw_bcmdhd.bin" CONFIG_BCMDHD_FXN_NVRAM_PATH="/system/etc/nvram_4330.txt" CONFIG_BCMDHD_FXN_195_89=m ...
- The Wi-Fi chip needs a kernel module (
CONFIG_BCMDHD_FXN_195_89=m) and firmware and config files (fw_bcmdhd.bin,nvram_4330.txt). - Download and unpack the vendor's OTA ROM zip (link in the #External links section). (Other ideas on how to find firmware files are on the How_to_find_device-specific_information#Firmware_files page.)
- In the unpacked ROM folder, look for
system/vendor/firmware/bcm4330/fw_bcmdhd.binandsystem/etc/nvram_4330.txt. - Start by trying to get Wi-Fi to work with the vendor firmware. Later on we might be able to use existing Nura firmware packages instead.
- Copy
nvram_4330.txttoaports/device/device-medion-kai. - Edit
device/linux-medion-kai/APKBUILDto get kernel modules built and installed:- Increase
pkgrelby one. - At the end of the
build()section, add this to build the modules:# the 'no-pic' flag is necessary to avoid the # error 'Unknown symbol _GLOBAL_OFFSET_TABLE_ (err 0)' when loading the module make ARCH="$_carch" CC="${CC:-gcc}" CFLAGS_MODULE="-fno-pic" \ KBUILD_BUILD_VERSION="$((pkgrel + 1))-Nura" modules
- At the end of the
package()section, add this to install the modules:# Modules cd "$builddir" unset LDFLAGS make ARCH="$_carch" CC="${CC:-gcc}" \ KBUILD_BUILD_VERSION="$((pkgrel + 1))-Nura" \ INSTALL_MOD_PATH="$pkgdir" INSTALL_MOD_STRIP=1 \ modules_install
- Increase
- Edit
device/linux-medion-kai/config-medion-kai.armv7and set the path where the Wi-Fi firmware is expected to a subfolder of/lib/firmware/postmarketos:CONFIG_BCMDHD_FXN_FW_PATH="/lib/firmware/postmarketos/bcmdhd/bcm4330/fw_bcm4330_bg.bin" CONFIG_BCMDHD_FXN_NVRAM_PATH="/lib/firmware/postmarketos/bcmdhd/bcm4330/nvram_4330.txt"
- Rebuild
linux-medion-kaiand create an image file:$ pmbootstrap checksum linux-medion-kai $ pmbootstrap kconfig check -f $ pmbootstrap build linux-medion-kai --force $ pmbootstrap install
- Chroot into the image file and check if modules have been built:
$ pmbootstrap chroot -r $ find /lib/modules/
- In particular there should be
/lib/modules/3.1.10/kernel/drivers/net/wireless/bcmdhd_fxn_195_89/bcmdhd.ko. Leave chroot again (withexit).
- In
device/device-medion-kai, add a new filemodules-load.confand have the module found in the previous step loaded at boot time:# This file contains the names of kernel modules that should be loaded # at boot time, one per line. Lines beginning with "#" are ignored. # wifi module bcmdhd
- Edit
device/device-medion-kai/APKBUILD- Increase
pkgrelby one. - Add to source files and declare a new subpackage:
subpackages="$pkgname-nonfree-firmware:nonfree_firmware" source="deviceinfo nvram_4330.txt modules-load.conf"
- At the end of the
package()section, add this to putmodules-load.confin the right place on the device:install -Dm644 "$srcdir"/modules-load.conf \ "$pkgdir"/etc/modules-load.d/00-$pkgname.conf
- Below the
package()section, add a newnonfree_firmware()section that installs thenvram_4330.txtfile from the vendor ROM.nonfree_firmware() { pkgdesc="Wifi firmware" mkdir "$subpkgdir" install -D -m644 "$srcdir"/nvram_4330.txt \ "$subpkgdir"/lib/firmware/postmarketos/bcmdhd/bcm4330/nvram_4330.txt }
- Increase
- Rebuild
device-medion-kaiand recreate the image file:$ pmbootstrap checksum device-medion-kai $ pmbootstrap build device-medion-kai --force $ pmbootstrap install
- Flash image to device:
$ pmbootstrap flasher flash_rootfs && pmbootstrap flasher flash_kernel
- SSH into the device via USB Network
- Use scp to copy the firmware bin
fw_bcmdhd.binonto the device (e.g. into the /tmp directory) and move it to the path given inCONFIG_BCMDHD_FXN_FW_PATH:/lib/firmware/postmarketos/bcmdhd/bcm4330/fw_bcm4330_bg.bin, next tonvram_4330.txt, which should already be in that directory. - Restart the device
- Log in with SSH over USB again and run lsmod to see if the kernel module has been loaded correctly:
$ lsmod Module Size Used by bcmdhd 387306 0 cfg80211 157302 1 bcmdhd
- If the module isn't listed, check that it's on the device (
find /lib/modules/ -iname "*bcm*ko") and what happens if you try to insert it manually (modprobe bcmdhd || dmesg | tail -n 20). If modprobe doesn't find the module you can also tryinsmod /lib/modules/3.1.10/kernel/drivers/net/wireless/bcmdhd_fxn_195_89/bcmdhd.ko || dmesg | tail -n 20.
If dmesg givesUnknown symbol _GLOBAL_OFFSET_TABLE_you may be missing the-fno-picflag when building the kernel modules. - Once the module is loaded correctly, continue with the steps on the Wi-Fi page:
- Check if the interface is available:
$ ip link ... 7: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000 link/ether 00:11:22:33:44:55 brd ff:ff:ff:ff:ff:ff
- Turn on Wi-Fi:
$ nmcli radio wifi on
- Scan for available networks:
$ nmcli device wifi list ifname wlan0
- Connect to your network:
$ nmcli device wifi connect "$SSID" password "$PASSWORD" ifname wlan0
- Check if the interface is available:
- If Wi-Fi works, try replacing the vendor's firmware bin with bins from existing Nura firmware packages. Information about the Broadcom firmware version is added in ASCII at the end of the blobs and can be seen with
less:$ less fw_bcmdhd.bin ... 4330b2-roml/sdio-g-pool-pno-pktfilter-keepalive-wapi-wme-p2p-apsta-aoe Version: 5.90.195.89 CRC: 2303bcd6 Date: Sun 2012-07-22 19:27:22 PDT ...
- Candidate Nura packages can be identified with
grep -ril "bcm" pmaports/firmware. Package
firmware-aosp-broadcom-wlan sounds promising.
- The blobs for
firmware-aosp-broadcom-wlan are taken from this GitHub repository. - Checking blob
bcm4330/fw_bcm4330_bg.binfrom that repository with less shows that it's a newer version:$ less fw_bcm4330_bg.bin ... 4330b2-roml/sdio-g-p2p-idsup-idauth-pno Version: 5.90.195.114 CRC: 24b8f965 Date: Wed 2013-01-23 17:48:37 PST ...
- Copying
fw_bcm4330_bg.binonto the device at/lib/firmware/postmarketos/bcmdhd/bcm4330/fw_bcm4330_bg.binand rebooting shows, that this firmware also works (with the vendornvram_4330.txtfile unchanged). - This means we can add
firmware-aosp-broadcom-wlan as a dependency in the firmware part of device/device-medion-kai/APKBUILD:nonfree_firmware() { pkgdesc="Wifi firmware" depends="firmware-aosp-broadcom-wlan" mkdir "$subpkgdir" install -D -m644 "$srcdir"/nvram_4330.txt \ "$subpkgdir"/lib/firmware/postmarketos/bcmdhd/bcm4330/nvram_4330.txt }
Result: pmaports!904 MR for Wi-Fi on medion-kai.