Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Developer
Posts: 45
Registered: ‎01-18-2013
My Device: 9000
My Carrier: CMCC

Phone.endCall() does not work on 10.3.0.700

hi,everyone

 

I want to develop a call blocker app. The sdk is 10.3.0.700 for device Z10.  I'm  testing the phone.enCall() function to end an ongoing call,but It DOES NOT work.

 

Following is the error information from the console:

//---------------------------------------------------------------------------------------

PpsPermission unable to open path: "/pps/services/phone/private/calls/.all?delta" 

PpsPermission unable to open path: "/pps/services/phone/protected/enterprise_call_data/.all?delta"
"cellular" line updated. Total lines count is 1
"vchat" line updated. Total lines count is 2
PpsObject::read failed to read pps data, error "Resource temporarily unavailable"
PpsControl unable to open path: /pps/services/phone/private/control
PpsControl unable to open path: /pps/services/phone/private/control
PhonePrivate::endCall: invalid callId: 33

//---------------------------------------------------------------------------------------

 

I had set three permissions in the 'bar-descriptor.xml' file

 

<permission>read_phonecall_details</permission>
<permission>access_phone</permission>
<permission>control_phone</permission>

 

Source code:

 

void Quicker::onCallUpdated(const bb::system::phone::Call &call)
{

    QString aasdf=call.phoneNumber();

    qDebug()<<aasdf;

    Phone phone;
    phone.endCall(call.callId());
}

 

Anyone meet this issue?  

 

Thanks a lot!

 

Developer
Posts: 246
Registered: ‎09-30-2010
My Device: Z10, Onyx2
My Carrier: IND XL

Re: Phone.endCall() does not work on 10.3.0.700

i dont have this issue..
i test it on my device and it was working well.
im using z10 too
maybe there is something wrong with the callid
Highlighted
Developer
Posts: 45
Registered: ‎01-18-2013
My Device: 9000
My Carrier: CMCC

Re: Phone.endCall() does not work on 10.3.0.700

hi,anditsung:

 

Thanks for your reply.

The callid is get from the onCallUpdated() funciton:

 

void Quicker::onCallUpdated(const bb::system::phone::Call &call)
{

    QString aasdf=call.phoneNumber();

    qDebug()<<aasdf;

    Phone phone;
    phone.endCall(call.callId());
}

The callid is increased by one.

 

 

Developer
Posts: 246
Registered: ‎09-30-2010
My Device: Z10, Onyx2
My Carrier: IND XL

Re: Phone.endCall() does not work on 10.3.0.700

yes, im aware of that

but the error information you provide suggest that there is something wrong with the call id

 

PhonePrivate::endCall: invalid callId: 33

Developer
Posts: 45
Registered: ‎01-18-2013
My Device: 9000
My Carrier: CMCC

Re: Phone.endCall() does not work on 10.3.0.700

Hi, anditsung,thanks again.
But how to get the incoming call's callid?
Developer
Posts: 45
Registered: ‎01-18-2013
My Device: 9000
My Carrier: CMCC

Re: Phone.endCall() does not work on 10.3.0.700

nobody know that?
BlackBerry Development Advisor
Posts: 15,696
Registered: ‎07-09-2008
My Device: BlackBerry PRIV
My Carrier: Bell

Re: Phone.endCall() does not work on 10.3.0.700

I posted an example of ending a call in this thread.  You can give that sample a try.

Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker