Initial commit: CB-C6s-STU GSI Fixes

TWRP flashable zip for CB-C6s-STU tablet running GSI.
- build.prop: append tablet characteristics, brightness, orientation, BT offload
- goodix_ts.idc: touchscreen IDC config
- sensor_config.xml: camera sensor module mapping (hi846 / gc8034)
- Shell-script update-binary with append-only build.prop logic
This commit is contained in:
purpl
2026-06-27 12:18:41 +08:00
commit 0be91bc45b
7 changed files with 353 additions and 0 deletions

90
README.md Normal file
View File

@@ -0,0 +1,90 @@
# CB-C6s-STU GSI Fixes
TWRP flashable zip that applies device-specific fixes for the **CB-C6s-STU**
tablet when running a Generic System Image (GSI). All `build.prop` changes
are **appended** — the existing file is never replaced.
## What it fixes
| Area | File | Problem | Fix |
|------|------|---------|-----|
| System properties | `build.prop` | Missing tablet characteristics, wrong brightness range, portrait-only orientation, broken Bluetooth A2DP offload | Append missing properties |
| Touchscreen | `goodix_ts.idc` | Touch orientation and input device type not declared | Install IDC config for Goodix touch panel |
| Camera sensors | `sensor_config.xml` | Rear/front camera sensor modules not configured | Install sensor config for hi846 / gc8034 modules |
## Files
```
CB-C6s-STU-GSI-Fixes.zip
├── META-INF/com/google/android/
│ ├── update-binary # Shell script — all install logic
│ └── updater-script # Placeholder (TWRP uses shell-script mode)
├── system/
│ ├── build.prop # Properties appended to /system/build.prop
│ └── usr/idc/
│ └── goodix_ts.idc # Touchscreen input device config
└── vendor/etc/
└── sensor_config.xml # Camera sensor module mapping
```
### build.prop entries
Appended to the device's existing `/system/build.prop`:
```ini
# Tablet characteristics
ro.build.characteristics=tablet
# Workaround: Set max brightness of sprd_backlight to 1023
persist.sys.qcom-brightness=1023
# Workaround: Set primary display orientation to landscape
ro.surface_flinger.primary_display_orientation=ORIENTATION_90
# Workaround: Disable Bluetooth A2DP offload
ro.bluetooth.a2dp_offload.supported=false
persist.bluetooth.a2dp_offload.disabled=true
```
A backup is saved to `/system/build.prop.bak` before appending.
## Usage
1. Copy `CB-C6s-STU-GSI-Fixes.zip` to the device (sdcard or adb push).
2. Boot to **TWRP Recovery**.
3. Tap **Install** → select the zip → **Swipe to confirm Flash**.
4. Reboot.
The script mounts `/system` and `/vendor` automatically. No manual
mounting is needed.
## TWRP install output
During flash, TWRP will show:
```
[1/3] Appending entries to /system/build.prop...
[2/3] Installing goodix_ts.idc...
[3/3] Installing sensor_config.xml...
```
## Compatibility
- **Device**: CB-C6s-STU tablet (Spreadtrum / Unisoc platform)
- **Recovery**: TWRP with `/sbin/sh` support (shell-script update-binary)
- **GSI**: Any Android GSI that needs these device-specific tweaks
## Notes
- The `build.prop` entries are **appended, not replaced**. Re-flashing
the zip multiple times will duplicate the entries — restore from
`/system/build.prop.bak` if needed, or inspect the file first.
- The `sensor_config.xml` covers four camera sensor combinations:
rear (`hi846`, `gc8034_rear`) and front (`hi846_front`, `gc8034`),
each with OTP EEPROM tuning parameters.
- For SAR (System-as-Root) devices, the script falls back to
`/system/vendor/etc/` if `/vendor/etc/` is not available.
## License
Provided as-is for device maintenance. No warranty.