|
1 /* |
|
2 * Copyright (c) 2005-2006 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: A class that stores audio accessory related information. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef BTACC_INFO_H |
|
20 #define BTACC_INFO_H |
|
21 |
|
22 // INCLUDES |
|
23 #include <bttypes.h> // TBTDevAddr |
|
24 |
|
25 // DATA TYPES |
|
26 |
|
27 // CLASS DECLARATION |
|
28 class TAccInfo |
|
29 { |
|
30 |
|
31 public: |
|
32 |
|
33 enum TSupportedFeaturesIndex |
|
34 { |
|
35 ERemConTGIndex = 3, |
|
36 EStereoIndex = 2, |
|
37 EHSPIndex = 1, |
|
38 EHFPIndex = 0 |
|
39 }; |
|
40 |
|
41 enum TAvrcpVersion |
|
42 { |
|
43 EAvrcpVersionNo14 = 0x0103, |
|
44 EAvrcpVersion14 = 0x0104 |
|
45 }; |
|
46 |
|
47 public: |
|
48 |
|
49 /** |
|
50 * Accessor for the |
|
51 * @return |
|
52 */ |
|
53 void SetBDAddress(const TBTDevAddr& aAddr); |
|
54 |
|
55 /** |
|
56 * Accessor for the |
|
57 * @return |
|
58 */ |
|
59 const TBTDevAddr& GetBDAddress(); |
|
60 |
|
61 /** |
|
62 * Accessor for the |
|
63 * @return |
|
64 */ |
|
65 void SetCapturingSupport(TBool aCapturingSupport); |
|
66 |
|
67 /** |
|
68 * Accessor for the |
|
69 * @return |
|
70 */ |
|
71 TBool GetCapturingSupport(); |
|
72 |
|
73 /** |
|
74 * Accessor for the |
|
75 * @return |
|
76 */ |
|
77 void SetSuppportedProfiles(TUint8 aSuppProfiles); |
|
78 |
|
79 /** |
|
80 * Accessor for the |
|
81 * @return |
|
82 */ |
|
83 TUint8 SupportedProfiles() const; |
|
84 |
|
85 /** |
|
86 * Accessor for the |
|
87 * @return |
|
88 */ |
|
89 void SetConnectedProfiles(TUint8 aConnProfiles); |
|
90 |
|
91 /** |
|
92 * Accessor for the |
|
93 * @return |
|
94 */ |
|
95 TUint8 ConnectedProfiles() const; |
|
96 |
|
97 /** |
|
98 * Accessor for the |
|
99 * @return |
|
100 */ |
|
101 void SetDeviceType(TUint8 aDeviceType); |
|
102 |
|
103 /** |
|
104 * Accessor for the |
|
105 * @return |
|
106 */ |
|
107 TUint8 DeviceType() const; |
|
108 |
|
109 /** |
|
110 * Accessor for the |
|
111 * @return |
|
112 */ |
|
113 void SetModel(TUint16 aModel); |
|
114 |
|
115 /** |
|
116 * Accessor for the |
|
117 * @return |
|
118 */ |
|
119 TUint16 Model() const; |
|
120 |
|
121 /** |
|
122 * Accessor for the |
|
123 * @return |
|
124 */ |
|
125 void SetSupportedFeature(TUint16 aSupportedFeature, TInt aPosition); |
|
126 |
|
127 /** |
|
128 * Accessor for the |
|
129 * @return |
|
130 */ |
|
131 TUint16 SupportedFeatureL(TInt aPosition) const; |
|
132 |
|
133 public: |
|
134 TBTDevAddr iAddr; |
|
135 TBool iCapturingSupport; // If accessory is capable of capturing or recording (DRM feature) |
|
136 TUint8 iSuppProfiles; // Supported profile in the remote device |
|
137 TUint8 iConnProfiles; // Connected Profiles from the remote device point of view |
|
138 TUint8 iAudioOpenedProfiles; // The profiles that currently have audio link. |
|
139 TUint8 iDeviceType; // 0x1 headset device, 0x2 carkit (@see AccPolGenericid.h) |
|
140 TUint16 iModel; |
|
141 TUint16 iAvrcpVersion; // 0x00 AVRCP1.3, 0x01 AVRCP1.4 |
|
142 TFixedArray<TUint16,8> iSupportedFeatures; // position of objects matched TSupportedFeaturesIndex |
|
143 }; |
|
144 |
|
145 #endif // BTACC_INFO_H |
|
146 |
|
147 // End of File |