Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No picture from sc401ai, on NT98562 Cam #1492

Open
Grundefuht opened this issue Jul 18, 2024 · 1 comment
Open

No picture from sc401ai, on NT98562 Cam #1492

Grundefuht opened this issue Jul 18, 2024 · 1 comment

Comments

@Grundefuht
Copy link

Camera is running on NT98562
IMG_1477
IMG_1478

Vendor version was V5.00.R02.000629G3.10010.140200.0020000
It did upgraded without any troubles with
000629G3_OpenIPC_IPC_NT98562_80N40_S38.bin

Everything runs ok except picture from sensor

Majestic logs

majestic[1090]: Majestic Lite for Novatek, version master+401f141, built on 2024-05-19
majestic[1090]: Watchdog device (/dev/watchdog) not found
majestic[1090]: Set server path: /var/www
majestic[1090]: HTTP server started on :::80
majestic[1090]: Loading main configuration: /etc/majestic.yaml
majestic[1090]: SENSOR=sc401ai
majestic[1090]: Using /etc/sensors/sc401ai.yaml as sensor config
majestic[1090]: VI: sc401ai @ 0x60 [2560x1440]
majestic[1090]: Memory pool[0]: 0x00005200 x 2
majestic[1090]: Memory pool[1]: 0x00546200 x 1
majestic[1090]: Memory pool[2]: 0x00083600 x 1
majestic[1090]: sys_info.devid 0xFFFFE102, cur_fps[0]=0/100, vd_count=0^M
majestic[1090]: set_cap_param CROP NONE=0
majestic[1090]: set_cap_param OUT=0
majestic[1090]: RTSP server started on port 554

Kernel logs

Booting Linux on physical CPU 0x0
Linux version 4.19.91 (runner@fv-az651-131) (buildroot-gcc-13.2.0) #1 PREEMPT Tue May 21 02:59:59 UTC 2024
CPU: ARMv7 Processor [414fc091] revision 1 (ARMv7), cr=10c53c7d
CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
OF: fdt: Machine model: Novatek NA51089
Memory policy: Data cache writeback
On node 0 totalpages: 8192
  Normal zone: 64 pages used for memmap
  Normal zone: 0 pages reserved
  Normal zone: 8192 pages, LIFO batch:0
CPU: All CPU(s) started in SVC mode.
random: get_random_bytes called from start_kernel+0x80/0x48c with crng_init=0
pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
pcpu-alloc: [0] 0 
Built 1 zonelists, mobility grouping on.  Total pages: 8128
Kernel command line: earlyprintk console=ttyS0,115200 mem=32M panic=20 nprofile_irq_duration=on root=/dev/mtdblock3 rootfstype=squashfs init=/init mtdparts=spi_nor.0:64k(loader),256k(boot),2048k(kernel),5120k(rootfs),-(rootfs_data) bootts=260427,993806 resume_addr=0x00200088 user_debug=0xff 
Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)
Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)
Memory: 24588K/32768K available (4096K kernel code, 283K rwdata, 944K rodata, 1024K init, 232K bss, 8180K reserved, 0K cma-reserved, 0K highmem)
Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
    vmalloc : 0x82800000 - 0xff800000   (2000 MB)
    lowmem  : 0x80000000 - 0x82000000   (  32 MB)
    pkmap   : 0x7fe00000 - 0x80000000   (   2 MB)
    modules : 0x7f000000 - 0x7fe00000   (  14 MB)
      .text : 0x80008000 - 0x80500000   (5088 kB)
      .init : 0x80700000 - 0x80800000   (1024 kB)
      .data : 0x80800000 - 0x80846fc0   ( 284 kB)
       .bss : 0x80846fc0 - 0x80881344   ( 233 kB)
SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
rcu: Preemptible hierarchical RCU implementation.
	Tasks RCU enabled.
NR_IRQS: 384
L2C-310 enabling early BRESP for Cortex-A9
L2C-310 full line of zeros enabled for Cortex-A9
L2C-310 ID prefetch enabled, offset 1 lines
L2C-310 dynamic clock gating enabled, standby mode enabled
L2C-310 cache controller enabled, 8 ways, 128 kB
L2C-310: CACHE_ID 0x410000c9, AUX_CTRL 0x76420001
APIs of flush/clean all cache are supported
novatek_clock_init
sched_clock: 64 bits at 120MHz, resolution 8ns, wraps every 4398046511102ns
clocksource: arm_global_timer: mask: 0xffffffffffffffff max_cycles: 0x3759f22983, max_idle_ns: 881590413697 ns
Switching to timer-based delay loop, resolution 8ns
Console: colour dummy device 80x30
Calibrating delay loop (skipped), value calculated using timer frequency.. 240.00 BogoMIPS (lpj=1200000)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
CPU: Testing write buffer coherency: ok
Setting up static identity map for 0x100000 - 0x10003c
rcu: Hierarchical SRCU implementation.
devtmpfs: initialized
VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
NVTBOOTTS: nvt_bootts_proc_init initial success
clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
futex hash table entries: 256 (order: 0, 7168 bytes)
pinctrl core: initialized pinctrl subsystem
NET: Registered protocol family 16
DMA: preallocated 256 KiB pool for atomic coherent allocations
*** nvt_poweroff_setup 
nvt_otp_module_init
*** disable_cnn Get CNN2 Clock error
cryptd: max_cpu_qlen set to 1000
nvt_gpio f0070000.gpio: Register nvt_gpio_probe successfully
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
nvt_i2c f0220000.i2c: Register nvtim_i2c_probe successfully ver:1.00.013
nvt_i2c f0350000.i2c2: Register nvtim_i2c_probe successfully ver:1.00.013
nvt_i2c f03a0000.i2c3: Register nvtim_i2c_probe successfully ver:1.00.013
clocksource: Switched to clocksource arm_global_timer
VFS: Disk quotas dquot_6.6.0
VFS: Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
NET: Registered protocol family 2
tcp_listen_portaddr_hash hash table entries: 256 (order: 0, 6144 bytes)
TCP established hash table entries: 1024 (order: 0, 4096 bytes)
TCP bind hash table entries: 1024 (order: 2, 20480 bytes)
TCP: Hash tables configured (established 1024 bind 1024)
UDP hash table entries: 256 (order: 1, 12288 bytes)
UDP-Lite hash table entries: 256 (order: 1, 12288 bytes)
NET: Registered protocol family 1
RPC: Registered named UNIX socket transport module.
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
RPC: Registered tcp NFSv4.1 backchannel transport module.
Initialise system trusted keyrings
workingset: timestamp_bits=30 max_order=13 bucket_order=0
squashfs: version 4.0 (2009/01/31) Phillip Lougher
jffs2: version 2.2. (NAND) © 2001-2006 Red Hat, Inc.
Key type asymmetric registered
Asymmetric key parser 'x509' registered
bounce: pool size: 64 pages
Block layer SCSI generic (bsg) driver version 0.4 loaded (major 251)
io scheduler noop registered
io scheduler deadline registered (default)
io scheduler cfq registered
io scheduler mq-deadline registered (default)
io scheduler kyber registered
f0290000.uart: ttyS0 at MMIO 0xf0290000 (irq = 5, base_baud = 1500000) is a NVT
nvt_serial: console setup on port #0
console [ttyS0] enabled
f0300000.uart: ttyS1 at MMIO 0xf0300000 (irq = 6, base_baud = 3000000) is a NVT
f0310000.uart: ttyS2 at MMIO 0xf0310000 (irq = 7, base_baud = 3000000) is a NVT
nvt_serial: driver initialized
loop: module loaded
id =  0x20 0x70 0x17 0x20
spi_nor f0400000.nor: mtd .name=spi_nor.0 .size=800000(8M) .erasesize = 0x10000(64K)
spi_nor f0400000.nor: 1-bit mode @ 48000000 Hz
5 cmdlinepart partitions found on MTD device spi_nor.0
Creating 5 MTD partitions on "spi_nor.0":
0x000000000000-0x000000010000 : "loader"
0x000000010000-0x000000050000 : "boot"
0x000000050000-0x000000250000 : "kernel"
0x000000250000-0x000000750000 : "rootfs"
0x000000750000-0x000000800000 : "rootfs_data"
libphy: Fixed MDIO Bus: probed
nvt_eth_env_probe: get IO MEM 0xfd2b0000
nvt_eth_env_probe: pinmux detect emb phy 0x22
DWC_ETH_QOS: Phy detected at ID/ADDR 0
libphy: dwc_phy: probed
nvt_resume: find node
nvt_resume: led-inv = 0
nvt_resume: pinmux 0x22
Supports TSO, SG and TX COE
Supports RX COE and GRO
nvt_rtc f0060000.rtc: rtc core: registered nvt_rtc as rtc0
i2c /dev entries driver
NET: Registered protocol family 10
Segment Routing with IPv6
NET: Registered protocol family 17
Loading compiled-in X.509 certificates
nvt_rtc f0060000.rtc: setting system clock to 2024-07-18 02:06:55 UTC (1721268415)
VFS: Mounted root (squashfs filesystem) readonly on device 31:3.
devtmpfs: mounted
Freeing unused kernel memory: 1024K
Run /init as init process
random: fast init done
overlayfs: upper fs does not support tmpfile.
overlayfs: upper fs does not support xattr, falling back to index=off and metacopy=off.
random: crng init done
phydev exist: resume phy
nvt_resume: find node
nvt_resume: led-inv = 0
nvt_resume: pinmux 0x22
DWC_ETH_QOS_yinit: apb_clk 120000000 Hz
Queue0 Tx fifo size 2048, Rx fifo size 2048
Disabled JUMBO pkt
Enabled Rx watchdog timer
Enabled TSO
Disabled Rx Split header mode
phydev exist: start phy
IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
DWC_ETH_QOS_adjust_link: start tx/rx
DWC_ETH_QOS f02b0000.eth eth0: Link is Up - 100Mbps/Full - flow control rx/tx
IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
kwrap: loading out-of-tree module taints kernel.
nvt_vos: 1.00.003 (Jan  4 2022 12:09:47)
nvtmem: module license 'Proprietary' taints kernel.
Disabling lock debugging due to kernel taint
NVTMEM: 0.0.1
kdrv_builtin_init init module ==========
nvt_jpg version: 1.00.007
kdrv_builtin_init init module ==========
log.ko v1.4: Jan  4 2022 12:01:35 (mmap 0x80d40000 size 0x21800)

LOG base 0x811c1800(ddr0) size 1K (start pointer 0x7f0e8eb4)
PAGE_OFFSET(0x80000000) VMALLOC START(0x82800000) HZ(100)
nvt_sif_init:
nvt_sif_probe:f0240000.sif
nvt_sif_probe:0. resource:0xf0240000 size:0x200
nvt_sif_probe:IRQ 0. ID44
nvt_sif_probe:DevID Major:249 minor:11
nvt_sif_drv_init:


nvt_csi_probe:not fast boot
nvtmpp_init_mmz: ddr1 pa = 0x2000000 va = 0x83000000 , size = 0x2000000
h26x kdrv version: 0.3.8, nvt codec version 0.3.9.0
nvt_audlib_aac_module_init:
nvt_audlib_g711_module_init:
hd_common_init
vprc init: stripe LV1 = cut w>1280, GDC =  on, 2D_LUT off after cut (LL slow)
venc init: config tile cut if w>1280 (LL slow)
csi_platform_clk_enable....
csi_open:CSI HW reset!
ERR:_isf_vdocap_do_getportstruct() get sen[0] fps failed!(-11)
ERR:_isf_vdocap_do_getportstruct() VCAP NOT START
ERR:vos_file_open() open [/mnt/app/isp/day-2_dpc.bin] failed, ret -2
ERR:vos_file_open() open [/mnt/app/isp/day-2_ecs.bin] failed, ret -2
ERR:vos_file_open() open [/mnt/app/isp/day-2_ecs_auto_0.bin] failed, ret -2
ERR:vos_file_open() open [/mnt/app/isp/day-2_ecs_auto_1.bin] failed, ret -2
ERR:vos_file_open() open [/mnt/app/isp/day-2_ecs_auto_2.bin] failed, ret -2
ERR:vos_file_open() open [/mnt/app/isp/day-2_lut2d.bin] failed, ret -2
ERR:_isf_vdocap_do_start() RAW buf insufficient(0x5498C0)
vprc: enable one-buf func at path 0, (3ndr_ref=0) (max_strp=3)
========== AE_CBMSG_PREVIEWSTABLE ==========
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!
nvt_i2c f0220000.i2c: i2c_nvtim_xfer_msg(671) NACK!

I beleive that kernel logs shows that problem start around "ERR:_isf_vdocap_do_getportstruct() get sen[0] fps failed!(-11)"

Selected sensor is sc401ai
/etc/sensors/sc401ai.yaml

sensor:
 name: sc401ai
 bus: i2c
 width: 2560
 height: 1440
 sensor_mode: 1 

/etc/sensors/sen_sc401ai.cfg

[MAP]
path_1 = 1                          #Path 1 Enable
path_2 = 0                          #Path 2 Disable
path_3 = 0                          #Path 3 Disable
path_4 = 0                          #Path 4 Disable
path_5 = 0                          #Path 5 Disable
path_6 = 0                          #Path 6 Disable
path_7 = 0                          #Path 7 Disable
path_8 = 0                          #Path 8 Disable

[PRESET]
id_0_expt_time = 10000              #10000us
id_0_gain_ratio = 1000              #1x gain

[DIRECTION]
id_0_mirror = 1                     #mirror
id_0_flip = 1                       #flip

[POWER]
id_0_mclk = 0                       #CTL_SEN_CLK_SEL_SIEMCLK
id_0_pwdn_pin = 0xFFFFFFFF          #no pwdn pin, C_GPIO:+0x0; P_GPIO:+0x20; S_GPIO:+0x40; L_GPIO:0x60...
id_0_rst_pin = 0x44                 #S_GPIO_4, C_GPIO:+0x0; P_GPIO:+0x20; S_GPIO:+0x40; L_GPIO:0x60
id_0_rst_time = 1                   #1ms
id_0_stable_time = 1                #1ms

[I2C]
id_0_i2c_id = 0                     #SEN_I2C_ID_2
id_0_i2c_addr = 0x30                #0x60>> 1 

As openipc.org says:
"Work in progress. We learned a lot about the platform hardware and code base, prepared the first public binary build, and are waiting for the first adopters to test it on their boards and provide feedback to help us move"
So here am I

@widgetii
Copy link
Member

Hi, NT98562 is broken for a long time due to absence of maintainers for the platform.

If you have programming skills you can help, otherwise it's better to use other supported platform

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

No branches or pull requests

2 participants