Samsung Galaxy Tab 4 8.0 Wi-Fi (samsung-milletwifi)

From postmarketOS Wiki
Samsung Galaxy Tab 4 8.0 Wi-Fi
Galaxy Tab 4 8.0 running postmarketOS showing the xfce4 desktop
Galaxy Tab 4 8.0 running postmarketOS showing the xfce4 desktop
Manufacturer Samsung
Name Galaxy Tab 4 8.0 Wi-Fi
Codename samsung-milletwifi
Model SM-T330
Released 2014
Category testing
Pre-built images no
Original software Android
Original version 4.4.2
Extended version 5.1.1
postmarketOS kernel 6.5.7
Hardware
Chipset Qualcomm Snapdragon 400 (APQ8026)
CPU 4x 1.2 GHz Cortex-A7
GPU Adreno 305
Display 800x1280 px, 8.0" in (20 cm) diagonal, WXGA TFT display
Storage 16/32 GB flash memory, microSDXC slot (up to 64 GB)
Memory 1.5 GB
Architecture ARMv7
Type tablet
Unixbench Whet/Dhry score 604
Features
USB Networking
Works
Flashing
Works
Touchscreen
Partial
Display
Partial
WiFi
Partial
FDE
Works
Mainline
Works
Battery
Broken
3D Acceleration
Broken
Audio
Broken
Bluetooth
Works
Camera
Broken
GPS
Partial
Internal storage
Works
USB OTG
Broken
Sensors
Accelerometer
Works
Hall Effect
Works
Power Sensor
Broken
Misc
Ir TX
Broken
Ir RX
Broken
Memory Card
Works
FOSS bootloader
Broken


Member of the Samsung Galaxy Tab 4 series of tablets.

Maintainer(s)

Users owning this device

  • NekoCWD (Notes: postmarketOS lab rat)
  • Susurrus (Notes: 2x with flip cover)


How to enter flash mode

Download mode: When turned off hold Power+Volume Down+Home

Recovery mode: When turned off hold Power+Volume Up+Home

lk2nd: Power on and once something is shown on the display hold Volume Down

Installation

Prerequisites:

Install Lk2nd/lk1st via Heimdall. Heimdall hasn't been tested beyond this as lk2nd is recommended for all devices.

Follow the pmbootstrap article until you have done the install action (note that --fde stands for full-disk-encryption - this can also be left out):

pmbootstrap install --fde

The SYSTEM partition is only 2GB, and to simplify switching back to Android, install to the larger (12GB or 30GB depending on your device) USERDATA partition. Boot into lk2nd and then:

pmbootstrap flasher flash_rootfs --partition userdata

Near-mainline Status

For the status of all components in the near-mainline codebase being used, see below:

