devices: add CP Plus CP-UNC-TA21L2C (gk7205v200_lite, SC223A)#106
Open
AKoo7 wants to merge 1 commit into
Open
Conversation
Dahua-OEM 2 MP camera. The SC223A is on hardware I2C0 routed to the VI-RAW pads (0x112c0060/0x64 func2) rather than the default mipi-sensor pads (0x30/0x34 func1) the SDK probes, and needs a 27 MHz MCLK (0x120100f0=0x19; SDK default 0x11/div4 leaves it unresponsive). S71devmem re-muxes the pads, selects the SENSOR_RSTN reset (GPIO8_7 func2) and fixes MCLK after S70vendor/load_goke; the stock open_sensor_i2c then reaches the sensor over /dev/i2c-0. No kernel module needed. Verified on hardware: chip-id 0xcb3e over HW I2C0, MIPI lock 1920x1080 zero errors, majestic streams correct colour 1080p. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a device profile for the CP Plus CP-UNC-TA21L2C — a Dahua-OEM 2 MP
full-colour camera on a Goke gk7205v200 (lite) with a SmartSens SC223A
(chip-id
0xcb3e), 16 MiB SPI-NOR, wired-only.Board specifics
On this board the SC223A is on the SoC's hardware I2C0, but routed to the
VI-RAW pads (
0x112c0060/0x64, func2) instead of the default mipi-sensorpads (
0x112c0030/0x34, func1) that the SDKboard=demobring-up probes — sothe stock probe never ACKs. It also needs a 27 MHz MCLK (
0x120100f0 = 0x19,div6); the SDK default
0x11(div4) leaves the sensor unresponsive.general/overlay/etc/init.d/S71devmemhandles both: it runs afterS70vendor(load_goke) and beforeS95majestic, re-muxing I2C0 to theVI-RAW pads, selecting the
SENSOR_RSTNreset (GPIO8_7, func2) and fixingthe MCLK. With that, the stock
open_sensor_i2creaches the sensor over/dev/i2c-0— no kernel module required. (load_gokealready muxesSENSOR_CLKto func1, and majestic does not disturb the MCLK.)Verified on hardware
0xcb3eread over hardware I2C0 (i2ctransfer -y 0 w2@0x30 0x31 0x07 r1→0xcb)majesticstreams correct-colour 1080p (Smart SC223A_1080P_30FPS_10BIT_LINE_Init_OK!, RTSP up)S70vendor → S71devmem → S95majesticwas reproduced and confirmed end-to-endContext
This started as a buildroot package in OpenIPC/firmware (PR
OpenIPC/firmware#2206, now closed). Per @widgetii's review there — both that
these pads are hardware I2C0 rather than a bit-bang bus, and that
board-specific pinmux belongs in this repo — the work is reworked into a device
profile here, with the kernel module dropped in favour of the pinmux above.
TODO (follow-ups)