telephonyserverplugins/attestltsy/atcommand/generic/src/tsyconfg.cpp
author Tom Pritchard <tomp@symbian.org>
Wed, 17 Feb 2010 18:40:26 +0000
branchAT_Test_LTSY
changeset 3 70f1e1f5dabe
parent 1 4047d69ee0e4
permissions -rw-r--r--
Changes to the phonetsy name from commdb and the make voice dialing not require AT+WIND indications
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
     1
// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
     2
// All rights reserved.
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
     3
// This component and the accompanying materials are made available
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
     4
// under the terms of "Eclipse Public License v1.0"
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
     5
// which accompanies this distribution, and is available
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
     6
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
     7
//
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
     8
// Initial Contributors:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
     9
// Nokia Corporation - initial contribution.
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    10
//
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    11
// Contributors:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    12
//
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    13
// Description:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    14
// @file tsyconfig.cpp
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    15
// This contains CTsyConfig which manage access to CommDB configuration.
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    16
// 
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    17
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    18
// system include
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    19
#include <commsdattypesv1_1.h>
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    20
#include <commsdat_partner.h>
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    21
using namespace CommsDat;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    22
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    23
// user include
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    24
#include "tsyconfg.h"
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    25
#include "mslogger.h"
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    26
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    27
#ifdef __LOGDEB__
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    28
_LIT8(KLogEntry,"CTsyConfig::%S\t%S");
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    29
#define LOCAL_LOGTEXT(function,text) {_LIT8(F,function);_LIT8(T,text);LOGTEXT3(KLogEntry,&F,&T);}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    30
#else
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    31
#define LOCAL_LOGTEXT(function,text)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    32
#endif
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    33
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    34
// const defination
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    35
const TInt KDefaultLocationInternalPref = 0;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    36
const RCall::TMonitorSpeakerControl KDefaultModemSpeakerSetting = RCall::EMonitorSpeakerControlOnUntilCarrier;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    37
const RCall::TMonitorSpeakerVolume KDefaultMonitorSpeakerVolume = RCall::EMonitorSpeakerVolumeOff;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    38
const RCall::TWaitForDialTone KDefaultWaitForDialTone = RCall::EDialToneNoWait;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    39
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    40
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    41
// CTsyConfig::NewL
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    42
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    43
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    44
CTsyConfig* CTsyConfig::NewL() 
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    45
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    46
	CTsyConfig* self = new(ELeave) CTsyConfig();
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    47
	CleanupStack::PushL(self);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    48
	self->ConstructL(); 
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    49
	CleanupStack::Pop();
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    50
	return (self);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    51
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    52
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    53
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    54
// CTsyConfig::CTsyConfig
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    55
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    56
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    57
CTsyConfig::CTsyConfig()
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    58
	{	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    59
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    60
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    61
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    62
// CTsyConfig::ConstructL
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    63
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    64
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    65
void CTsyConfig::ConstructL()
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    66
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    67
	iLocationId = 0;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    68
	iModemBearer = 0;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    69
	SetCurrentTableViewL();
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    70
	GetLocationModemSettingsL();
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    71
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    72
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    73
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    74
// CTsyConfig::SetCurrentTableViewL
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    75
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    76
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    77
void CTsyConfig::SetCurrentTableViewL()
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    78
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    79
	TInt r = KErrNone;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    80
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    81
	for (TInt i = 0; i < 10; i++)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    82
		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    83
		TRAP(r, GetCurrentTableViewsL()); // Place a cursor on the default modem record in comms database server
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    84
		if (r == KErrAccessDenied)        // if we get access denied from DBMS, which is a timing thing, just re-post
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    85
			{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    86
			User::After(1000000);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    87
			continue;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    88
			}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    89
		else
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    90
			{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    91
			break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    92
			}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    93
		}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    94
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    95
	if(r)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    96
		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    97
		LOGTEXT(_L8("CommDB values seem to be corrupt"));
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    98
		User::Leave(KErrEtelModemSettingsCorrupt);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
    99
		}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   100
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   101
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   102
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   103
// CTsyConfig::GetLocationModemSettingsL
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   104
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   105
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   106
void CTsyConfig::GetLocationModemSettingsL()
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   107
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   108
	ASSERT(iModemBearer != 0);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   109
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   110
	iSpeakerSetting = KDefaultModemSpeakerSetting;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   111
	iSpeakerVolume = KDefaultMonitorSpeakerVolume;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   112
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   113
	if(iLocationId == 0)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   114
		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   115
		iInterval = KDefaultLocationInternalPref;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   116
		iWaitForDialTonePref = KDefaultWaitForDialTone;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   117
		}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   118
	else
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   119
		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   120
		TBool value(EFalse);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   121
		CMDBField<TUint32>* intervalField = new(ELeave) CMDBField<TUint32>(KCDTIdPauseAfterDialOut);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   122
		CleanupStack::PushL(intervalField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   123
		intervalField->SetRecordId(iLocationId);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   124
		intervalField->LoadL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   125
		iInterval = *intervalField;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   126
		CleanupStack::PopAndDestroy(intervalField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   127
		
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   128
		CMDBField<TUint32>* valueField = new(ELeave) CMDBField<TUint32>(KCDTIdWaitForDialTone);		
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   129
		CleanupStack::PushL(valueField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   130
		valueField->SetRecordId(iLocationId);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   131
		valueField->LoadL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   132
		value = *valueField;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   133
		CleanupStack::PopAndDestroy(valueField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   134
		
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   135
		if (value)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   136
			{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   137
			iWaitForDialTonePref = RCall::EDialToneWait;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   138
			}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   139
		else
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   140
			{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   141
			iWaitForDialTonePref = RCall::EDialToneNoWait;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   142
			}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   143
		}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   144
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   145
    // read speaker preferences
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   146
	CMDBField<TUint32>* speakerPrefField = new(ELeave) CMDBField<TUint32>(KCDTIdSpeakerPref);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   147
	CleanupStack::PushL(speakerPrefField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   148
	speakerPrefField->SetRecordId(iModemBearer);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   149
	speakerPrefField->LoadL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   150
	iSpeakerSetting = static_cast<RCall::TMonitorSpeakerControl>(static_cast<TUint32>(*speakerPrefField));
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   151
	CleanupStack::PopAndDestroy(speakerPrefField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   152
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   153
	// read speaker volume preferences
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   154
	CMDBField<TUint32>* speakerVolPrefField = new(ELeave) CMDBField<TUint32>(KCDTIdSpeakerVolPref);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   155
	CleanupStack::PushL(speakerVolPrefField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   156
	speakerVolPrefField->SetRecordId(iModemBearer);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   157
	speakerVolPrefField->LoadL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   158
	iSpeakerVolume = static_cast<RCall::TMonitorSpeakerVolume>(static_cast<TUint32>(*speakerVolPrefField));			
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   159
	CleanupStack::PopAndDestroy(speakerVolPrefField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   160
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   161
    // read modem rate
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   162
	CMDBField<TUint32>* rateField = new(ELeave) CMDBField<TUint32>(KCDTIdRate);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   163
	CleanupStack::PushL(rateField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   164
	rateField->SetRecordId(iModemBearer);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   165
	rateField->LoadL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   166
	TUint32 rate;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   167
	rate = *rateField;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   168
	CleanupStack::PopAndDestroy(rateField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   169
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   170
	// read data bits for modem
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   171
	CMDBField<TUint32>* dataBitsField = new(ELeave) CMDBField<TUint32>(KCDTIdDataBits);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   172
	CleanupStack::PushL(dataBitsField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   173
	dataBitsField->SetRecordId(iModemBearer);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   174
	dataBitsField->LoadL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   175
	TUint32 dataBits;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   176
	dataBits = *dataBitsField;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   177
	CleanupStack::PopAndDestroy(dataBitsField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   178
    
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   179
	// read stop bits for modem
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   180
	CMDBField<TUint32>* stopBitsField = new(ELeave) CMDBField<TUint32>(KCDTIdStopBits);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   181
	CleanupStack::PushL(stopBitsField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   182
	stopBitsField->SetRecordId(iModemBearer);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   183
	stopBitsField->LoadL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   184
	TUint32 stopBits;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   185
	stopBits = *stopBitsField;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   186
	CleanupStack::PopAndDestroy(stopBitsField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   187
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   188
	// read parity for modem
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   189
	CMDBField<TUint32>* parityField = new(ELeave) CMDBField<TUint32>(KCDTIdParity);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   190
	CleanupStack::PushL(parityField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   191
	parityField->SetRecordId(iModemBearer);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   192
	parityField->LoadL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   193
	TUint32 parity;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   194
	parity = *parityField;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   195
	CleanupStack::PopAndDestroy(parityField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   196
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   197
	// read handshake for modem
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   198
	CMDBField<TUint32>* handshakeField = new(ELeave) CMDBField<TUint32>(KCDTIdHandshaking);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   199
	CleanupStack::PushL(handshakeField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   200
	handshakeField->SetRecordId(iModemBearer);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   201
	handshakeField->LoadL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   202
	TUint32 handshake;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   203
	handshake = *handshakeField;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   204
	CleanupStack::PopAndDestroy(handshakeField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   205
    
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   206
	// set the modem configuration
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   207
	iConfig.iRate = (TBps)rate;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   208
	iConfig.iDataBits = (TDataBits)dataBits;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   209
	iConfig.iStopBits = (TStopBits)stopBits;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   210
	iConfig.iParity = (TParity)parity;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   211
	iConfig.iHandshake = handshake;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   212
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   213
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   214
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   215
// CTsyConfig::~CTsyConfig
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   216
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   217
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   218
CTsyConfig::~CTsyConfig()
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   219
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   220
	delete iDbSession;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   221
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   222
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   223
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   224
// CTsyConfig::ConfigModemStringL
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   225
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   226
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   227
TInt CTsyConfig::ConfigModemStringL(const TDesC& aStringTag, TDes8& aString)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   228
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   229
	ASSERT(iDbSession != 0);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   230
	CCDModemBearerRecord* modemRecord = static_cast<CCDModemBearerRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdModemBearerRecord));
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   231
	CleanupStack::PushL(modemRecord);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   232
	modemRecord->SetRecordId(iModemBearer);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   233
	modemRecord->LoadL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   234
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   235
	TInt ret;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   236
	TInt type(0);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   237
	CMDBElement* baseField = NULL;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   238
	TRAP(ret, baseField = modemRecord->GetFieldByNameL(aStringTag, type));
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   239
	if (ret == KErrNone)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   240
		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   241
		// check for type
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   242
		switch(type)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   243
			{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   244
			case EMedText:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   245
			case EText:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   246
				{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   247
				CMDBField<TDesC>* field16 = static_cast<CMDBField<TDesC>*>(baseField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   248
				const TDesC& refField = *field16;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   249
				aString.Copy(refField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   250
				ret = KErrNone;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   251
				}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   252
				break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   253
			case EDesC8:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   254
				{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   255
				CMDBField<TDesC8>* field = static_cast<CMDBField<TDesC8>*>(baseField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   256
				aString = *field;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   257
				ret = KErrNone;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   258
				}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   259
				break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   260
			default:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   261
				ret = KErrNotFound;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   262
			}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   263
    	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   264
	CleanupStack::PopAndDestroy(modemRecord);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   265
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   266
	return ret;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   267
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   268
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   269
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   270
// CTsyConfig::ConfigModemStringL
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   271
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   272
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   273
TInt CTsyConfig::ConfigModemStringL(const TDesC& aStringTag, TDes16& aString)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   274
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   275
	ASSERT(iDbSession != 0);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   276
	// get the table record
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   277
	CCDModemBearerRecord* modemRecord = static_cast<CCDModemBearerRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdModemBearerRecord));
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   278
	CleanupStack::PushL(modemRecord);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   279
	modemRecord->SetRecordId(iModemBearer);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   280
	modemRecord->LoadL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   281
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   282
	TInt ret;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   283
	TInt type(0);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   284
	CMDBElement* baseField = NULL;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   285
	TRAP(ret, baseField = modemRecord->GetFieldByNameL(aStringTag, type));
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   286
	if (ret == KErrNone)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   287
		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   288
		// check for type
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   289
		switch(type)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   290
			{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   291
			case EMedText:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   292
			case EText:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   293
				{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   294
				CMDBField<TDesC>* field = static_cast<CMDBField<TDesC>*>(baseField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   295
				aString = *field;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   296
				ret = KErrNone;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   297
				}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   298
				break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   299
			case EDesC8:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   300
				{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   301
				// des16 needs to be cast to des8
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   302
				CMDBField<TDesC8>* field8 = static_cast<CMDBField<TDesC8>*>(baseField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   303
				const TDesC8& refField = *field8;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   304
				aString.Copy(refField);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   305
				ret = KErrNone;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   306
				}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   307
				break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   308
			default:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   309
				ret = KErrNotFound;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   310
			}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   311
		}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   312
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   313
	CleanupStack::PopAndDestroy(modemRecord);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   314
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   315
	return ret;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   316
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   317
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   318
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   319
// CTsyConfig::GetSpeakerSettingPref
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   320
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   321
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   322
void CTsyConfig::GetSpeakerSettingPref(RCall::TMonitorSpeakerControl& aSpeakerSetting)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   323
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   324
	aSpeakerSetting = iSpeakerSetting;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   325
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   326
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   327
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   328
// CTsyConfig::GetSpeakerVolumePref
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   329
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   330
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   331
void CTsyConfig::GetSpeakerVolumePref(RCall::TMonitorSpeakerVolume& aSpeakerVolume)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   332
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   333
	aSpeakerVolume = iSpeakerVolume;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   334
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   335
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   336
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   337
// CTsyConfig::GetWaitForDialTonePref
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   338
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   339
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   340
void CTsyConfig::GetWaitForDialTonePref(RCall::TWaitForDialTone& aWaitForDialTonePref)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   341
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   342
	aWaitForDialTonePref = iWaitForDialTonePref;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   343
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   344
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   345
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   346
// CTsyConfig::PortConfig
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   347
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   348
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   349
TInt CTsyConfig::PortConfig(TCommConfig& aConfigPckg, TConfigType aConfigType)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   350
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   351
	TCommConfig configDummyPckg;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   352
	TCommConfigV01& config = configDummyPckg();
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   353
	config = iConfig;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   354
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   355
	if (aConfigType==EConfigTypeHangUp ||
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   356
		aConfigType==EConfigTypeQuickInit)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   357
		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   358
		config.iHandshake = 0;//&= (~(KConfigFailDCD | KConfigObeyDCD | KConfigFailDSR));
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   359
		}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   360
	else
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   361
		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   362
		switch (aConfigType)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   363
			{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   364
		case EConfigTypePreInit:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   365
			config.iHandshake &= (~(KConfigObeyCTS | KConfigFailCTS | KConfigObeyDCD | KConfigFailDCD | KConfigFailDSR));
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   366
			break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   367
		case EConfigTypeInit:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   368
			config.iHandshake &= (~(KConfigObeyCTS | KConfigFailCTS | KConfigObeyDCD | KConfigFailDCD));
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   369
			break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   370
		case EConfigTypeConnect:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   371
			config.iHandshake &= (~(KConfigFailCTS | KConfigFailDCD));	// fail DCD masked out, as should get NO CARRIER anyway
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   372
			break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   373
		case EConfigTypeFull:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   374
			break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   375
		case EConfigTypeDDBugWorkAroundStart:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   376
			if (config.iRate!=EBps300)	// ensure that something other than handshaking has changed
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   377
				config.iRate=EBps300;	// to work around the bug in the ARM device driver
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   378
			else
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   379
				config.iRate=EBps2400;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   380
			config.iHandshake=0;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   381
			break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   382
		case EConfigTypeDDBugWorkAroundEnd:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   383
			config.iHandshake=0;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   384
			break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   385
		default:
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   386
			break;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   387
			}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   388
		}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   389
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   390
	aConfigPckg=configDummyPckg;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   391
	return KErrNone;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   392
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   393
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   394
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   395
// CTsyConfig::GetCurrentTableViewsL
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   396
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   397
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   398
void CTsyConfig::GetCurrentTableViewsL() 
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   399
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   400
	ResetCurrentTableViews();
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   401
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   402
#ifdef SYMBIAN_NON_SEAMLESS_NETWORK_BEARER_MOBILITY
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   403
	iDbSession = CMDBSession::NewL(KCDVersion1_2);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   404
#else
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   405
	iDbSession = CMDBSession::NewL(KCDVersion1_1);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   406
#endif
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   407
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   408
	iModemBearer = 0;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   409
	iLocationId = 0;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   410
	// Search the bearer tables for records using the Phonetsy.TSY
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   411
	GetModemBearerIdL(iModemBearer);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   412
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   413
	// Get the associated locationId
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   414
	GetLocationIdL(iModemBearer,iLocationId);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   415
	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   416
	//Check if the selected bearer is an MMTSY bearer with a valid location
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   417
	if(!iModemBearer || !iLocationId) 
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   418
		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   419
		//
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   420
		// Selected bearer does not mention the MMTSY
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   421
		LOCAL_LOGTEXT("GetCurrentSettingsL","PhoneTSY not mentioned in the selected bearer");
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   422
		User::Leave(KErrNotFound);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   423
		}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   424
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   425
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   426
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   427
// CTsyConfig::ResetCurrentTableViews
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   428
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   429
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   430
void CTsyConfig::ResetCurrentTableViews()
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   431
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   432
	delete iDbSession;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   433
	iDbSession = NULL;		
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   434
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   435
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   436
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   437
// CTsyConfig::GetLocationIdL
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   438
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   439
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   440
void CTsyConfig::GetLocationIdL(const TUint32& aBearerId, TUint32& aLocationId) 
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   441
 	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   442
    CCDIAPRecord *iapRecord = static_cast<CCDIAPRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdIAPRecord));
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   443
  	CleanupStack::PushL(iapRecord);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   444
  	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   445
  	iapRecord->iBearer = aBearerId;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   446
  	TBool err = iapRecord->FindL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   447
  	if (err)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   448
  		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   449
  		aLocationId = iapRecord->iLocation;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   450
  		}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   451
  	else
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   452
  		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   453
  		aLocationId = static_cast<TUint32>(KErrNotFound);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   454
  		}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   455
  	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   456
    CleanupStack::PopAndDestroy(iapRecord);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   457
    
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   458
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   459
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   460
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   461
// CTsyConfig::GetModemBearerIdL
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   462
// other items were commented in a header
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   463
// ---------------------------------------------------------------------------
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   464
void CTsyConfig::GetModemBearerIdL(TUint32& aBearerId)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   465
	{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   466
    CCDModemBearerRecord *modemRecord = static_cast<CCDModemBearerRecord*>(CCDRecordBase::RecordFactoryL(KCDTIdModemBearerRecord));
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   467
    CleanupStack::PushL(modemRecord);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   468
    
3
70f1e1f5dabe Changes to the phonetsy name from commdb and the make voice dialing not require AT+WIND indications
Tom Pritchard <tomp@symbian.org>
parents: 1
diff changeset
   469
    _LIT(KTsyName,"phonetsy"); // Note this is case sensitive and must match the name in commdb
1
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   470
    modemRecord->iTsyName.SetMaxLengthL(KMaxTextLength);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   471
    modemRecord->iTsyName = KTsyName;
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   472
    
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   473
    TBool searchResult = modemRecord->FindL(*iDbSession);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   474
    
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   475
    if (searchResult)
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   476
	    {
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   477
		aBearerId = modemRecord->RecordId();	
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   478
	    }
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   479
	else
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   480
		{
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   481
		aBearerId = static_cast<TUint32>(KErrNotFound);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   482
		}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   483
    
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   484
    CleanupStack::PopAndDestroy(modemRecord);
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   485
	}
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   486
4047d69ee0e4 Initial upload of Nokia's AT based test LTSY which uses the dispatcher
Tom Pritchard <tomp@symbian.org>
parents:
diff changeset
   487
// End of file