• Join
  • Sign In with my.TI Login
Texas Instruments
  • Products
  • Applications
  • Tools & Software
  • Support & Community
  • Sample & Buy
  • About TI
Sample & Purchase Cart Sample & Purchase Cart
  • Search
  • Advanced
TI E2E™ Community
  • Support Forums
  • Blogs
  • Groups
  • Videos
  • 简体中文
  • More ...
TI Home » TI E2E Community » Support Forums » Digital Signal Processors (DSP) » DaVinci™ Video Processors » DM64x DaVinci Video Processor Forum » DM648 dropping udp packets
Share
DaVinci™ Video Processors
  • Forums
  • Announcements
Options
  • Subscribe via RSS

Forums

DM648 dropping udp packets

This question is not answered
krishnamaiden
Posted by krishnamaiden
on Apr 09 2012 04:22 AM
Prodigy110 points

Hi All,

I am building an application that receives a udp stream with RTP data payload. I am on a private network with just the EVM dm648 and my workstation. I am using NDK ndk_2_20_06_35 with the NIMU compliant hal libraries released with NDK2.00.The UDP packets are streamed from my workstation via VLC media player. I am streaming a 10mbps clip 720x480 MPEG2 clip.

The issue I am facing is that when the UDP packets received in my application are parsed for the RTP payload sequence numbers, a packet drop is reported(some packet sequence number missing). This meant that some packets are dropped (50 packets of every 40000 received packets). Wireshark does not report any loss of packets on the network. To debug the issue further i did the following

  1. Increased UDP receive socket buffer to a comfortable large size(512k).
  2. Dumped the UDP statistics available in the NDK (udps). The statistics are as below
  3. RcvTotal       = 0000034507
    RcvShort       = 0000000000
    RcvBadLen      = 0000000000
    RcvBadSum      = 0000000000
    RcvFull        = 0000000000
    RcvNoPort      = 0000000741
    RcvNoPortB     = 0000000000
    SndTotal       = 0000000000
    SndNoPacket    = 0000000000. As RcvFull is set to zero I am assuming that the UDP recv buffer size if not an issue.
  4. the variable 'memory_squeeze_error' present in the ethernet hal library Ethdriver.c is not incremented, which led me to believe that the PBM is also not an issue.
  5. The finally the CPSW 3G register "RXSOFOVERRUNS"  indicating start of frame overruns was read and the value turned out to be 207. (this value kept varying based on the bit-rate of the clip being streamed).

To debug this further started using the benchmark udp testee application (ndk_2_0_0\packages\ti\ndk\benchmarks\copyUDP\testee\dm648) and added the print of the "RXSOFOVERRUNS" register at the end of the application. The here also is set as a non-zero value.

The question I have is

  1. How can i avoid the RXSOFOVERRUNS errors ? (Please note I only receive in my app i do not transmit data over a socket).
  2. Is one 10mbps stream too much to handle for the CPSW 3g ? I am writing the application to receive 3 10mbps streams.

Regards

Krishna

DM648 648 drivers NDK
Report Abuse
  • Reply
