rtos-only下can't probe sensor on 2

Viewed 22

问题描述


我在canmv v1.1开发板上的csi2接口接了GC2093摄像头,但是运行sample_uvc_dev_vicap测试,报上述错误,defconfig脚本如下:
CONFIG_MPP_ENABLE_CSI_DEV_0=y
CONFIG_MPP_CSI_DEV0_RESET=0
CONFIG_MPP_CSI_DEV0_I2C_DEV="i2c3"
CONFIG_MPP_CSI_DEV0_MCLK_1=y
CONFIG_MPP_ENABLE_CSI_DEV_1=y
CONFIG_MPP_CSI_DEV1_RESET=23
CONFIG_MPP_CSI_DEV1_I2C_DEV="i2c0"
CONFIG_MPP_ENABLE_CSI_DEV_2=y
CONFIG_MPP_CSI_DEV2_RESET=24
CONFIG_MPP_CSI_DEV2_I2C_DEV="i2c1"
CONFIG_MPP_ENABLE_SENSOR_GC2093=y
CONFIG_MPP_SENSOR_GC2093_ON_CSI0_USE_CHIP_CLK=y
CONFIG_MPP_ENABLE_SENSOR_OV5647=y
CONFIG_MPP_SENSOR_OV5647_ON_CSI0_USE_CHIP_CLK=y
CONFIG_MPP_ENABLE_SENSOR_IMX335=y
CONFIG_MPP_SENSOR_IMX335_ON_CSI0_USE_CHIP_CLK=y
CONFIG_MPP_ENABLE_SENSOR_BF3238=y
CONFIG_MPP_ENABLE_SENSOR_BF3238_ON_CSI0_USE_CHIP_CLK=y

运行log如下:
U-Boot SPL 2022.10-00007-g7164d1b3 (Oct 27 2025 - 08:08:43 +0000)
00000000: PMU Major Msg: End of CA training
00000000: PMU Major Msg: End of initialization
00000000: PMU Major Msg: End of read enable training
00000000: PMU Major Msg: End of fine write leveling
00000000: PMU Major Msg: End of read dq deskew training
00000000: PMU Major Msg: End of MPR read delay center optimization
00000000: PMU Major Msg: End of Write leveling coarse delay
00000000: PMU Major Msg: End of write delay center optimization
00000000: PMU Major Msg: End of read delay center optimization
00000000: PMU Major Msg: End of max read latency training
00000000: PMU Major Msg: Firmware run has completed
load image 306245 bytes, time 93730 us, speed 3000 KB/s

U-Boot 2022.10-00007-g7164d1b3 (Oct 27 2025 - 08:08:43 +0000)

CPU: rv64imafdcvsu
Model: kendryte k230 canmv
DRAM: 512 MiB
Core: 26 devices, 13 uclasses, devicetree: separate
MMC: mmc0@91580000: 0, mmc1@91581000: 1
Loading Environment from MMC... OK
In: serial@91400000
Out: serial@91400000
Err: serial@91400000
Net: No ethernet found.
Hit any key to stop autoboot: 0
load image 1648028 bytes, time 69237 us, speed 23000 KB/s
Jump to big hart

OpenSBI v1.2.2
heap: [0x004e6380 - 0x024e6380], size 32768 KB
page: [0x024e6388 - 0x0fffec00], size 224354 KB

\ | /

  • RT - Thread Smart Operating System
    / | \ 5.0.0 build Nov 10 2025
    2006 - 2020 Copyright by rt-thread team
    lwIP-2.1.2 initialized!
    [I/I2C] I2C bus [i2c0] registered
    [I/I2C] I2C bus [i2c1] registered
    [I/I2C] I2C bus [i2c2] registered
    [I/I2C] I2C bus [i2c3] registered
    [I/I2C] I2C bus [i2c4] registered
    [E/drv_touch] touch probe failed.
    [I/SDIO] SD card capacity 30627840 KB.
    found part[0], begin: 52428800, size: 10.0MB
    found part[1], begin: 62914560, size: 500.0MB
    found part[2], begin: 1073741824, size: 28.213GB
    ▒Xcc
    OK

<ai_2d> ▒Xcc
OK

[I/sal.skt] Socket Abstraction Layer initialize success.
/dev/shm file system initialization done!
find sensor(ov5647_csi0) on csi0
vicap_mcm_init
#############SDK VERSION######################################
SDK : v0.5-20251110-093040-kevin-P920-3fa7ad3
nncase: 2.9.0
##############################################################
msh />/sdcard/app/userapps/sample_uvc_dev_vicap.elf -c 2
UVC Camera Demo Started
Using CSI device: 2
ERROR: can't probe sensor on 2, output 1920x1080@30
Deinitializing VB...
UVC Camera Demo Finished
msh />

硬件板卡


canmv k230 v1.1

软件版本


CanMV-K230_sdcard_v2.0_nncase_v2.10.0.img.gz

其他信息


我试着把CSI0摄像头拆掉,发现启动log中can't probe find sensor on csi0,看起来像是只使能了csi0:
U-Boot SPL 2022.10-00007-g7164d1b3 (Oct 27 2025 - 08:08:43 +0000)
00000000: PMU Major Msg: End of CA training
00000000: PMU Major Msg: End of initialization
00000000: PMU Major Msg: End of read enable training
00000000: PMU Major Msg: End of fine write leveling
00000000: PMU Major Msg: End of read dq deskew training
00000000: PMU Major Msg: End of MPR read delay center optimization
00000000: PMU Major Msg: End of Write leveling coarse delay
00000000: PMU Major Msg: End of write delay center optimization
00000000: PMU Major Msg: End of read delay center optimization
00000000: PMU Major Msg: End of max read latency training
00000000: PMU Major Msg: Firmware run has completed
load image 306245 bytes, time 93732 us, speed 3000 KB/s

U-Boot 2022.10-00007-g7164d1b3 (Oct 27 2025 - 08:08:43 +0000)

CPU: rv64imafdcvsu
Model: kendryte k230 canmv
DRAM: 512 MiB
Core: 26 devices, 13 uclasses, devicetree: separate
MMC: mmc0@91580000: 0, mmc1@91581000: 1
Loading Environment from MMC... OK
In: serial@91400000
Out: serial@91400000
Err: serial@91400000
Net: No ethernet found.
Hit any key to stop autoboot: 0
load image 1648028 bytes, time 69235 us, speed 23000 KB/s
Jump to big hart

OpenSBI v1.2.2
heap: [0x004e6380 - 0x024e6380], size 32768 KB
page: [0x024e6388 - 0x0fffec00], size 224354 KB

\ | /

  • RT - Thread Smart Operating System
    / | \ 5.0.0 build Nov 10 2025
    2006 - 2020 Copyright by rt-thread team
    lwIP-2.1.2 initialized!
    [I/I2C] I2C bus [i2c0] registered
    [I/I2C] I2C bus [i2c1] registered
    [I/I2C] I2C bus [i2c2] registered
    [I/I2C] I2C bus [i2c3] registered
    [I/I2C] I2C bus [i2c4] registered
    [E/drv_touch] touch probe failed.
    [I/SDIO] SD card capacity 30627840 KB.
    found part[0], begin: 52428800, size: 10.0MB
    found part[1], begin: 62914560, size: 500.0MB
    found part[2], begin: 1073741824, size: 28.213GB
    ▒Xcc
    OK

<ai_2d> ▒Xcc
OK

[I/sal.skt] Socket Abstraction Layer initialize success.
/dev/shm file system initialization done!
Can't find sensor on csi0
vicap_mcm_init
#############SDK VERSION######################################
SDK : v0.5-20251110-093040-kevin-P920-3fa7ad3
nncase: 2.9.0
##############################################################
msh />

2 Answers

你好,V1.1的板子,btb接口是使用的CSI0, 因此demo需要传参 -c 0