0
|
1 |
/*
|
|
2 |
* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
|
|
3 |
* All rights reserved.
|
|
4 |
* This component and the accompanying materials are made available
|
|
5 |
* under the terms of "Eclipse Public License v1.0"
|
|
6 |
* which accompanies this distribution, and is available
|
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
8 |
*
|
|
9 |
* Initial Contributors:
|
|
10 |
* Nokia Corporation - initial contribution.
|
|
11 |
*
|
|
12 |
* Contributors:
|
|
13 |
*
|
|
14 |
* Description:
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
#ifndef __DbgTrcPortMgr_h__
|
|
19 |
#define __DbgTrcPortMgr_h__
|
|
20 |
|
|
21 |
// System includes
|
|
22 |
#include <e32base.h>
|
|
23 |
#include <c32comm.h>
|
|
24 |
|
|
25 |
#include "dbgtrccomm.h"
|
|
26 |
|
|
27 |
class CPortReader;
|
|
28 |
class CPortWriter;
|
|
29 |
|
|
30 |
class CDbgTrcPortMgr : public CBase
|
|
31 |
{
|
|
32 |
|
|
33 |
public:
|
|
34 |
static CDbgTrcPortMgr* NewL();
|
|
35 |
~CDbgTrcPortMgr();
|
|
36 |
|
|
37 |
//private construct
|
|
38 |
private:
|
|
39 |
CDbgTrcPortMgr() {};
|
|
40 |
void ConstructL();
|
|
41 |
|
|
42 |
public:
|
|
43 |
TInt OpenPortL();
|
|
44 |
TInt ClosePort();
|
|
45 |
|
|
46 |
void GetPortConfig(TDes8& aDes);
|
|
47 |
TInt SetPortConfig(const TDesC8& aDes);
|
|
48 |
|
|
49 |
CPortWriter* GetPortWriter();
|
|
50 |
CPortReader* GetPortReader();
|
|
51 |
|
|
52 |
// data members
|
|
53 |
private:
|
|
54 |
|
|
55 |
TBuf<32> iPDD;
|
|
56 |
TBuf<32> iLDD;
|
|
57 |
TBuf<32> iCSY;
|
|
58 |
TUint iPortNumber;
|
|
59 |
TBaudRates iRate;
|
|
60 |
|
|
61 |
RCommServ iServer;
|
|
62 |
RComm iPort;
|
|
63 |
|
|
64 |
TBool iServerStarted;
|
|
65 |
TBool iConnected;
|
|
66 |
TBool iActiveConnections;
|
|
67 |
|
|
68 |
CPortReader* iReader;
|
|
69 |
CPortWriter* iWriter;
|
|
70 |
|
|
71 |
TAcmConfigV01 iAcmConfig;
|
|
72 |
|
|
73 |
};
|
|
74 |
|
|
75 |
#endif //__DbgTrcPortMgr_h__
|