Part Number:DRA746
Tool/software: Linux
Hi Sir
We used latest automotive processor SDK in J6 EVM for development.
And we would like to use mini USB port (USB 2.0) to connect with USB camera.
We found system was unstable to capture video for a long time.
For example, we used below sample code to capture video. the system will crash in 5 minutes.
#include <stdio.h>
#include <string.h>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
#include <opencv2/core/ocl.hpp>
#include <cstdio>
#include <opencv2/opencv.hpp>
using namespace cv;
void inituvc(cv::VideoCapture vc, int w, int h) {
vc.set(CV_CAP_PROP_FRAME_WIDTH, w);
vc.set(CV_CAP_PROP_FRAME_HEIGHT, h);
}
void show_live_video () {
VideoCapture capture(1);
inituvc (capture, 1920, 1080);
Mat frame;
while(waitKey(20)!=27)
{
capture>>frame;
if ( !frame.empty() )
imshow("ADAS", frame);
else
printf ("frame.empty()\n");
}
}
int main () {
printf ("OpenCV linking OK.\n");
show_live_video ();
return 0;
}
And the log message is showed below
[ 516.713750] Alignment trap: not handling instruction ed910b22 at [<b6d54e4c>]
[ 516.721573] Unhandled fault: alignment exception (0x221) at 0x000000a2
[ 516.728701] pgd = ed5ebec0
[ 516.731771] [000000a2] *pgd=ad731003, *pmd=df883003
[ 6463.274551] omap_hwmod: mmu1_dsp2: _wait_target_disable failed
[ 6463.288607] omap_hwmod: mmu0_dsp2: _wait_target_disable failed
[ 6463.301801] omap_hwmod: mmu1_dsp1: _wait_target_disable failed
[ 6463.315024] omap_hwmod: mmu0_dsp1: _wait_target_disable failed
[ 6701.894740] Alignment trap: not handling instruction ed8c2b1e at [<b6d60f00>]
[ 6701.902413] Unhandled fault: alignment exception (0xa21) at 0xfffffe77
[ 6701.911692] pgd = df96c080
[ 6701.914744] [fffffe77] *pgd=80000080007003, *pmd=affae003, *pte=00000000
[ 6701.997545] tvp5158 1-0058: Unable to of_probe
[ 6702.009575] omap_hwmod: mmu0_dsp2: _wait_target_disable failed
[ 6702.015466] omap-iommu 41501000.mmu: 41501000.mmu: version 3.0
[ 6702.022145] omap-iommu 41502000.mmu: 41502000.mmu: version 3.0
[ 6702.029825] tvp5158 1-0058: Unable to of_probe
[ 6702.041456] omap_hwmod: mmu0_dsp1: _wait_target_disable failed
[ 6702.047343] omap-iommu 40d01000.mmu: 40d01000.mmu: version 3.0
[ 6702.053945] omap-iommu 40d02000.mmu: 40d02000.mmu: version 3.0
[ 6702.063079] tvp5158 1-0058: Unable to of_probe
[ 6702.068746] tvp5158 1-0058: Unable to of_probe
[ 6712.271331] omap_hwmod: mmu1_dsp2: _wait_target_disable failed
[ 6712.284338] omap_hwmod: mmu0_dsp2: _wait_target_disable failed
[ 6712.297437] omap_hwmod: mmu1_dsp1: _wait_target_disable failed
[ 6712.310433] omap_hwmod: mmu0_dsp1: _wait_target_disable failed
please advise and thanks for your help
BR
Yimin