Discussion Board

Results 1 to 4 of 4
  1. #1
    Regular Contributor
    Join Date
    Jun 2004

    CMdaAudioToneUtility priority


    How do i set the priority of CMdaAudioToneUtility? When i do the following code:
    static const TInt KSoundFrequency = 9500;
    static const TInt KSoundDuration = 200000;
    void CToneAdapter::ConstructL()
        iMdaAudioToneUtility = CMdaAudioToneUtility::NewL(*this);
        // Configure the audio tone utility to play a single tone
        // causes MMdaAudioToneObserver::MatoPrepareComplete to be called
        iMdaAudioToneUtility->PrepareToPlayTone(KSoundFrequency, TTimeIntervalMicroSeconds(KSoundDuration));
        iMdaAudioToneUtility->SetPriority(80, (TMdaPriorityPreference)EMdaPriorityPreferenceTimeAndQuality);
    it gives me "CMdaAudioToneUti 0" What does this mean? I hope you gurus could help me. Thanks!

    Also, I'm having problems with CMdaAudioPlayerUtility and CMdaAudioRecorderUtility on N3650 and N7650. My app plays a wav file every minute when there is an active call. My app is fine on N6600. But when i use it on N3650 and N7650, the behavior is not very stable. Sometimes, it plays every minute, sometimes, it plays every other minute. Did any of you experience this kind of problem? How did you solve it? thank you very much.

  2. #2
    Nokia Developer Moderator
    Join Date
    Mar 2003

    Re: CMdaAudioToneUtility priority

    have you checked the callback error values with the CMdaAudioPlayerUtility and CMdaAudioRecorderUtility ?

    I basically have always find it very difficult to open a file with OS 6.1 phones during a phone call, but the playing has never really been a problem when the file is opened before the phone call. Quite often end up getting KErrCorrupt (-20) error time-to-time.


  3. #3
    Regular Contributor
    Join Date
    Jun 2004

    Re: CMdaAudioToneUtility priority

    Thank you for the quick reply yucca!

    but the playing has never really been a problem when the file is opened before the phone call
    i opened the file before observing for the phone for calls. i used CPeriodic to periodically call Play() method which in turn calls iMdaAudioPlayerUtility->Play(). Is it better to use SetRepeats that CPeriodic? I have to try SetRepeats tomorrow to see if it works.

    By the way, how do you set the priority of CMdaToneUtility? thank you very much!


  4. #4
    Regular Contributor
    Join Date
    Jun 2004

    Thumbs up Re: CMdaAudioToneUtility priority

    I realized that I could not set the priority in the ContructL method so I placed the SetPriority call in MatoPrepareComplete method. It now runs smoothly.

    With regards to the CMdaAudioPlayerUtility and CMdaAudioRecorderUtility, my wav file was the problem. I used CMdaToneUtility instead of these two classes.

Similar Threads

  1. Audio priority on 6630, 6680 and 6681
    By bpelt in forum Symbian Media (Closed)
    Replies: 2
    Last Post: 2006-01-19, 10:56
  2. Problems with CActiveScheduler
    By so002340 in forum Symbian
    Replies: 1
    Last Post: 2005-02-21, 14:01
  3. Question: Priority of Application Sounds
    By lwolff in forum Symbian
    Replies: 3
    Last Post: 2004-02-16, 09:56
  4. The priority of the connection in "Push Registry".
    By akokchai in forum Mobile Java General
    Replies: 0
    Last Post: 2003-02-24, 04:45
  5. How to create a high priority dialog?
    By ivuorio in forum Symbian
    Replies: 1
    Last Post: 2002-10-09, 10:07

Posting Permissions

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