Skip to content

arm64: dts: apple: n66: Enable the cameras on both iPhone 6s Plus models - #176

Merged
henrikklee merged 2 commits into
OrchardLinux:mainfrom
ricktav:n66/camera
Dec 5, 2026
Merged

henrikklee merged 2 commits into
OrchardLinux:mainfrom
ricktav:n66/camera

Conversation

@ricktav

@ricktav ricktav commented Dec 4, 2026 •

Copy link
Copy Markdown

The A9 camera driver from #135 on the iPhone 6s Plus. One commit, device tree only.

What

  • The 6s Plus (N66, N66m) wires its cameras like the iPhone 6s:
    • the D2255 rails cam_avdd (pmuL 0x208) and cam0 (0x215), plus the second analog supply on AP GPIO 194;
    • rear and front shutdown on GPIOs 48 and 52, the clock pads 49 and 53, and the torch on 74.
  • Only the ADT sensor-type differs: 0x82 instead of 0x88.
  • The 6s Plus also has optical stabilisation (ADT has-sphere, sphere_buck_mode GPIO 111, focus_subdev GPIO 47). The firmware drives it, and the driver leaves those lines alone.
  • The block goes in s800x-n66.dtsi, which both models include. The values are from the iOS 15.8.8 (19H422) device trees of n66ap and n66map, which agree on the ISP node.

Tested on an N66 (Samsung). Main a1d07f1 plus this commit, booted as an extra Omarchy A kernel entry, with apple/isp-s8000.bin from the 6s Plus's own 19H422 IPSW (byte-identical to the 6s file in OrchardLinux/orchard#524):

  • t8010-isp ... platform 0x82; video0 and video2. The firmware reports the 6s sensors: rear 0x247, module 1, design 1 → set-file 9611_01; front 0x190, module 2 → 1422_01.
  • Rear: 1920x1080 NV12 at 30.00 fps (120 frames, then 3×300).
  • Front: 1024x720 and 1280x720 at 15–17 fps, in a dim room.
  • Stills from both look right: colours, no tearing.
  • Three rounds of rear + front streaming gave no ISP, DART or kernel errors.
  • Not tested:
    • set-files (not installed, so default tuning);
    • the torch, focus and the larger modes;
    • the TSMC N66m.

Orchard side: the firmware recipe for the n66 is OrchardLinux/orchard#562.

🤖 Generated with Claude Code

https://claude.ai/code/session_01SFMaVeK3LkXZ3zvi9pvxid

The iPhone 6s Plus (N66, N66m) wires its cameras as the iPhone 6s
does: the D2255 camera rails cam_avdd (pmuL 0x208) and cam0 (0x215),
the second analog supply on AP GPIO 194, rear and front shutdown on
GPIOs 48 and 52, the clock pads 49 and 53 and the torch enable on 74.
Only the ADT sensor-type differs, 0x82 instead of 0x88. The rear
camera also has optical stabilisation (ADT has-sphere,
sphere_buck_mode on GPIO 111, focus_subdev on GPIO 47). The firmware
drives it, and the driver leaves those lines alone.

Add the ISP board part to s800x-n66.dtsi, which both models include.
The values come from the iOS 15.8.8 device trees of both models,
which agree.

Tested on an N66 (Samsung): the firmware reports the iPhone 6s
sensors (rear 0x247, front 0x190). The rear camera streams 1920x1080
NV12 at 30 fps, the front one 1024x720 and 1280x720, and the images
are correct. Over repeated streams of both, the kernel log stays
clean.

Signed-off-by: ricktav <82380971+ricktav@users.noreply.github.com>
Assisted-by: LLM
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… Plus

The iPhone 6s (N71, N71m) and 6s Plus (N66, N66m) wire their cameras the
same way: rails, shutdown GPIOs, reference clock pads, torch line,
firmware and DART. Only the ADT sensor-type differs, 0x88 on the 6s and
0x82 on the 6s Plus.

Move the shared part into s800x-6s.dtsi, which both models include, and
keep only apple,platform-id in each model file. The compiled device
trees of all four boards are unchanged.

Assisted-by: LLM
Signed-off-by: Henrik Klee <henrik@goat-code.com>
henrikklee added a commit to ricktav/orchard that referenced this pull request Dec 5, 2026
The TSMC iPhone 6s Plus (n66m) restores from the same iOS 15.8.8 file
(19H422) as the Samsung one, and OrchardLinux/linux#176 enables the
cameras on both 6s Plus models. Install apple/isp-s8000.bin there too,
with the same input and output entries and checksums as n66.

Assisted-by: LLM
Signed-off-by: Henrik Klee <henrik@goat-code.com>
@henrikklee
henrikklee merged commit 63caf78 into OrchardLinux:main Dec 5, 2026
4 checks passed
@henrikklee

Copy link
Copy Markdown

Merged, thank you @ricktav! Both cameras on the 6s Plus, with three clean streaming rounds on your N66 and the values checked against both models' ADTs. Very nice work.

What changed on your branch: your commit is unchanged. On top of it I added one device-tree commit (f79aeaf). Your camera block was the same as the iPhone 6s's line for line, except for apple,platform-id, so the shared part (rails, GPIOs, clock pads, torch line, firmware name, DART) now lives once in s800x-6s.dtsi, which both phones include. s800x-n66.dtsi and s800x-n71.dtsi keep only their platform id (0x82 and 0x88), and your note on the optical stabiliser stays in the N66 file. The compiled device trees of all four boards (N66, N66m, N71, N71m) are byte-for-byte the same as before the move, so nothing changes for the 6s or for your tested setup.

Nothing was left out.

Open follow-ups:

  • Users get the cameras when orchard moves its kernel lock (happening now) together with the ISP firmware from orchard#562. That recipe covers the N66 only, so the N66m (TSMC) needs the same firmware recipe before its cameras can start.
  • media: apple: t8010-isp: Add the A9's torch #177 (torch) is next once it's rebased; see my comment there.
  • Idea for later: the iPhone SE (N69, s800x-se.dtsi) is the same A9 family and has no cameras yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants