This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux: VSDKv3.4 supports 4CH AVB Capture + Surround View (DSPx) + Display (HDMI) (TDA2x & TDA2Ex ONLY)

Other Parts Discussed in Thread: TDA2

Tool/software: Linux

Hi, 

As the release note of VSDKv3.4 which support 4CH AVB Capture + Surround View (DSPx) + Display (HDMI)  on TDA2x board.

As known that there is one ethernet MAC on theTDA2x board.

Q1: How to support the use-case of 4CH AVB capture + Surround view+ Display (HDMI)?

       Does it need add an Ethernet Swtich controller on the board?

Q2: How to recongize/identify the AVB capture link/ video stream of 4CH?

regards,

Sam.

  • HI,

    Please refer the below usecase and doc

    vision_sdk\apps\src\hlos\adas\src\usecases\avb_rx_multi_cam_3d_srv

    vision_sdk\docs\Linux\VisionSDK_Linux_UserGuide.pdf

    Regards,

    Anuj

  • log_avb_ether_2018_1008.txtHi Anuj,

    Thanks for your reply.

    I follow the steps of userguide to build image of  user case 2: 4CH AVB Capture + Decode + SGX 3D-SRV + DISPLAY.

    Based on VSDKv3.5, I modified the following:

    ### Ensure that A15_TARGET_OS := Linux and NDK_PROC_TO_USE=ipu2

    in \vision_sdk\$(MAKEAPPNAME)\configs\$(MAKECONFIG)\cfg.mk

    ### dra72-evm-common.dtsi for TDA2xx) from kernel

    (ti_components/os_tools/linux/kernel/omap/arch/arm/boot/dts)as shown below

    Change below

    &mac {

    status = "okay";

    to

    &mac {

    status = "disabled";

    Basically you need to disable mac from Kernel so VSDK can use it exclusively.

    It occurred the kernel panic error when plug into a 3rd AVB camera.

    Could you help intruct me how to solve the issue? Thanks.

    The message as the following:  In details, refer to the attached.

    [  167.595061] cpsw 48484000.ethernet eth0: Link is Up - 100Mbps/Full - flow control off

    [  167.603010] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready

    [  167.620438] Unable to handle kernel paging request at virtual address 48486034

    [  167.627719] pgd = c0003000

    [  167.630438] [48486034] *pgd=80000080005003, *pmd=00000000

    [  167.635879] Internal error: Oops: 205 [#1] PREEMPT SMP ARM

    [  167.641385] Modules linked in: memcache(O) xhci_plat_hcd xhci_hcd usbcore rpmsg_proto dwc3 udc_core virtio_rpmsg_bus ahci_platform libahci_platform libahci l                                                                             ibata omap_sham extcon_usb_gpio omap_aes_driver c_can_platform scsi_mod c_can ca                                                                             n_dev dwc3_omap omap_des extcon omap_rng rng_core rtc_omap omap_remoteproc remot                                                                             eproc virtio virtio_ring sch_fq_codel

    [  167.672959] CPU: 0 PID: 185 Comm: kworker/0:3 Tainted: G        W  O    4.4.84-00032-g0f6b93d #1

    [  167.681781] Hardware name: Generic DRA74X (Flattened Device Tree)

    [  167.687905] Workqueue: events_power_efficient phy_state_machine

    [  167.693856] task: ee664200 ti: ee656000 task.ti: ee656000

    [  167.699281] PC is at cpsw_rx_handler+0x14/0x1f8

    [  167.703830] LR is at __cpdma_chan_free+0x9c/0xb8

    [  167.708466] pc : [<c045861c>]    lr : [<c04521d4>]    psr: 600f0113

    [  167.708466] sp : ee657c00  ip : ee657c30  fp : ee657c2c

    [  167.719992] r10: c001c6b0  r9 : 00010000  r8 : 00000556

    [  167.725236] r7 : 48486020  r6 : 48486020  r5 : eeac69d0  r4 : fa486000

    [  167.731790] r3 : c0458608  r2 : 00010000  r1 : 00000556  r0 : 48486020

    [  167.738345] Flags: nZCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment kernel

    [  167.745683] Control: 30c5387d  Table: ae70c140  DAC: fffffffd

    [  167.751451] Process kworker/0:3 (pid: 185, stack limit = 0xee656210)

    [  167.757829] Stack: (0xee657c00 to 0xee658000

  • Hi Anuj,

    I have built an image with AVB RX USc in main menu, verified it by connect an AVB camera with Ethernet.

    it just show CPU-cores usage without video frame on HDMI TV when select the item of “4CH AVB + SGX mosaic SRV +DISPLAY”

    it show the error message of “Calibrated SGX LUT is NOT present” on console when select item of “4CH AVB + SGX 3D-SRV +DISPLAY”.

    And I also tried to use “Surround view calibration” to generate a default SGX LUT, but it got failure.

    Could you help instruct us how to calibrate/generate SGX LUT for AVB capture devices? Thanks.

    BRs,

    Sam Hsieh

  • Hi Shiju,

    As the vision_sdk\docs\Linux\VisionSDK_Linux_UserGuide.pdf,
    I observed that there is some conflicts in the configuration for 4CH AVB SUV UCs (tda2_evm_linux_all/cfg.mk).

    For TDA2xx & TDA2Ex - vision SDK Linux can run on either IPU1 or IPU2 subsystem
    And the AVBRX link Id - can be used for supported CPUs only.
    / *
    * Supported CPUs: ipu1_0, ipu1_1, a15_0 in TDA2xx
    * Supported CPUs: ipu1_0, ipu1_1 in TDA3xx
    */

    Why does it need "PROC_IPU2_INCLUDE=yes", "IPU_PRIMARY_CORE=ipu2" for 4CH AVB SUV UCs?
    If there is any mistakes, please let me know. Thanks.

    regards,
    Sam Hsieh
  • Hi,

    There is no mistake.
    Internally all links are mapped to IPU2 from IPU1_0 in linux case.

    Can you download a fresh vsdk3.5 and tried to run the usecase by following the guide.

    Regards,
    Anuj
  • Hi Anuj,

    Thanks for your feedback.

    I confirmed that the UCs of Multi LVDS camera SRV works fine with the latest VSDK v3.5 on TDA2XX EVM board.

    and both IPU1_0 & IPU1_1 core should be disabled for VSDK Linux.

    But the UCs of AVB camera RX SRV can't work fine.

    Could you help confirm that the UCs configuration in tda2xx_evm_linux/cfg.mk file ? Thanks.

    PROC_IPU1_0_INCLUDE=no
    PROC_IPU2_INCLUDE=yes
    PROC_A15_INCLUDE=yes

    IPU_PRIMARY_CORE=ipu2

    NDK_PROC_TO_USE=ipu2
    A15_TARGET_OS=Linux

    regards,

    Sam Hsieh

    ps. The picture is from Vision SDK SW_architechure overview. it doesn't mention the IPU2 core.

  • Hi Anuj,

    As the above configuration, it seems that the UCs work fine  from the log message of attached except lens calibration (LUT) missed.

    But it can't display any image frame on the HDMI TV execpt TI surround view title and processor utiliztion.

    Could you help instruct me how to look into the issue? Thanks.

    regards,

    Sam. TDA2XX_AVB_SRV_log.txt

  • Hi Sam,
    Which file did you modify to disable the mac for TDA2x ?
    Is it dra7-evm.dts or dra72-evm-common.dtsi
    For TDA2x, you should disable the mac in dra7-evm.dts & for TDA2Ex, in dra72-evm-common.dtsi
    While building, modify the config file as below
    NDK_PROC_TO_USE=ipu2
    AVB_INCLUDE=yes

    Regards
    Surya
  • Hi Surya,

    Thanks for your feedback.

    Yes, I confirmed that I have disabled the MACs by the following command:

    $cat /proc/device-tree/ocp/ethernet\@48484000/status   ==>disabled

    regards,

    Sam.

  • Hi Surya,

    I tried look into the AvbRxLink_tskRun() function which AVBRx link object/task,

    And detect whether if there is any MJPEG frames from AVB driver,

    But it just receive the SYSTEM_CMD_PRINT_STATISTICS message, there is no SYSTEM_CMD_NEW_DATA message from AVB driver.

    And it shows that there are no input packets received in the [ AVBTP RX ] Link Statistics,

    As I known that the Ethernet MAC is disabled for AVB captures,

    Could you tell me what’s the entry point of AVBRX driver? Thanks.

    regards,

    Sam.

  • Hello Sam,

    sam hsieh said:

    Q1: How to support the use-case of 4CH AVB capture + Surround view+ Display (HDMI)?

           Does it need add an Ethernet Swtich controller on the board?

    Yes, if you have more than single camera, you need to have switch in between cameras and TDA

    sam hsieh said:

    Q2: How to recongize/identify the AVB capture link/ video stream of 4CH?

    The cameras are recognized using AVB stream IDs. These needs to be different for each camera and needs to be configured in the ChainsCommon_SetAvbRxPrm function. Currently stream IDs are set to below. You can change these to your values in apps/src/hlos/common/chains_common.c.

    {0x01, 0x23, 0x45, 0x67, 0x89, 0xAB, 0xCD, 0xE1}, //front
    {0x01, 0x23, 0x45, 0x67, 0x89, 0xAB, 0xCD, 0xE0}, //right
    {0x01, 0x23, 0x45, 0x67, 0x89, 0xAB, 0xCD, 0xE2}, //back
    {0x01, 0x23, 0x45, 0x67, 0x89, 0xAB, 0xCD, 0xE3}, //left

    Also can you please reply to below queries?

    1. Are you using PC talker or actual AVB cameras? If later, how are cameras connected to TDA? 

    2. Is this TI EVM or custom board?

    Regards,

    Prasad

  • Hi Prasad,

    Thank you for your feedback.

    I currently connect an actual AVB camera via a common switch(no VLAN) with TDA2X EVM board.

    Even though rebuild the utility of avbtalker,  it's fail by run avbtalker on PC because the dependency issue of libavformat-ffmpeg.so.56 and Ubuntu 18.04 (must be in Ubuntu 16.04). 

    BTW, I thought that the listener (AVBRX) should receive all broadcast packets from any AVB camera.

    It means that the AVBRX run as promiscuous mode on ethernet. Is it correct or not?

    Could you let me know which code filter/drop the packets from the other streamIDs (not default)? Thanks.

    ps. The streamID of My AVB camera: [01 23 45 67 89 ab cd ef] 

    regards,

    Sam Hsieh.

  • Hello Sam,

    sam hsieh said:
    Even though rebuild the utility of avbtalker,  it's fail by run avbtalker on PC because the dependency issue of libavformat-ffmpeg.so.56 and Ubuntu 18.04 (must be in Ubuntu 16.04). 

    There should be latest library available for Ubuntu 18.04. Please check online for more info.

    sam hsieh said:

    BTW, I thought that the listener (AVBRX) should receive all broadcast packets from any AVB camera.

    Yes, listener can receive all broadcast packets but it would ignore if stream id configured for AVBRX and stream id of received stream doesn't match.

    Also if you configure camera to send multicast and add that multicast to TDA side, you can receive multicast as well.

    Also cameracan send unicast with TDA MAC address.

    sam hsieh said:

    Could you let me know which code filter/drop the packets from the other streamIDs (not default)? Thanks.

    This code is present in the AVBTP package. The function AVBTP_processRxPackets  in PROCESSOR_SDK_VISION_xx_xx\ti_components\networking\avbtp_0_10_00_00\packages\ti\avbtp\avbtp.c processes all receive packets and matches it to stream id.

    Please put breakpoint in this function, see if its hit, and why packets gets dropped here.

    sam hsieh said:

    ps. The streamID of My AVB camera: [01 23 45 67 89 ab cd ef] 

    This doesn't match with TI default ({0x01, 0x23, 0x45, 0x67, 0x89, 0xAB, 0xCD, 0xE1-4}, please change this in common.c file as suggested earlier.

    Also, run AVB mosaic use-case with single camera for debug.

    Regards,

    Prasad

  • Hi Prasad,

    Thanks for your recommendation.

    I tried to replaced the default streamID with my actual AVB camera, but it can't captured any AVBTP packet.

    At the same time, I added the LOGE message in  AVBTP_processRxPackets() function,

    It seems that the whole AVBTP package doesn't have been rebuild all manually, 

    Could you teach me how to rebuild AVBTP stack package only? Thanks.

    BTW, my AVB camera just send broadcast AVBTP packets, without multicast/unicast packet supprt.

    regards,

    Sam Hsieh

  • Hello Sam,

    You can follow instrunctions in AVB user-guide for building the AVB package alone.
    avbtp_0_10_00_00/docs/avbtp_0_10_00_00_user_guide.html#Build_lib

    Make sure you give XDC path in command line when building the package.
    xdc all --xdcpath=”/ti/PROCESSOR_SDK_VISION_03_03_00_00/ti_components/ os_tools/bios_6_46_04_53/packages” --jobs 4