×

Discussion Board

Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    Jan 2005
    Posts
    26

    Red face sending file over tcp/ip to symbian emulator

    Hello,
    I have wrote an server program with c# which sending file over tcp/ip.
    In emulator, my symbian program sending request to my server program.And then my server program begins to send 2-3kB sized frames to my emulator.When a frame has come to my symbian program, draw it to screen.

    My problem is that:
    Frame sending speed is a bit slowe.1-2 frame per second.This is on Adsl line speed.
    In local speed is 2-3 frame per second.
    (my packets size are 2560byte)

    I have used sdk socket example.
    //this is my recieving code
    void CSocketsEngine::MiuoConvertComplete(TInt aError)
    {
    if( aError == KErrNone )
    {
    .......
    iContainer.DrawNow();//drawing recieved image
    ....//sending new request for new image
    }
    }

    Adls speed 512kbit=52kB
    my frame size is 3kB
    In one second speed should be 52/3=27 frame
    Also in local,speed should be much more.
    What is the problem

  2. #2
    Registered User
    Join Date
    Jan 2005
    Posts
    26

    Re: sending file over tcp/ip to symbian emulator

    I use Series 60 2ns edition feature pack 2.
    May be emulator is slow ?:roll:

    My socket code like
    my code like this:
    //socketnegine.cpp
    void CSocketsEngine::ConstructL()
    {
    .........
    iMdaImageDescToBitmapUtility=CMdaImageDescToBitmapUtility::NewL(*this);
    iBitmap = new (ELeave) CFbsBitmap();
    iBitmap->Create(TSize(110,130), EColor64K);
    ......
    }
    void CSocketsEngine::ResponseReceived( const TDesC8& aBuffer )
    {
    .....//image recieving ends.
    TDesC8& ides=(TDesC8&) iResimBuffer;
    iMdaImageDescToBitmapUtility->OpenL(ides);
    .....................
    }

    void CSocketsEngine::MiuoCreateComplete(TInt /*aError*/)
    {

    };

    void CSocketsEngine::MiuoOpenComplete(TInt aError)
    {
    if( aError != KErrNone )
    {
    //
    }
    TInt frameCount = iMdaImageDescToBitmapUtility->FrameCount();
    if( frameCount == 0 )
    {
    //
    }

    TFrameInfo frame;
    iMdaImageDescToBitmapUtility->FrameInfo(0, frame);
    iMdaImageDescToBitmapUtility->ConvertL(*iBitmap);
    }

    void CSocketsEngine::MiuoConvertComplete(TInt aError)
    {
    TBuf16<50> savingpath;
    if( aError == KErrNone )
    {
    _LIT(savingpathLIT,"c:\\System\\Apps\\calismalar\\gelenresimler\\");
    savingpath.Append(savingpathLIT);
    savingpath.Append(imagenumber);
    savingpath.Append(_L(".bmp"));
    iBitmap->Save(savingpath);
    iMdaImageDescToBitmapUtility->Close();
    iContainer.DrawNow(); ///drawing image
    imagenumber.Zero();
    iBitmap->UnlockHeap(EFalse);
    savingpath.Zero();
    .................
    }
    }

    //container
    void CcalismalarContainer:: Draw(const TRect& aRect) const
    {
    CWindowGc& gc = SystemGc();

    if(iCurrentOutlineId==EDrawingScreen)
    {
    _LIT(savingpathLIT,"c:\\System\\Apps\\calismalar\\gelenresimler\\"); savingpath.Append(savingpathLIT);
    savingpath.Append(iSocketEngine->imagenumber);
    savingpath.Append(_L(".bmp"));
    iBitmap->Load(savingpath);
    savingpath.Zero();
    gc.BitBlt(TPoint(30,5),iBitmap);
    iBitmap->UnlockHeap(EFalse);
    }

Similar Threads

  1. Sockets in Symbian C++ for Series 60 Emulator.
    By tippu in forum Mobile Java Networking & Messaging & Security
    Replies: 2
    Last Post: 2006-03-10, 05:55
  2. Sending .jpg file from phone to PC
    By ja_calulot in forum General Messaging
    Replies: 7
    Last Post: 2006-02-13, 03:56
  3. File paths in Symbian C++?
    By maniac_2k in forum Symbian
    Replies: 5
    Last Post: 2004-08-05, 18:44
  4. nokia 7210 modem via IR doesn't work !
    By oussamaaiadi in forum PC Suite API and PC Connectivity SDK
    Replies: 1
    Last Post: 2003-03-06, 10:46
  5. Replies: 0
    Last Post: 2002-06-10, 12:24

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×