×

Discussion Board

Page 1 of 2 12 LastLast
Results 1 to 15 of 18
  1. #1
    Registered User
    Join Date
    Sep 2005
    Posts
    8

    Question Voice Call status with publish & subscribe

    Hi All,

    Does anybody know how to get information about voice calls etc using the publish & subscribe API?

    I'm writing an application for Symbian 9, and therefore can't use the system agent. Instead I've tried the following:

    RProperty callProperty;

    User::LeaveIfError(callProperty.Attach(KUidSystemCategory,KUidCurrentCallValue))

    TInt err;
    TInt value;

    if((err=callProperty.Get(value)) == KErrNone)
    {
    switch(value)
    case ESACallNone:
    //do stuff
    break;
    case ESACallVoice:
    //do stuff
    break;
    default:
    //default other states for now
    break;

    callProperty.Close();

    }

    I always get KErrNotFound on the Get() method.

    Now, I'm pretty sure that I'm using the wrong category or key or both when attaching to the property. These properties should already be defined in the system, right?

    Is there an alternative way of querying the system about call status?

    I Would really appreciate any help on this.

    Thanks, Hlynur

  2. #2
    Nokia Developer Expert
    Join Date
    Mar 2003
    Location
    Lempäälä/Finland
    Posts
    29,143

    Re: Voice Call status with publish & subscribe

    dunno about the P & S, but, you could also use CTelephony to get this information.

    yucca

  3. #3
    Super Contributor
    Join Date
    Nov 2004
    Location
    Wiltshire, UK
    Posts
    3,644

    Re: Voice Call status with publish & subscribe

    Is this on a real device or the emulator?

  4. #4
    Registered User
    Join Date
    Sep 2005
    Posts
    8

    Re: Voice Call status with publish & subscribe

    This is on a real device.

    There must be a way to get the call status without using CTelephony, no!?
    Cheers for the suggestion though yucca

    Hlynur

  5. #5
    Super Contributor
    Join Date
    Nov 2004
    Location
    Wiltshire, UK
    Posts
    3,644

    Re: Voice Call status with publish & subscribe

    I hav'nt tried this on an S60 3r edition device, but something simpler like RProperty::Get(KUidSystemCategory,KUidCurrentCallValue, value) might work better.

    The other thing to note is that you need to have ReadDeviceData & WriteDeviceData capability in your application.

    The documentation states that you need to have both read and write capability, though I SUSPECT you only need to have read capability.

  6. #6
    Registered User
    Join Date
    Sep 2005
    Posts
    8

    Re: Voice Call status with publish & subscribe

    I've tried RProperty::Get(KUidSystemCategory,KUidCurrentCallValue, value) as well and it consistently gives me a value of -19, regardless of if there is a call active or not.

    If access rights were needed (probably only ReadSystemData in this case), I'd expect to get a KErrAccessDenied error when trying to read the property.

    H

  7. #7
    Super Contributor
    Join Date
    Nov 2004
    Location
    Wiltshire, UK
    Posts
    3,644

    Re: Voice Call status with publish & subscribe

    I'm in the office tomorrow so I will run a quick test and see if it is broken

  8. #8
    Registered User
    Join Date
    Sep 2005
    Posts
    8

    Re: Voice Call status with publish & subscribe

    Thanks for your help Paul.

    I've actually resorted to using CTelephony for now, but it would be very useful to know how the predefined system properties should be used with the P&S API.

    Cheers, Hlynur

  9. #9
    Super Contributor
    Join Date
    Nov 2004
    Location
    Wiltshire, UK
    Posts
    3,644

    Re: Voice Call status with publish & subscribe

    My test app is showing the same behaviour. It appears that this is a bug and it seems to be present in 06w08.

    I suggest you raise it with your Forum Pro representative.

  10. #10
    Super Contributor
    Join Date
    Nov 2004
    Location
    Wiltshire, UK
    Posts
    3,644

    Re: Voice Call status with publish & subscribe

    This was tested on an E60

  11. #11
    Super Contributor
    Join Date
    Nov 2004
    Location
    Wiltshire, UK
    Posts
    3,644

    Re: Voice Call status with publish & subscribe

    I hav'nt had a chance to check it, but you might need to call StartSysAgt2 to register the properties you are looking for.

  12. #12
    Registered User
    Join Date
    Jun 2003
    Posts
    20

    Re: Voice Call status with publish & subscribe

    Hi all,
    I've got the same problem as hlynurjoh. I also assume (according to documentation) that StartSysAgt2 should be called before. But I can't find the .lib to link against, so I'm running into an "undefined refference". I tried to search all the winscw libs by content, but I couldn't find any lib containing it. Also they don't specify in the documentation a lib to link against. Could you help me on that?
    Thank you, and best regards,
    Marius Crisan

  13. #13
    Super Contributor
    Join Date
    Nov 2004
    Location
    Wiltshire, UK
    Posts
    3,644

    Re: Voice Call status with publish & subscribe

    Unfortunatly the StartSysAgt2 is in the SysAgt2Cli.dll file and library files are not supplied.

    I guess you are going to have to try to load the file using RLibrary and then call the first exported function.

  14. #14
    Registered User
    Join Date
    Jun 2003
    Posts
    20

    Re: Voice Call status with publish & subscribe

    That's not working either. It even doesn't follow the documentation, because I called that TLibraryFunction at ordinal 1 twice, and no KErrAlreadyExists jumped off. It's always returning KErrNone. Any other suggestions?

  15. #15
    Super Contributor
    Join Date
    Nov 2004
    Location
    Wiltshire, UK
    Posts
    3,644

    Re: Voice Call status with publish & subscribe

    I guess Nokia forgot to update the System Agent server with the system properties.
    What is meant to happen I believe is that as a legacy issue, the SysAgent2 server was supposed to setup and initialize these variables.

    The Licencee (in this case Nokia) was supposed to put the values in for these settings.

    The only thing I can suggest is to open a paid support issue with Nokia and see if they can come up with anything.

Page 1 of 2 12 LastLast

Similar Threads

  1. SX1 dialling initiates fax call instead of voice call
    By kdinn in forum Symbian Networking & Messaging (Closed)
    Replies: 3
    Last Post: 2005-08-25, 06:12
  2. Voice call and DTMF tones
    By kivitalo in forum General Messaging
    Replies: 0
    Last Post: 2005-06-17, 09:03
  3. Voice call using Nokia 12 module
    By CONTEMPO in forum Nokia M2M
    Replies: 3
    Last Post: 2005-01-28, 21:39
  4. How to make simultaneous VOICE and DATA call on a Nokia Phone?
    By venkat_nokia in forum PC Suite API and PC Connectivity SDK
    Replies: 0
    Last Post: 2004-04-28, 12:15
  5. Voice call in middle of a data call
    By njacharya21 in forum Mobile Java General
    Replies: 0
    Last Post: 2004-01-29, 16:20

Posting Permissions

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