|
1 // Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // @file tlbsutils.h |
|
15 // This is the header file which contains the common utility functions |
|
16 // |
|
17 // |
|
18 |
|
19 /** |
|
20 @file |
|
21 @internalTechnology |
|
22 @test |
|
23 */ |
|
24 |
|
25 #ifndef __T_LBS_UTILS_H__ |
|
26 #define __T_LBS_UTILS_H__ |
|
27 |
|
28 |
|
29 // Epoc includes |
|
30 #include <e32cmn.h> |
|
31 |
|
32 // LBS includes |
|
33 #include <lbs.h> |
|
34 #include <lbscommon.h> |
|
35 #include <lbspositioninfo.h> |
|
36 #include <lbs/lbsassistancereferencetime.h> |
|
37 #include <lbsclasstypes.h> |
|
38 #include <lbs/lbsadmin.h> |
|
39 #include <lbs/lbsextendedsatellite.h> |
|
40 #include <lbs/lbsgpsmeasurement.h> |
|
41 #include <lbs/lbslocdatasourcegpsbase.h> |
|
42 |
|
43 // Forward Declaration |
|
44 |
|
45 // Includes for Log Comparison |
|
46 #include <lbs/lbslogevent.h> |
|
47 #include <lbs/lbsselflocatelogevent.h> |
|
48 #include <lbs/lbsexternallocatelogevent.h> |
|
49 #include <lbs/lbstransmitlocationlogevent.h> |
|
50 #include <lbs/lbsnetworklocatelogevent.h> |
|
51 #include <lbs/lbsassistancedatalogevent.h> |
|
52 |
|
53 |
|
54 |
|
55 |
|
56 // Property Keys |
|
57 enum TLbsTestPropertyKeys |
|
58 { |
|
59 ELbsTestAGpsModuleIn = 1301, |
|
60 ELbsTestAGpsModuleOut = 2301, |
|
61 ELbsTestClockPluginOut = 3301, |
|
62 ELbsTestAGpsModuleModeChanges = 4301, |
|
63 ELbsTestAGpsModuleResetAssistanceDataFlag = 5301, |
|
64 ELbsTestAGpsModuleCancelCount = 6301, |
|
65 //ELbsTestAGpsModuleAssistanceDataRequestFlag = 7301 //NOTE: This property is defined in tlbsdefs.h - please do not use value 7301 again |
|
66 ELbsTestAGpsModuleClientMode = 8301 |
|
67 }; |
|
68 |
|
69 enum KLbsTestAGpsModuleResetAssistanceDataStates |
|
70 { |
|
71 ELbsTestAGpsResetAssistanceDataNotReceived, |
|
72 ELbsTestAGpsResetAssistanceDataReceived |
|
73 }; |
|
74 |
|
75 |
|
76 const TInt KMaxModuleDataBusIniFileName = 100; |
|
77 |
|
78 // assistance data providers: |
|
79 const TInt KSimpleAssistanceDataProviderPluginUidValue = 0x10281D77; |
|
80 const TInt KSuplAssistanceDataProviderPluginUidValue = 0x10285AC2; |
|
81 |
|
82 |
|
83 /** Update structure to hold both measurement and position (location) information. |
|
84 */ |
|
85 class TLbsModuleUpdateItem |
|
86 { |
|
87 public: |
|
88 IMPORT_C TLbsModuleUpdateItem(); |
|
89 |
|
90 IMPORT_C const TPositionExtendedSatelliteInfo& Position() const; |
|
91 IMPORT_C const TPositionGpsMeasurementInfo& Measurement() const; |
|
92 IMPORT_C TInt Error() const; |
|
93 IMPORT_C TInt Delay() const; |
|
94 |
|
95 IMPORT_C void SetPosition(const TPositionExtendedSatelliteInfo& aReport); |
|
96 IMPORT_C void SetMeasurement(const TPositionGpsMeasurementInfo& aMeasurement); |
|
97 IMPORT_C void SetError(TInt aError); |
|
98 IMPORT_C void SetDelay(TInt aDelay); |
|
99 |
|
100 |
|
101 protected: |
|
102 TPositionExtendedSatelliteInfo iPosition; |
|
103 TPositionGpsMeasurementInfo iMeasurement; |
|
104 TInt iError; |
|
105 TInt iDelay; |
|
106 }; |
|
107 |
|
108 |
|
109 |
|
110 // Passing data to test module. |
|
111 class TModuleDataIn |
|
112 { |
|
113 public: |
|
114 /** Supported request types. */ |
|
115 enum TModuleRequestType |
|
116 { |
|
117 EModuleRequestConfig, |
|
118 EModuleRequestEventKickOff, |
|
119 EModuleRequestTestMode, |
|
120 EModuleRequestTimeOut, |
|
121 EModuleRequestError, |
|
122 EModuleRequestTimeStampOffset, |
|
123 EModuleRequestOptionsChangeReportMode |
|
124 }; |
|
125 TModuleRequestType iRequestType; |
|
126 |
|
127 |
|
128 /** Config request data. */ |
|
129 TBuf<KMaxModuleDataBusIniFileName> iConfigFileName; |
|
130 TBuf<40> iConfigSection; // bug if you make it bigger, more data we add, we get a -9 buf overflow on the property read |
|
131 |
|
132 |
|
133 /** Event kick off request data. */ |
|
134 enum _TKickOffEventType |
|
135 { |
|
136 EKickOffEventTypeDevice=0x01, |
|
137 EKickOffEventTypeDataQuality=0x02 |
|
138 }; |
|
139 typedef TUint TKickOffEventType; |
|
140 TKickOffEventType iKickOffEventType; |
|
141 |
|
142 |
|
143 /** Assistance event data. */ |
|
144 enum TAssDataEventType |
|
145 { |
|
146 EAssDataEventExpectSingle, |
|
147 EAssDataEventExpectMultiple |
|
148 }; |
|
149 TAssDataEventType iAssDataEventType; |
|
150 |
|
151 |
|
152 /** Module test mode. */ |
|
153 enum TTestMode |
|
154 { |
|
155 EModuleTestModeAssDataOff, |
|
156 EModuleTestModeAssDataOn, |
|
157 EModuleTestModeAssDataOn_TimeStamp, |
|
158 EModuleTestModeAssDataOn_Cancel_Stage1, |
|
159 EModuleTestModeAssDataOn_Cancel_Stage2, |
|
160 EModuleTestModeAssDataOn_Unsolicited, |
|
161 EModuleTestModeAssDataOn_NoNetwork, |
|
162 EModuleTestModeAssDataOn_DataNotAvailable, |
|
163 EModuleTestModeAssDataOn_SomeDataNotAvailable, |
|
164 EModuleTestModeAssDataOn_InvalidDataRequest, |
|
165 EModuleTestModeAssDataOn_InvalidDataGet, |
|
166 EModuleTestModeAssDataOn_EarlyPosUpdates |
|
167 }; |
|
168 TTestMode iAssDataTestMode; |
|
169 |
|
170 enum TGpsOptionsChangeReportMode |
|
171 { |
|
172 EGpsModuleDoReportOptionsChange, |
|
173 EGpsModuleDoNotReportOptionsChange, |
|
174 }; |
|
175 TGpsOptionsChangeReportMode iOptionsChangeReportMode; |
|
176 |
|
177 /** Module time out. */ |
|
178 TTimeIntervalMicroSeconds iTimeOut; |
|
179 |
|
180 TBool iOneOffTimeOut; |
|
181 |
|
182 /** Module Error Code */ |
|
183 TInt iError; |
|
184 |
|
185 /** Used to alter the time stamp of the posinfo. */ |
|
186 TTimeIntervalMicroSeconds iTimeStampOffset; |
|
187 }; |
|
188 |
|
189 |
|
190 // Retriving data from the test module. |
|
191 class TModuleDataOut |
|
192 { |
|
193 public: |
|
194 |
|
195 enum TModuleRequestType |
|
196 { |
|
197 EModuleResponse, |
|
198 EModuleGpsMode, |
|
199 }; |
|
200 TModuleRequestType iRequestType; |
|
201 |
|
202 enum TModuleResponseType |
|
203 { |
|
204 EModuleResponseOk, |
|
205 EModuleAssDataRequestedOk, |
|
206 EModuleAssDataOk, |
|
207 EModuleAssDataCancelledOk, // may not be possible to verify from within module, hence may remove |
|
208 EModuleStartupOk, |
|
209 EModuleShutdownOk, |
|
210 EModuleErr /** Set if any of the above failed. */ |
|
211 }; |
|
212 |
|
213 TModuleResponseType iResponse; |
|
214 CLbsAdmin::TGpsMode iGpsMode; /** Used to retrive GPS mode from the module. */ |
|
215 }; |
|
216 |
|
217 |
|
218 // Retriving data from the test clock plugin. |
|
219 class TClockPluginDataOut |
|
220 { |
|
221 public: |
|
222 enum TClockPluginResponseType |
|
223 { |
|
224 EClockPluginResponseOk, |
|
225 EClockPluginErr /** Set if any of the above failed. */ |
|
226 }; |
|
227 |
|
228 TClockPluginResponseType iResponse; |
|
229 }; |
|
230 |
|
231 // Count of cancels |
|
232 class TCancelCount |
|
233 { |
|
234 public: |
|
235 TUint iCancelCount; |
|
236 }; |
|
237 |
|
238 // Assistance Data Simple Provider Default values. |
|
239 const TUint KAssistanceData_RefTime_Week = 12; |
|
240 const TUint KAssistanceData_RefTime_Tow1MSec = 567; |
|
241 |
|
242 // Module Info values |
|
243 /* |
|
244 * the A-GPS value are from testproduct\agpsmodule\group\xtestmodule.ini |
|
245 * most the AGPS module module info are the same as the LbsLocDataSourcePlugins\sirf\group\sirfdatasource.ini |
|
246 * except "Module name", "Version", "ClassesSupported", "DataSourceId" |
|
247 */ |
|
248 //Module ID |
|
249 #define APGS_MODINFO_MODULE_ID 271064388 |
|
250 #define NETWORK_MODINFO_MODULE_ID 271064387 |
|
251 |
|
252 //Module name |
|
253 #define AGPS_MODINFO_MOD_NAME _L("TEST_Loc_AGPS_Module") |
|
254 #define NETWORK_MODINFO_MOD_NAME _L("NetLocManager") |
|
255 // |
|
256 #define AGPS_MODINFO_IS_AVAILABLE (ETrue) |
|
257 #define NETWORK_MODINFO_IS_AVAILABLE (ETrue) |
|
258 //Technology type |
|
259 #define AGPS_MODINFO_TECHNOLOGY_TYPE (TPositionModuleInfo::TTechnologyType(TPositionModuleInfo::ETechnologyTerminal | \ |
|
260 TPositionModuleInfo::ETechnologyAssisted)) |
|
261 #define NETWORK_MODINFO_TECHNOLOGY_TYPE (TPositionModuleInfo::TTechnologyType(TPositionModuleInfo::ETechnologyNetwork)) |
|
262 //version |
|
263 #define AGPS_MODINFO_VERSION (TVersion(1,2,3)) |
|
264 #define NETWORK_MODINFO_VERSION (TVersion(0,1,1)) |
|
265 //device location |
|
266 #define AGPS_MODINFO_DEVICE_LOCATION (TPositionModuleInfo::TDeviceLocation(TPositionModuleInfo::EDeviceInternal)) |
|
267 #define NETWORK_MODINFO_DEVICE_LOCATION (TPositionModuleInfo::TDeviceLocation(TPositionModuleInfo::EDeviceExternal)) |
|
268 //capabilities |
|
269 #define AGPS_MODINFO_CAPABILITIES (TPositionModuleInfo::TCapabilities(TPositionModuleInfo::ECapabilityHorizontal | \ |
|
270 TPositionModuleInfo::ECapabilityVertical | \ |
|
271 TPositionModuleInfo::ECapabilitySpeed | \ |
|
272 TPositionModuleInfo::ECapabilityDirection | \ |
|
273 TPositionModuleInfo::ECapabilitySatellite)) |
|
274 #define NETWORK_MODINFO_CAPABILITIES (TPositionModuleInfo::TCapabilities(TPositionModuleInfo::ECapabilityHorizontal| \ |
|
275 TPositionModuleInfo::ECapabilityVertical | \ |
|
276 TPositionModuleInfo::ECapabilitySpeed | \ |
|
277 TPositionModuleInfo::ECapabilityDirection)) |
|
278 //classes supported |
|
279 #define AGPS_MODINFO_CLASSES_SUPPORTED_POSITION_FAMILY (EPositionInfoClass|EPositionGenericInfoClass| \ |
|
280 EPositionCourseInfoClass|EPositionSatelliteInfoClass) |
|
281 #define NETWORK_MODINFO_CLASSES_SUPPORTED_POSITION_FAMILY (EPositionInfoClass|EPositionGenericInfoClass| \ |
|
282 EPositionCourseInfoClass|EPositionSatelliteInfoClass) |
|
283 //time to first fix |
|
284 #define AGPS_MODINFO_TIME_TO_FIRST_FIX (TTimeIntervalMicroSeconds(90000000)) |
|
285 #define NETWORK_MODINFO_TIME_TO_FIRST_FIX (TTimeIntervalMicroSeconds(20000000)) |
|
286 //time to next fix |
|
287 #define AGPS_MODINFO_TIME_TO_NEXT_FIX (TTimeIntervalMicroSeconds(1000000)) |
|
288 #define NETWORK_MODINFO_TIME_TO_NEXT_FIX (TTimeIntervalMicroSeconds(20000000)) |
|
289 //horizontal accuracy |
|
290 #define AGPS_MODINFO_HORIZONTAL_ACCURACY 5.4f |
|
291 #define NETWORK_MODINFO_HORIZONTAL_ACCURACY 100.0f |
|
292 //vertical accuracy |
|
293 #define AGPS_MODINFO_VERTICAL_ACCURACY 5.4f |
|
294 #define NETWORK_MODINFO_VERTICAL_ACCURACY 100.0f |
|
295 //cost indication |
|
296 #define AGPS_MODINFO_COST_INDICATOR (TPositionQuality::ECostPossible) |
|
297 #define NETWORK_MODINFO_COST_INDICATOR (TPositionQuality::ECostCharge) |
|
298 //power consumption |
|
299 #define AGPS_MODINFO_POWER_CONSUMPTION (TPositionQuality::EPowerLow) |
|
300 #define NETWORK_MODINFO_POWER_CONSUMPTION (TPositionQuality::EPowerLow) |
|
301 |
|
302 /** |
|
303 Current LBS system has two positioning module: A-GPS and Network Loc manager |
|
304 This value might be changed if more positioning modules are added in the future |
|
305 */ |
|
306 #define MAX_POSITIONING_MODULES 2 |
|
307 |
|
308 class TCTClientDetails |
|
309 { |
|
310 public: |
|
311 inline TCTClientDetails() |
|
312 : iSessionIdDelay(0), iSessionStepDelay(0), iCancelRequest(EFalse), iSessionIdCancel(0), iSessionStepCancel(0), iNumberOfNPUDs(1), iUpdateOptions(0), iPsyId(0), iExpectedError(0) |
|
313 {} |
|
314 public: |
|
315 TInt iSessionIdDelay; |
|
316 TInt iSessionStepDelay; |
|
317 TBool iCancelRequest; |
|
318 TInt iSessionIdCancel; |
|
319 TInt iSessionStepCancel; |
|
320 TInt iNumberOfNPUDs; |
|
321 TPositionUpdateOptions iUpdateOptions; |
|
322 TInt iPsyId; |
|
323 TInt iExpectedError; |
|
324 }; |
|
325 |
|
326 // Implements a class to contain the utility functions. |
|
327 class T_LbsUtils |
|
328 { |
|
329 public: |
|
330 enum TComparisonAccuracyType |
|
331 { |
|
332 ERoughAccuracy, EExactAccuracy |
|
333 }; |
|
334 |
|
335 IMPORT_C T_LbsUtils(); |
|
336 IMPORT_C ~T_LbsUtils(); |
|
337 |
|
338 IMPORT_C void CreateTestPropertiesL(); |
|
339 // |
|
340 IMPORT_C void GetConfigured_ModuleInfoL(const TDesC& aConfigFileName, const TDesC& aConfigSection, TPositionModuleInfo& aModInfo); |
|
341 |
|
342 IMPORT_C void GetConfigured_PosInfosL(const TDesC& aConfigFileName, const TDesC& aConfigSection, RPointerArray<TAny>& aPosInfoArr); |
|
343 IMPORT_C void GetConfigured_UpdateArrayL(const TDesC& aConfigFileName, const TDesC& aConfigSection, RPointerArray<TLbsModuleUpdateItem>& aUpdateArr); |
|
344 IMPORT_C void GetConfigured_ModuleStatusL(const TDesC& aConfigFileName, const TDesC& aConfigSection, TPositionModuleStatus& aModuleStatus, TBool& aDelayReportingModStatus); |
|
345 IMPORT_C void GetConfigured_ModuleUpdateOptionsL(const TDesC& aConfigFileName, const TDesC& aConfigSection, TPositionUpdateOptions& aUpdateOpts); |
|
346 IMPORT_C void GetConfigured_ClientDetailsL(const TDesC& aConfigFileName, const TDesC& aConfigSection, |
|
347 RArray<TCTClientDetails>& aClientDetailsArray); |
|
348 |
|
349 IMPORT_C void GetExpected_ModuleModes(const TDesC& aConfigFileName, const TDesC& aConfigSection, RPointerArray<TLbsGpsOptions>& aModuleModes); |
|
350 |
|
351 IMPORT_C void NotifyModuleOfConfigChangeL(const TModuleDataIn& aModuleDataIn); |
|
352 IMPORT_C void WaitForModuleToRequestAssistanceDataL(); |
|
353 |
|
354 IMPORT_C TBool Compare_PosInfo(const TPositionInfoBase& aPosInfoSideA, const TPositionInfoBase& aPosInfoSideB); |
|
355 IMPORT_C TBool Compare_PosInfo(const TPositionInfoBase& aPosInfoSideA, const TPositionInfoBase& aPosInfoSideB, TComparisonAccuracyType aCmpAccuracy); |
|
356 |
|
357 IMPORT_C TBool Compare_PosInfoArr(RPointerArray<TAny>& aPosInfoArrSideA, RPointerArray<TAny>& aPosInfoArrSideB); |
|
358 IMPORT_C TBool Compare_PosInfoArr(RPointerArray<TAny>& aPosInfoArrSideA, RPointerArray<TAny>& aPosInfoArrSideB, TComparisonAccuracyType aCmpAccuracy); |
|
359 |
|
360 IMPORT_C void ResetAndDestroy_PosInfoArr(RPointerArray<TAny>& aPosInfoArr); |
|
361 |
|
362 IMPORT_C TPositionModuleId GetNetworkModuleIdL(RPositionServer& aServer); |
|
363 IMPORT_C TPositionModuleId GetAGpsModuleIdL(RPositionServer& aServer); |
|
364 IMPORT_C TPositionModuleId GetBadModuleId(); |
|
365 |
|
366 IMPORT_C TBool Compare_ModuleInfo(TPositionModuleInfo& aModInfoSideA, TPositionModuleInfo& aModInfoSideB); |
|
367 IMPORT_C TBool Compare_PositionQuality(TPositionQuality& aQualitySideA, TPositionQuality& aQualitySideB); |
|
368 IMPORT_C TBool Compare_ModuleStatus(TPositionModuleStatus& aModStatusSideA, TPositionModuleStatus& aModStatusSideB); |
|
369 IMPORT_C TBool Compare_ModuleUpdateOptions(TPositionUpdateOptions& aModUpdateOptsSideA, TPositionUpdateOptions& aModUpdateOptsSideB); |
|
370 IMPORT_C TBool Verify_PositionIsValid(TPositionInfo& aPosInfo); |
|
371 |
|
372 // Assistance data functions |
|
373 // IMPORT_C void CreateSimpleAssistanceData(/*TLbsAssistanceDataGroup aDataMask, RDataReaderRootBase& aGpsRefTimeReader*/); |
|
374 IMPORT_C TBool VerifySimpleAssistanceData(RUEPositioningGpsReferenceTimeReader& aGpsRefTimeReader); |
|
375 IMPORT_C void Create_ModuleInfoL(TPositionModuleId aModuleId, TPositionModuleInfo& aModInfo); |
|
376 |
|
377 |
|
378 IMPORT_C TBool Compare_LogBase(const CLbsLogEvent& aLogEventSideA, const CLbsLogEvent& aLogEventSideB); |
|
379 IMPORT_C TBool Compare_SelfLocateLog(const CLbsSelfLocateLogEvent& aSelfLocateLogSideA, const CLbsSelfLocateLogEvent& aSelfLocateLogB); |
|
380 IMPORT_C TBool Compare_NetworkLocateLog(const CLbsNetworkLocateLogEvent& aNetworkLocateLogSideA, const CLbsNetworkLocateLogEvent& aNetworkLocateLogB); |
|
381 IMPORT_C TBool Compare_ExternalLocateLog(const CLbsExternalLocateLogEvent& aExternalLocateLogSideA, const CLbsExternalLocateLogEvent& aExternalLocateLogSideB); |
|
382 IMPORT_C TBool Compare_TransmitLocationLog(const CLbsTransmitLocationLogEvent& aX3PLogSideA, const CLbsTransmitLocationLogEvent& aX3PLogSideB); |
|
383 IMPORT_C TBool Compare_AssistanceDataLog(const CLbsAssistanceDataLogEvent& aAssistanceDataLogSideA, const CLbsAssistanceDataLogEvent& aAssistanceDataLogSideB); |
|
384 |
|
385 // Needed to compare destinations within TransmitLocation Logs |
|
386 TBool Compare_Destinations(TDesC16& aDestinationFromRealLog, TDesC16& aDestinationFromExpectedLog); |
|
387 |
|
388 |
|
389 IMPORT_C TInt SupportedType(const TUint32& aType, const TInt& aSize); |
|
390 IMPORT_C TInt CopyPositionTypes(TPositionInfoBase& aTo, const TPositionInfoBase& aFrom); |
|
391 |
|
392 IMPORT_C void ResetIntegrationModulesCountOfCancelsL(); |
|
393 IMPORT_C void IncrementIntegrationModulesCountOfCancels(); |
|
394 IMPORT_C TUint IntegrationModulesCountOfCancelsL(); |
|
395 private: |
|
396 TInt GetModIdByTechnology(RPositionServer& aServer, TPositionModuleInfo::TTechnologyType aTechnologyType, TPositionModuleId& aModuleId); |
|
397 // Needed to compare external locate logs. |
|
398 TBool Compare_ExternalRequestPrivacyRequestParams(const TLbsLoggingPrivacyRequestParams& aLogPrivacyRequestParamsSideA, const TLbsLoggingPrivacyRequestParams& aLogPrivacyRequestParamsSideB); |
|
399 TBool Compare_ExternalRequestPrivacyResponseParams(const TLbsLoggingPrivacyResponseParams& aExternalRequestPrivacyResponseSideA, const TLbsLoggingPrivacyResponseParams& aExternalRequestPrivacyResponseSideB); |
|
400 TBool Compare_ExternalRequestInfo(const TLbsExternalRequestInfo& aExternalRequestInfoSideA, const TLbsExternalRequestInfo& aExternalRequestInfoSideB); |
|
401 TBool Compare_ExternalRequestPrivacy(const TLbsNetPosRequestPrivacy& aExternalRequestPrivacySideA, const TLbsNetPosRequestPrivacy& aExternalRequestPrivacySideB); |
|
402 }; |
|
403 |
|
404 |
|
405 /** Possible set of Module options. |
|
406 Held by AGps Hybrid module as bits in a 32 bitmap. |
|
407 */ |
|
408 enum TLbsHybridModuleOptions |
|
409 { |
|
410 EHybridModuleOptions_ClearAll = 0x0000, |
|
411 ELbsHybridModuleOptions_AssistanceDataOn = 0x0001, |
|
412 ELbsHybridModuleOptions_MultiUpdatesOn = 0x0002, |
|
413 ELbsHybridModuleOptions_DisableReqAssistData = 0x0004, |
|
414 ELbsHybridModuleOptions_DynamicAssistanceData = 0x008, //Assistance Data delivery variant used in SUPL tests |
|
415 ELbsHybridModuleOptions_SetAll = 0x000F |
|
416 }; |
|
417 |
|
418 #endif //__T_LBS_UTILS_H__ |