×

Discussion Board

Results 1 to 2 of 2
  1. #1
    Registered User
    Join Date
    Mar 2003
    Posts
    30

    RE: How to release PDP context?

    Hello again,

    I don't know if anyone is interested in it, but I have the answer for my original question : we can release the GPRS PDP context by closing everything that is socket-related. I closed the sockets, host resolver and the socket server and since I was the only user of the connection, the connection got closed. That's all! I'm not sure if we have to do _all_ these things, but I think it's the best way.

    Some answers to nitin's requests :
    - I don't why your PC doesn't get the data sent by your phone. Are you behind a firewall? That may hinder incoming packets (from phone to PC). When you send a UDP datagram is it sent successfully? Do you have a snipper program for your PC? Sometimes the datagrams arrive to your PC, but perhaps because your program was configured improperly it doesn't get the packets at all.
    - Local IP as 0 : we had been struggling with this program for a long time, but we found the solution. Though we establish a GPRS connection manually (i.e. by code), I guess it's the same with dialog selection ==> we use RGenericAgent in order to establish a connection, but when it returns the connection has NOT been established yet! It was only the setup phase and we need to wait for a while in order to get a working connection. You can use the very same RGenericAgent object for progress notification : when it notices that the connection is up (connection state == EIfProgressLinkUp), then you can use the connection, then you can get your local IP address that won't be 0. So, the order : 1. RGenericAgent::StartOutgoing, 2. RGenericAgent::ProgressNotification.
    - Anyway, you can easily check whether there's a GPRS connection established ==> there's a 'G' letter near the top-left corner of the display. When this 'G' has a square around it, then the connection is up. When only the 'G' is visible, you've attached to the GPRS network. When this 'G' is crossed with a line : your GPRS connection is suspended.

    Hope I could help you,

    tOtE

  2. #2
    Registered User
    Join Date
    Mar 2003
    Posts
    30

    How to release PDP context?

    Hi there,

    I'd like to know how I can release GPRS PDP context when it's no longer needed. I don't want to close the connection, since it's not so nice if others are also using the same connection. Therefore I'd like to release the context, simply saying that I don't want to use it for a while. But how can I do that?
    My guess is that all I should do is closing the socket I'm using. Is it true? And if I always keep a host resolver (RHostResolver) open, should I close it as well? And what about the socket server (RSocketServ)?

    Thanks for your help in advance,

    tOtE

Posting Permissions

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