×

Discussion Board

Results 1 to 6 of 6
  1. #1
    Registered User
    Join Date
    Jul 2004
    Posts
    40

    CIntConnectionInitiator - HOW?

    i am trying to open a socket connection without showing the connection prompt for my application.
    the application should be compatible with series 60 sdk 1.2 as well as sdk 2.1 phones.

    setting the database entry for the display prompt obviously is not very useful, since i don't want to change global settings for the phone, but only for my application. i tried that one first and did not even find a possibility where the user could reset the behaviour if he wanted.

    now i am working with override settings and CIntConnectionInitiator. code looks like this:

    if(iIntConn == NULL) {
    iIntConn = CIntConnectionInitiator::NewL();
    }

    TUint32 iapId;

    if(iIntConn->GetActiveIap(iapId) != KErrNone) {
    CCommDbOverrideSettings* shit =
    CCommDbOverrideSettings::
    NewL(CCommDbOverrideSettings::EParamListPartial,
    EDatabaseTypeIAP);
    CleanupStack::PushL(shit);
    CCommsDbConnectionPrefTableView::
    TCommDbIapConnectionPref prefs;
    prefs.iRanking = 1;
    prefs.iDirection = ECommDbConnectionDirectionOutgoing;
    prefs.iDialogPref = ECommDbDialogPrefDoNotPrompt;
    shit->SetConnectionPreferenceOverride(prefs);

    TRequestStatus stat(KRequestPending);
    iIntConn->ConnectL(prefs, stat);

    CleanupStack::PopAndDestroy(shit);

    }

    // create Socket Connection engine
    iEngine->ConnectL(KServer, iCred);



    i can see that a GPRS data connection is being opened, but then the program panics.

    so how the f**k do i open socket connections after i initialised the outgoing internet connection?
    i did not find any methods or parameters to be passed to the socket server...

    the documentation is completely useless there.

  2. #2
    Registered User
    Join Date
    Aug 2003
    Location
    Oulu, Finland
    Posts
    1,122
    TRequestStatus stat(KRequestPending);
    iIntConn->ConnectL(prefs, stat);
    You're setting up an asynchronous request here but you're never waiting for it to complete (for example, using active objects or plain old User::WaitForRequest()).

    See the IAP Connect examples on Forum Nokia for code examples: version 1.0 for 1.x SDKs (using CIntConnectionInitiator) and 2.0 for 2.x SDKs (using RConnection, CIntConnectionInitiator is deprecated in S60 2.0).

    Lauri

  3. #3
    Registered User
    Join Date
    Jul 2004
    Posts
    40
    plain old User::WaitForRequest does never return so i cut it out again. I guessed that ConnectL returns after the async event happens.

    RConnection does not help because sdk2.1 code does not run on sdk 1.2 phones, so sdk2.1 interfaces are best ignored for applications planned for the whole series 60 market since developing different solutions for each and every platform variation is much too costly. i wish nokia and symbian would come up with a clear concept for multi-flavoured platform-based application development instead of this silly multi-sdk mess.
    Last edited by peter.koellner; 2004-09-07 at 15:21.

  4. #4
    Super Contributor
    Join Date
    Apr 2003
    Location
    Czech Republic
    Posts
    915
    Seems to me pretty clear that if you have a portfolio of phones with very different capabilities on 3 different versions of operating system (Symbian OS 6.1, 7.0s, 8.0) you must have something like multiple SDKs. And it is not so messy how it looks once you get use to it.

  5. #5
    Registered User
    Join Date
    Jul 2004
    Posts
    40
    sorry, but i disagree. if applications are designed to use a capability available only on a certain model, it might be a solution to have separate SDKs for each variety. But not if you target development at -say- series 60 phones in general, that is a computer system with phone and internet capabilities and a graphical display, key input etc. with certain standard characteristics
    for that, i would like a single sdk with well-defined macros to switch between code versions if needed.

    what makes different sdks necessary at the moment is the lack of separation between build, emulator, target and project environment.

    let's take a look in the future, when, say, symbian 8.1x, 8.7 and 9.2 are out with series 60 1.2, 2.1, 2.2,2.5 and perhaps 3.1.

    how many sdks would i have to install on my development computer, and how many variations of source code would i have to provide to get my application service the majority of series 60 phones operational in the market?

    basically, if i have to develop 4 or 5 different source versions, an application that might otherwise be profitable could turn into a loss.

    that was the whole sense behind series 60, wasn't it? to establish a common platform so application development would not have to focus on single devices. i don't think that can be very successful in the longer run with such a fragmentated development environment.

  6. #6
    Super Contributor
    Join Date
    Apr 2003
    Location
    Czech Republic
    Posts
    915
    Of course you are right, but S60 platform becomes somewhat too fragmented and it will be more and more difficult to have some common ground...
    and imagine the mess when feature pack 3 comes and you will have a possibility to have S60 phone with different size of screen (not just 176x208)...:-)

Posting Permissions

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