You have posted to a forum that requires a moderator to approve posts before they are publicly available.
All Replies
  • Prathap Srinivas
    Posted by Prathap Srinivas
    on Apr 09 2012 06:44 AM
    Expert3980 points

    Hi,

    I am not working on NDK but these are some generic queries/suggestions which you can verify if not already done.

    What is the UDP packet size? Are you sending packets with size greater than MTU/payload?

    If so, can you try sending packets lesser than MTU size & check.

    Also can you check with client example & testudp as suggested below-

    http://e2e.ti.com/support/embedded/bios/f/355/t/121331.aspx

    Also how are you increasing socket buffer size? Using setsockopt()? You can refer to the below link if required-

    http://e2e.ti.com/support/embedded/bios/f/355/t/126152.aspx

    Thanks,

    Prathap.

    If my reply answers your question then please click on the "Verify Answer" button.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • krishnamaiden
    Posted by krishnamaiden
    on Apr 09 2012 07:12 AM
    Prodigy110 points

    Hi Srinivas,

    Thanks for your reply. Please find he answers to your query as below

    • The UDP packet size as seen on wireshark is 1370 bytes. VLC media player is not sending any packets greater than the MTU size.
    • I have not tried that specific app that the link refers to but have tried another app from the same release at ndk_2_0_0\packages\ti\ndk\benchmarks\copyUDP\testee. This app also shows the same issue that i am seeing.
    • Regarding increasing the size of the buffer I am using setsockopt to increase the size of the buffers as with default values 8192 the buffers overflow (indicated by the udp statistics).

    Regards

    Krishan

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • Benoit Parrot
    Posted by Benoit Parrot
    on Apr 10 2012 17:31 PM
    Intellectual1400 points

    Krishan,

    I am not familiar with the NDK, but I am familiar with the cpsw3g module.
    What you are describing would make me think that you are exceeding one or more of the FIFO capacity.
    I would check that flow control is enabled. Is 'cpsw3g_SetSwitchFlowControl' invoked at all?

    Flow control is especially important between the switch and the host port.

    Regards,
    Benoit

    If my reply answers your question then please click on the "Verify Answer" button.

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
  • krishnamaiden
    Posted by krishnamaiden
    on Apr 13 2012 09:19 AM
    Prodigy110 points

    Hi Benoit,

    After adding the call to 'cpsw3g_SetSwitchFlowControl' in my API unfortunately the packet drops are still present. I am not sure if I am missing something configuration because even after calling this API the CPSW register  'TXPAUSEFRAMES' is being read as zero. I am receiving on port 1 my setting for that port are as below

    • P1_RX_MAX_BLKS = 6
    • P1_TX_MAX_BLKS = 14
    • P1_RX_BLK_CNT  = 2
    • P1_TX_BLK_CNT  = 4 
    • P1_P0TX_THRESH = 11
    • P1_P2TX_THRESH = 4
    • GMAC1->RX_CMF_EN = 1
    • GMAC1->RX_CSF_EN = 1
    • GMAC1->RX_CEF_EN =1
    • GMAC1->TX_FLOW_EN = 1
    • GMAC1->RX_FLOW_EN = 1

    Port 2 FIFO setting are as below

    • P2_RX_MAX_BLKS = 4
    • P2_TX_MAX_BLKS = 16 
    • P2_RX_BLK_CNT  = 4
    • P2_TX_BLK_CNT  = 16

    The CPSW_CONTROL register reads a 274.

    My the P1 flow control enabled ?

    Regards

    Krishna

     

     

    Report Abuse
    • Reply
    You have posted to a forum that requires a moderator to approve posts before they are publicly available.
TI E2E™ Community
  • Support Forums
  • Blogs
  • Videos
  • Groups
  • Site Support & Feedback
  • Settings
TI E2E™ Community Groups
  • TI University Program
  • Make the Switch
  • Microcontroller Projects
  • Motor Drive & Control
Other Communities
  • Deyisupport
  • Designsomething.org
  • beagleboard.org
  • TI on Element 14
  • TI on TechXchangeSM
Other Technical & Support Resources
  • WEBENCH® Design Center
  • Product Information Centers
  • Technical Documents
  • TI Design Network
  • TI Technical Articles
  • TI Training

All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.

Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms of Use of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms of Use of this site. TI, its suppliers and providers of content reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.

Follow Us Texas Instruments on Facebook Texas Instruments on Twitter Texas Instruments on LinkedIn Texas Instruments on Google+
TI Worldwide | Contact Us | my.TI Login | Site Map | Corporate Citizenship | mobile m.ti.com (Mobile Version)

TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs and
embedded processors, along with software, tools and the industry’s largest sales/support staff.

© Copyright 1995-2013 Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy Policy | Terms of Use