| Reply | « Previous Thread | Next Thread » |
|
Hi, sevih,
I add a line to solve the problem: CActiveScheduler::Add(this); Good luck ! |
|
Hi pinchiang,
a. Where did you add CActiveScheduler::Add(this); to fix the problem ? It's already in the code: CGetCallerId::CGetCallerId(): CActive(EPriorityStandard) { CActiveScheduler::Add(this); } When I try this code and try to add your line I get same error as other guys in this thread. Has anybody been able to make this working ? If Yes could you please put the working and corrected CPP file here ? b. If I call this from my Hello world app UI can I call this function to get the phone call any time (assume the log in my phone has some phone numbers saved) ? Or did you guys test it when there is incoming/outgoing call or after a termination ? I mean when do you call this function from the Hello World App UI ? Can you call it anytime ? Btw, what SDK do you use SDK 1.2 (for example phone 3650) or 2.0 (phone 6600). Best Regards, Symbian_porgrammer |
| Symbian_Programmer |
| View Public Profile |
| Find all posts by Symbian_Programmer |
|
If you don't need to support 6.1 devices (like the 7650), you can use
RMobileCall to get the caller id, which is quicker and more reliable. To use RMobileCall you Etelmm headers and LIBs, they are available from the Motorola A925 SDK (although they are for 7.0, these features are compatible with Series 60 phones based on 7.0s and 8.0a). See http://db.cs.helsinki.fi/~mraento/lx...l_listener.cpp for an example implementation. Miak |
| mikaraento |
| View Public Profile |
| Find all posts by mikaraento |
|
Hi sorry, I am quite new to this. would it be possible for someone to send me the full code of an application that will answer a call based on incoming number?
Cheers Oz. |
| oz.mortimer |
| View Public Profile |
| Find all posts by oz.mortimer |
|
Sometimes I wonder what's the use of putting up information. The link
I gave has at the top of the page a link for 'Building instructions and source code packages'. If that's enough, I don't know what is. Mika |
| mikaraento |
| View Public Profile |
| Find all posts by mikaraento |
|
Hi,
I didn't go throught whole discussion, I only look on title, so sorry if I will not answer it properly. I once develop the Call Engine and: - on S60 I used Call Log engine and other ETEL classes without any problems for capturing calls, getting dialed and remote party MSISDN - works perfectly on N6680, N6630... - on SE900 it also works, but you must copy here some libs and headers from Sendo(gsmadv.lib,gsmbas.lib) and Nokia 9200 SDK(etelagsm.h,etelbgsm.h) as I remember.... - on Motorola 925/A1000 you can easily get remote party dialed number, but it is not possible to get dialed NUMBER!!!!!! Don't know why? I didn't found a way how to do it. My advice: ======== Collect all SDK you can: Sendo, Motorola, old Nokia SDK. Sometimes they're useful.... If you need some source codes or more detailed description, I can put here something.... Just ask. Bye STeN |
|
Hi to all, I've tried to get the telephone number from a call but I can't do this...
I've got an active object that listen to the line and when answering a call it record the call. I put the code found in this thread, but if I call GetLatest() from HandleCommand of a view, the program quit. If I remove the GetLatest() and I try to see the content of the descriptor iTelNumber it is blank... This is my code // // iPhoneObserver.cpp // #include <e32base.h> #include <e32std.h> #include <etel.h> #include "phoneobserver.h" #include "recorderview.h" #include "recorder.hrh" #include <aknnotewrappers.h> CPhoneObserver::CPhoneObserver(): CActive(EPriorityStandard) { } CPhoneObserver::~CPhoneObserver() { Cancel(); } CPhoneObserver* CPhoneObserver::NewL(CRecorderView* aRecView, RLine* aLine) { CPhoneObserver* self = NewLC(aRecView, aLine); CleanupStack::Pop(self); return self; } CPhoneObserver* CPhoneObserver::NewLC(CRecorderView* aRecView, RLine* aLine) { CPhoneObserver* self = new (ELeave) CPhoneObserver(); CleanupStack::PushL(self); self->ConstructL(aRecView, aLine); return self; } void CPhoneObserver::RunL() { if (iStatus.Int() == KErrNone) { //here I put the code of the threads const CLogEvent& event = iRecentLogView->Event(); iTelNumber.Copy(event.Number()); if (iLineStatus == RCall::EStatusConnected) { //key event for muting the microphone RWsSession sess=CCoeEnv::Static()->WsSession(); TWsEvent event; TInt id=sess.FindWindowGroupIdentifier( 0, _L("*Phone?") ); event.SetType(EEventKey); event.SetTimeNow(); event.Key()->iCode = EKeyMenu; event.Key()->iModifiers = 0; event.Key()->iRepeats = 0; event.Key()->iScanCode = EStdKeyNull; sess.SendEventToWindowGroup( id, event ); event.SetType(EEventKey); event.SetTimeNow(); event.Key()->iCode = EKeyDownArrow; event.Key()->iModifiers = 0; event.Key()->iRepeats = 0; event.Key()->iScanCode = EStdKeyNull; sess.SendEventToWindowGroup( id, event ); event.SetType(EEventKey); event.SetTimeNow(); event.Key()->iCode = EKeyDownArrow; event.Key()->iModifiers = 0; event.Key()->iRepeats = 0; event.Key()->iScanCode = EStdKeyNull; sess.SendEventToWindowGroup( id, event ); event.SetType(EEventKey); event.SetTimeNow(); event.Key()->iCode = EKeyDownArrow; event.Key()->iModifiers = 0; event.Key()->iRepeats = 0; event.Key()->iScanCode = EStdKeyNull; sess.SendEventToWindowGroup( id, event ); event.SetType(EEventKey); event.SetTimeNow(); event.Key()->iCode = EKeyEnter; event.Key()->iModifiers = 0; event.Key()->iRepeats = 0; event.Key()->iScanCode = EStdKeyNull; sess.SendEventToWindowGroup( id, event ); //If line is connected, recording may start. iRecView -> HandleCommandL(EProgCmdRecord); } else if (iLineStatus == RCall::EStatusHangingUp) { //If line is hanging up, recorder must stop. iRecView -> HandleCommandL(EProgCmdStop); } Start(); } else { Cancel(); } } TInt CPhoneObserver::RunError(TInt Error) { return Error; } void CPhoneObserver::DoCancel() { iLine -> NotifyStatusChangeCancel(); //here code of the threads iRecentLogView->Cancel(); } void CPhoneObserver::ConstructL(CRecorderView* aRecView, RLine* aLine) { iRecView = aRecView; iLine = aLine; CActiveScheduler::Add(this); // Connect to the Log Server iFs.Connect(); iLogClient = CLogClient::NewL(iFs); iRecentLogView = CLogViewRecent::NewL(*iLogClient); } void CPhoneObserver::Start() { Cancel(); iLine -> NotifyStatusChange(iStatus, iLineStatus); SetActive(); } void CPhoneObserver::Deactivate() { DoCancel(); } //here the get latest from the threads void CPhoneObserver::GetLatest() { // Cancel any outstanding requests. iRecentLogView->Cancel(); // Make a call into the Log server to get the latest call event. if( iRecentLogView->SetRecentListL(KLogNullRecentList,iStatus)) { // Notify the Log server that we're ready SetActive(); } } In the view object I try to call: iPhoneObserver.getLatest() //this quit the program CAknInformationNote *notify; notify = new (ELeave) CAknInformationNote; notify->ExecuteLD(iPhoneObserver->iTelNumber); Can someone help me?Please, it's very important |
|
Nobody can help me?
|
|
hi,
through logs you won't get call being answered or call in ringing status. BR, Sudhakar |
| S.S.Sudhakar |
| View Public Profile |
| Find all posts by S.S.Sudhakar |
|
Ok, I've understand that...I've understand that in the method constructL of my observer I can inizialize the lo with
iFs.Connect(); iLogClient = CLogClient::NewL(iFs); iRecentLogView = CLogViewRecent::NewL(*iLogClient); I don't understand where I have to put const CLogEvent& event = iRecentLogView->Event(); iTelNumber.Copy(event.Number()); (I think it's the code that copy the caller number from the log to the descriptor) and iRecentLogView->SetRecentListL(KLogNullRecentList,iStatus); (this place in the last log event) Excuse me for troubling you... |
|
hi,
you can use CTelephony in symbian 7.0 onwards as per the link http://developer.symbian.com/main/do...ianOS_cat.html I have not trtied this out but as soon as i will i post more details. regards arun |
|
Join Date: Feb 2006
Posts: 16,442
Location: Zürich, Switzerland
Offline
Forum Nokia Champion
|
|
In fact you can not. etel3rdparty.dll is not present on most 2nd edition S60 devices (due to security reasons), thus CTelephony produces exotic errors instead of working.
|
| wizard_hu_ |
| View Public Profile |
| Find all posts by wizard_hu_ |
|
I found this working with 2nd edition FP 3 device (N72).
regards arun |
|
Join Date: Feb 2006
Posts: 16,442
Location: Zürich, Switzerland
Offline
Forum Nokia Champion
|
|
Yes, I have seen it in the other related post. However note that although there are more than one S60 2nd ed. FP3 devices (http://www.forum.nokia.com/devices/m...2ed_fp3_1.html), they are still not that widespread in fact.
|
| wizard_hu_ |
| View Public Profile |
| Find all posts by wizard_hu_ |
|
Hi,
For symbian 7 and 8. using RLine, RCall get the handle to the call. How to do this is available in wiki pages. iSession.Connect(); iSession.LoadPhoneModule(KTSY); iSession.GetPhoneInfo(0, phoneInfo); iPhone.Open(iSession, phoneInfo.iName); iPhone.EnumerateLines(numberLines); iLine.Open(iPhone, lineInfo.iName); iLine.NotifyIncomingCall(iStatus,iName); You should be using RLine::NotifyIncomingCall(). When an incoming call arrives, the RunL will be activated and in it if the calli is ringing (if(iLineStatus == RCall::EStatusRinging)) iFsSession.Connect(); iLogClient = CLogClient::NewL(iFsSession); iLogView = CLogViewRecent::NewL(*iLogClient); iLogFilter = CLogFilter::NewL(); iLogFilter->SetEventType(KLogCallEventTypeUid); TRAP(err,iLogView->SetRecentListL(KLogNullRecentList ,*iLogFilter, iStatus)); The runL will be called once the recent list is built and in runL const CLogEvent& event = iLogView->Event(); iCallerNumber.Copy(event.Number()); This gives the caller number. Wiki pages give enough information to do this. hope this helps arun Symbian 9 devices, you can CTelephony class and it is straight forward.
Last edited by arunpirku : 2008-02-22 at 11:53.
Reason: Additional info
|
| Reply | « Previous Thread | Next Thread » |
| Thread Tools | Search this Thread |
|---|---|