Unable to send more than 255 bytes of data over PPP link - PPP

This is a discussion on Unable to send more than 255 bytes of data over PPP link - PPP ; Hi All, I am trying to upload a file from my target board. I use tcp socket (My client code) to send data using HTTP POST to the remote apache server using ppp link. I have proper connectivity. My client ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: Unable to send more than 255 bytes of data over PPP link

  1. Unable to send more than 255 bytes of data over PPP link

    Hi All,

    I am trying to upload a file from my target board.

    I use tcp socket (My client code) to send data using HTTP POST to
    the remote apache server using ppp link.

    I have proper connectivity. My client code sends data to pppd over
    ttyU0 (virtual serial port on ussp driver) which forwards the data to
    cmux (gsm0710) driver which inurn gets transmitted to the Modem.

    I observed that when ever I send a file size greater than 255 bytes
    the data transfer takes a long time. The remote server times out and
    send HTTP error code 500.

    I enabled the debug level of CMUX and USSP driver according to it the
    data reaches to them after a long delay from PPPd .

    How do I fix this ? Can I print PPP packets ? I don't have pppStats
    facility for pppd. Even, I don't have debug option support in my pppd.


  2. Re: Unable to send more than 255 bytes of data over PPP link

    harsh writes:
    > I am trying to upload a file from my target board.


    You've left out a ton of crucial information. What is your "target
    board?" What OS does it run? What sorts of development facilities do
    you have? Do you have a remote debugger?

    > I observed that when ever I send a file size greater than 255 bytes
    > the data transfer takes a long time. The remote server times out and
    > send HTTP error code 500.


    That sounds like a pretty straightforward flaw somewhere in the code
    you're using.

    One possible problem (and a *really* wild guess) would be an incorrect
    MTU/MRU setting. Another would be broken flow control handling with
    the modem. Still another would be a buffer boundary problem.

    Depending on what sorts of tools you have, you might want to try
    inserting either debug messages ("printf") or enabling tracing for the
    functions called.

    Here are several general suggestions (nothing specific, as you've
    provided few useful details):

    - Simplify in order to isolate the problem. Try getting rid of PPP
    and writing an application that opens the serial port and sends
    and receives large buffers of data. Check if the serial port and
    modem actually work. Try using the same modem on a different
    system. Get rid of the modem and try a hard-wired serial
    connection. Eliminate as many variables as possible to test each
    part separately.

    - Re-examine configuration options. Make sure you're really setting
    the modem up properly according to its technical reference
    manual. Modems are *hard* to use right. Make sure the serial
    port parameters are correct. Check all of the PPP options
    (particularly LCP) that are being negotiated. Get two or three
    coworkers to help out with a design and/or code review.

    - Get an analyzer. A line analyzer can help you determine whether
    there's misbehavior on the wire and can provide an impartial look
    at the way the software is working.

    - Buy an off-the-shelf solution. If your time is worth anything to
    you, consider just buying a product from someone that already
    supports what you're trying to do. There are a lot of embedded
    system vendors out there.

    --
    James Carlson, Solaris Networking
    Sun Microsystems / 35 Network Drive 71.232W Vox +1 781 442 2084
    MS UBUR02-212 / Burlington MA 01803-2757 42.496N Fax +1 781 442 1677

+ Reply to Thread