Beagleboardxm and MT9P031

13 views
Skip to first unread message

Lorenzo Salvemini

unread,
May 14, 2021, 5:25:51 AM5/14/21
to BeagleBoard
Hi all,
I'm using Beagleboardxm with MT9P031 senosr.
I can capture the frames but looking at the buffer saved with yavta I see the maximum value is 511 instead of 4095 for a white. It seems tha only 9 bit are correctly read.
I'm using Kernel 5.0.19 and the sesor is correctly reegistered.
Inside the device tree I put the following:
&i2c2 {
clock-frequency = <100000>;

mt9p031@48 {
compatible = "aptina,mt9p031";
reg = <0x48>;

clocks = <&isp 0>;
reset-gpios = <&gpio4 2 GPIO_ACTIVE_LOW>;

vaa-supply = <&hsusb2_power>;
vdd-supply = <&vaux3>;
vdd_io-supply = <&vaux4>;

port {
mt9p031_out: endpoint {
input-clock-frequency = <21000000>;
pixel-clock-frequency = <48000000>;
remote-endpoint = <&ccdc_ep>;
};
};
};
};

&isp {
#address-cells = <1>;
#size-cells = <0>;

ports {
port@0 {
reg = <0>;
ccdc_ep: endpoint {
remote-endpoint = <&mt9p031_out>;
bus-width = <12>;
hsync-active = <1>;
vsync-active = <1>;
pclk-sample = <0>;
};
};
};
};

Here below the ouput of media-ctl-p:
Media controller API version 5.0.19

Media device information
------------------------
driver          omap3isp
model           TI OMAP3 ISP
serial          
bus info        
hw revision     0xf0
driver version  5.0.19

Device topology
- entity 1: OMAP3 ISP CCP2 (2 pads, 2 links)
            type V4L2 subdev subtype Unknown flags 0
            device node name /dev/v4l-subdev0
pad0: Sink
[fmt:SGRBG10_1X10/4096x4096 field:none colorspace:srgb]
<- "OMAP3 ISP CCP2 input":0 []
pad1: Source
[fmt:SGRBG10_1X10/4096x4096 field:none colorspace:srgb]
-> "OMAP3 ISP CCDC":0 []

- entity 4: OMAP3 ISP CCP2 input (1 pad, 1 link)
            type Node subtype V4L flags 0
            device node name /dev/video0
pad0: Source
-> "OMAP3 ISP CCP2":0 []

- entity 8: OMAP3 ISP CSI2a (2 pads, 2 links)
            type V4L2 subdev subtype Unknown flags 0
            device node name /dev/v4l-subdev1
pad0: Sink
[fmt:SGRBG10_1X10/4096x4096 field:none colorspace:srgb]
pad1: Source
[fmt:SGRBG10_1X10/4096x4096 field:none colorspace:srgb]
-> "OMAP3 ISP CSI2a output":0 []
-> "OMAP3 ISP CCDC":0 []

- entity 11: OMAP3 ISP CSI2a output (1 pad, 1 link)
             type Node subtype V4L flags 0
             device node name /dev/video1
pad0: Sink
<- "OMAP3 ISP CSI2a":1 []

- entity 15: OMAP3 ISP CCDC (3 pads, 9 links)
             type V4L2 subdev subtype Unknown flags 0
             device node name /dev/v4l-subdev2
pad0: Sink
[fmt:SGRBG12_1X12/688x486 field:none colorspace:srgb]
<- "OMAP3 ISP CCP2":1 []
<- "OMAP3 ISP CSI2a":1 []
<- "mt9p031 1-005d":0 [ENABLED]
pad1: Source
[fmt:SGRBG12_1X12/688x486 field:none colorspace:srgb
crop.bounds:(0,0)/688x486
crop:(0,0)/688x486]
-> "OMAP3 ISP CCDC output":0 [ENABLED]
-> "OMAP3 ISP resizer":0 []
pad2: Source
[fmt:SGRBG10_1X10/688x485 field:none colorspace:srgb]
-> "OMAP3 ISP preview":0 []
-> "OMAP3 ISP AEWB":0 [ENABLED,IMMUTABLE]
-> "OMAP3 ISP AF":0 [ENABLED,IMMUTABLE]
-> "OMAP3 ISP histogram":0 [ENABLED,IMMUTABLE]

- entity 19: OMAP3 ISP CCDC output (1 pad, 1 link)
             type Node subtype V4L flags 0
             device node name /dev/video2
pad0: Sink
<- "OMAP3 ISP CCDC":1 [ENABLED]

- entity 23: OMAP3 ISP preview (2 pads, 4 links)
             type V4L2 subdev subtype Unknown flags 0
             device node name /dev/v4l-subdev3
pad0: Sink
[fmt:SGRBG10_1X10/2592x1943 field:none colorspace:srgb
crop.bounds:(8,4)/2578x1935
crop:(10,4)/2574x1935]
<- "OMAP3 ISP CCDC":2 []
<- "OMAP3 ISP preview input":0 []
pad1: Source
[fmt:UYVY8_1X16/2574x1935 field:none colorspace:jpeg]
-> "OMAP3 ISP preview output":0 []
-> "OMAP3 ISP resizer":0 []

- entity 26: OMAP3 ISP preview input (1 pad, 1 link)
             type Node subtype V4L flags 0
             device node name /dev/video3
pad0: Source
-> "OMAP3 ISP preview":0 []

- entity 30: OMAP3 ISP preview output (1 pad, 1 link)
             type Node subtype V4L flags 0
             device node name /dev/video4
pad0: Sink
<- "OMAP3 ISP preview":1 []

- entity 34: OMAP3 ISP resizer (2 pads, 4 links)
             type V4L2 subdev subtype Unknown flags 0
             device node name /dev/v4l-subdev4
pad0: Sink
[fmt:UYVY8_1X16/2574x1935 field:none colorspace:jpeg
crop.bounds:(1,1)/2572x1933
crop:(1,1)/2572x1933]
<- "OMAP3 ISP CCDC":1 []
<- "OMAP3 ISP preview":1 []
<- "OMAP3 ISP resizer input":0 []
pad1: Source
[fmt:UYVY8_1X16/1024x768 field:none colorspace:jpeg]
-> "OMAP3 ISP resizer output":0 []

- entity 37: OMAP3 ISP resizer input (1 pad, 1 link)
             type Node subtype V4L flags 0
             device node name /dev/video5
pad0: Source
-> "OMAP3 ISP resizer":0 []

- entity 41: OMAP3 ISP resizer output (1 pad, 1 link)
             type Node subtype V4L flags 1
             device node name /dev/video6
pad0: Sink
<- "OMAP3 ISP resizer":1 []

- entity 45: OMAP3 ISP AEWB (1 pad, 1 link)
             type V4L2 subdev subtype Unknown flags 0
             device node name /dev/v4l-subdev5
pad0: Sink
<- "OMAP3 ISP CCDC":2 [ENABLED,IMMUTABLE]

- entity 47: OMAP3 ISP AF (1 pad, 1 link)
             type V4L2 subdev subtype Unknown flags 0
             device node name /dev/v4l-subdev6
pad0: Sink
<- "OMAP3 ISP CCDC":2 [ENABLED,IMMUTABLE]

- entity 49: OMAP3 ISP histogram (1 pad, 1 link)
             type V4L2 subdev subtype Unknown flags 0
             device node name /dev/v4l-subdev7
pad0: Sink
<- "OMAP3 ISP CCDC":2 [ENABLED,IMMUTABLE]

- entity 81: mt9p031 1-005d (1 pad, 1 link)
             type V4L2 subdev subtype Sensor flags 0
             device node name /dev/v4l-subdev8
pad0: Source
[fmt:SGRBG12_1X12/688x486 field:none colorspace:srgb
crop:(0,0)/2752x1944]
-> "OMAP3 ISP CCDC":0 [ENABLED]

Any hints or tips are very appreciated
Reply all
Reply to author
Forward
0 new messages