Component Part number Works? Notes
Chipset Qualcomm Snapdragon 400 P Missing speedbin support, so CPU can't reach maximum frequency. However downclocking is supported.
Graphics Adreno 305 N Untested, but should work with the Adreno 330 firmware. Pending proper panel support.
eMMC (16GB) THGBMBG7D2KBAIL Y
Charging IC SMB358SET-1939Y Y
PMIC PM8226 N See this issue
Micro-USB IC SM5502 P USB-OTG not supported yet.
Audio WCD9306 N Requires codec support
Touchscreen MELFAS MMS-252M Y
Buttons gpio-keys Y Volume up/down, power and home button.
WiFi, Bluetooth WCN3660A P Bluetooth works, WiFi works with hardware scanning disabled.
Display Panel S6D7AA0 LSL080AL02 P Simple Framebuffer driver partially works (pmOS splash screen doesn't show). Full panel support is being tracked in linux#13.
Backlight LP8556TMX-E09-S7003056 P Changing brightness doesn't work. Pending panel work.
Front Camera Siliconfile SR130PC20 N
Rear Camera Siliconfile SR352 N
IR ABOV MC96FR116CU N 8-bit microcontroller with custom firmware to act as an IR LED transceiver.
GPS WGR7640 P Driver support implemented, but ModemManager doesn't support WiFi-only devices (see this discussion) & gpsd is awaiting gpsd!139.
Hall effect/flip cover sensor S-5712CCDL1-I4T1U Y Connected via GPIO.
Accelerometer STMicroelectronics K2HHTR Y

Known issues

Issues known to happen in the near-mainline kernel:

  • dmesg shows warning: l20: voltage operation not allowed (see linux#6)
  • dmesg shows warning: /cpus/cpu@0 missing clock-frequency property (also for cpu1, 2, & 3). - Normal operation, not a concern.
  • dmesg shows errors like: i2c_qup f9926000.i2c: tx channel not available - TX does work with i2c here, just not via DMA, which this SoC doesn't support. This error can be safely ignored.

Mainline Status

6.10 - Initial support including display (framebuffer), cover detection, buttons, touchscreen, and accelerometer

Hardware Revisions

7 versions are known to exist from the spec sheet. These may correlate with the different versions that are listed with the DTS files included in downstream (annotated as Rev-00 through Rev-05). These revisions are specified by a 4-bit value set by external pull-up/pull-down resistors on pins 12, 13, 32, & 63. To read these values run sudo gpioget 0 12 13 32 63.

The output maps to the revision name as follows:

Value Revision
0100 SM-T330_REV0.0
0101 SM-T330_REV0.1
0110
SM-T330_REV0.2
0111 SM-T330_REV0.3
1000 SM-T330_REV0.4
1001 SM-T330_REV0.5
1011 SM-T330_REV0.5C

Debugging

This device use Silicon Mitus SM5502 MUIC, which support carkit serial mode.

MUIC serial connected to uart3 (blsp1_uart3 in mainline kernel dt)

Notice Use 619k resistor

For more information about debugging see serial debugging page

Currently requires kernel-level and pmaports-level modifications to see output.

Serial output from a normal Android boot:

Normal Android boot:

Format: Log Type - Time(microsec) - Message
Log type: B - since boot(excluding boot rom).  D - delta
B -    147406 - SBL1, Start
B -    152683 - scatterload_region && ram_init, Start
D -         0 - scatterload_region && ram_init, Delta
B -    169183 - pm_device_init, Start
D -     16012 - pm_device_init, Delta
B -    185623 - boot_flash_init, Start
D -    171166 - boot_flash_init, Delta
B -    356880 - boot_config_data_table_init, Start
D -        61 - boot_config_data_table_init, Delta
B -    363072 - sbl1_ddr_set_params, Start
B -    366915 - Pre_DDR_clock_init, Start
D -       213 - Pre_DDR_clock_init, Delta
D -         0 - sbl1_ddr_set_params, Delta
B -    382744 - pm_driver_init, Start
D -     10034 - pm_driver_init, Delta
B -    392992 - clock_init, Start
D -       183 - clock_init, Delta
B -    412085 - boot_fota_restore_partition, Start
D -       793 - boot_fota_restore_partition, Delta
B -    509838 - Tz Execution, Start
D -    146247 - Tz Execution, Delta
B -    656177 - boot_fota_restore_partition, Start
D -         0 - boot_fota_restore_partition, Delta
B -    663619 - RPM loading is successful.
B -    730048 - Signal PBL to Jump to RPM FW
B -    730353 - WDT loading start!
B -    731024 - WDT loading success!
B -    753685 - WDT Execution, Start
D -       793 - WDT Execution, Delta
B -    980849 - sbl1_efs_handle_cookies, Start
D -       488 - sbl1_efs_handle_cookies, Delta
B -    982862 - RPM sync cookie updated
B -   1040019 - SBL1, End
Android Bootloader - UART_DM Initialized!!!
[0] HW REV11 : (1, 0, 1, 1)
[0] init_dbg SEC_DEBUG_BASE_ADDR = 0x3fe00000 orig_logmagic 0x4d474f4c
[0] welcome to lk

[10] platform_init()
[10] target_init()
[10] check_reboot_mode RESTART_REASON_ADDR 0xfe80565c restart_reason 2003195137
[10] cancel power key check in case of reboot with 0x77665501
[20] Power on reason 131200
[20] Power on status : 0x20080 (Keypad Power on)
[260] [MUIC] control register value : 0x1e
[260] [MUIC] init_microusb_ic() done
[260] [MUIC]device type1 = 0x00 ,device type2 = 0x04
[270] [MUIC] microusb_get_devices : 0x0400
[270] [MUIC] microusb dev id : 0x01
[270] [MUIC] MUIC initializion Done
[280] [MUIC] microusb_reset_reg[680] microusb_reset_register end
[690] [MUIC]device type1 = 0x00 ,device type2 = 0x04
[690] [MUIC] detected cable_type(0x0400)
[690] check_reboot_mode RESTART_REASON_ADDR 0xfe80565c restart_reason 2003195137
[700] get_charger: hw_rev(0xb)
[710] [battery] cable_type(0x0400), vbus(0x00)
[710] aboot_dev_charging_init : cable_status(0), cable_type(1024), reboot_case(1)
[720] aboot_dev_charging_init, [battery] batt_id_value (0)
[720] get_charger: hw_rev(0xb)
[730] [battery] external charger init
[730] [battery] cable_type(0x0400), vbus(0x00)
[740] SMB358_set_registers: Float voltage - 4.34
[760] smb358_set_charging_current: input current(1000), (0x34)

[770] smb358_init_charger: Done
[770] [battery] skip init fuelgauge!!
[780] get_charger: hw_rev(0xb)
[780] check_reboot_mode RESTART_REASON_ADDR 0xfe80565c restart_reason 2003195137
[790] [battery] cable_type(0x0400), vbus(0x00)
[800] [MUIC]device type1 = 0x00 ,device type2 = 0x04
[800] low_power(rb=1, jig=1, ct=0, vcell=4146)
[800] skip check low power
[860] Done initialization of the card

MODEL_NAME:{{SM-T330}}
eMMC_SERIAL_NUMBER:{{1101003031364745320462ad416a9100}}

[890] aboot_init()
[890] check_reboot_mode RESTART_REASON_ADDR 0xfe80565c restart_reason 2003195137
[900] Power on reason 131200
[900] vibrator started
[1000] vibrator stopped
[1000] aboot_vib() DONE 
[1010] first_qcom_dload_magic=0x0,second_qcom_dload_magic=0x0
[1010] Not able to search the panel:
[1020] Display enabled for 8 HW type
[1020] dsi_panel_init: dual_pipe=0 dual_dsi=0 split_display=0  broadcast=0 
[1030] first_qcom_dload_magic=0x0,second_qcom_dload_magic=0x0
[1030] msm_display_init
[1040] target_enable_gpio_count(433): Invalid Model ID(0)
[1050] ERROR: splash Partition invalid
[1050] lcd : display bg screen 
[1050] Config MIPI_VIDEO_PANEL.
[1060] 	MIPI DSI_0 LP11
[1060] Panel Reset
[1130] lcd manufacture id: 0x5e8c10
[1130] :::DPK mdp_dsi_video_config done[1130] Turn on MIPI_VIDEO_PANEL.
[1150] Video lane tested successfully
[1150] mdss_dsi_config_post ++ 
[1550] mdss_dsi_config_post -- 
[1560] QFPROM serial num lsb: 0x07183d1b
[1560] QFPROM serial num msb: 0x0000000f
[1560] QFPROM ocm1: 0x10000000
[1560] serial number: 62ad416a07183d1b
[1570] i2c_init: .scl:[21]  .sda[20]
[1580] DDR manufacture: ELPIDA
BOOTLOADER VERSION : T330XXS1BPL1
[1590] before  aboot_check_mode() , boot_mode=0x0
[1600] check_ramdump_mode :: k_param.debuglevel[0x574f4c44]::k_param.cp_debuglevel[0x0] 
[1610] param.normal_poweroff[1]
[1610] pwr_normal_off::[0x1]
[1640] check_boot_mode, key Down[0], Up[0] 
[1640] cable_type =0x400, reboot_mode=0x77665501
check_pit_integrity: invalid pit magic code.(0x0)
[1650] SECURE : Signature verification...
[1660] SECURE : Signature verification succeed
[1670] before check_lpm_mode 
[1670] [battery] cable_type(0x0400), vbus(0x00)
[1680] is_reboot_case =1
[1680] cable_status = 0
[1680]  check_lpm_mode: Reading restart reason from DDR address: restart_reason = 0x715ad4c0
[1690]  check_lpm_mode: Clear the restart reason from DDR address: restart_reason = 0x0
[1700] enter normal booting mode
AST_POWERON
[2040] after  aboot_check_mode() 
[2050] [battery] cable_type(0x0400), vbus(0x00)
[2060] [MUIC]device type1 = 0x00 ,device type2 = 0x04
[2070] rb=1 jig=1
[2070] v=4109 soc=74
[2070] skip check low battery
[2070] reboot_mode = 0x77665501, boot_mode = 0, por = 0x20080
[2080] partition misc doesn't exist
[2080] error in emmc_recovery_init
[2080] begin  boot_linux_from_mmc()  
[2090] No 'misc' partition found
[2090] Error reading MISC partition
[2090] failed to get ffbm cookie
[2100] LK Area: 0xF800000 - 0xFA00000
[2100] Kernel Addr: 0x8000
[2100] Ramdisk Addr: 0x2000000
[2100] Second Addr: 0xF00000
[2110] Tags Adddr: 0x1E00000
[2110] use_signed_kernel=0, is_unlocked=0, is_tampered=0.
[2110] Loading boot image (7981056): start
[2220] Loading boot image (7981056): done
[2270] board[model_info:c708ff01, sec_rev:11], dtb[dt_model_info:c708ff01, dt_board_rev 4]
[2280] board[model_info:c708ff01, sec_rev:11], dtb[dt_model_info:c708ff01, dt_board_rev 5]
[2290] board[model_info:c708ff01, sec_rev:11], dtb[dt_model_info:c708ff01, dt_board_rev 6]
[2290] board[model_info:c708ff01, sec_rev:11], dtb[dt_model_info:c708ff01, dt_board_rev 7]
[2300] board[model_info:c708ff01, sec_rev:11], dtb[dt_model_info:c708ff01, dt_board_rev 8]
[2310] board[model_info:c708ff01, sec_rev:11], dtb[dt_model_info:c708ff01, dt_board_rev 9]
[2320] boot image size(8870144)
[2450] Calculate digest for TIMA. Reason = [-1][2550] [TIMA trusted boot]: Boot-time measurement successful
[2560] cmdline = 'console=null androidboot.console=null androidboot.hardware=qcom user_debug=23'
[2570] init_ddi_data: usable ddi data.
[2570] QFPROM serial num lsb: 0x07183d1b
[2570] QFPROM serial num msb: 0x0000000f
[2580] QFPROM ocm1: 0x10000000
[2580] QFPROM serial num lsb: 0x07183d1b
[2580] QFPROM serial num msb: 0x0000000f
[2590] QFPROM ocm1: 0x10000000
[2590] QFPROM serial num lsb: 0x07183d1b
[2590] QFPROM serial num msb: 0x0000000f
[2600] QFPROM ocm1: 0x10000000
[2600] WV: API Status 0x0
[2600] [MUIC]device type1 = 0x00 ,device type2 = 0x04
[2610] SPMI read command failure: 			cmd_id = 1, error = 2
[2610] 
Booting Linux
[2620] pm8x41_get_is_cold_boot: Warm boot
[2620] target_pause_for_battery_charge : pon_reason is 128 cold_boot:0
[2630] cmdline: console=null androidboot.console=null androidboot.hardware=qcom user_debug=23 androidboot.sec_atd.tty=/dev/ttyHSL0 sec_log=0x100000@0x3fe00008 sec_dbg=0x80000@0x3ff00008 sec_debug.reset_reason=0x1a2b3c00 normal_off=1 lcd_id=0x5e8c10 androidboot.d[2650] Updating device tree: start
[2760] Updating device tree: done
[2760] booting linux @ 0x8000, ramdisk @ 0x2000000 (1484585), tags/device tree @ 0x1e00000
[2770] Turn off MIPI_VIDEO_PANEL.
[2770] Continuous splash enabled, keeping panel alive.
[2770] Booting Linux

+UART READY
BOOTING COMPLETED

See also

Photos

Photo of stock Samsung recovery menu for Galaxy Tab 4 8.0 Wi-Fi