common_library: gettid is multiple declaration in cl_error
[staging/basesystem.git] / video_in_hal / vehicleservice / positioning / client / include / Naviinfo_API.h
1 /*
2  * @copyright Copyright (c) 2016-2020 TOYOTA MOTOR CORPORATION.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 /******************************************************************************
18 @file       Naviinfo_API.h
19 @detail     Naviinfo_API external header file<BR>
20             Naviinfo_API External Public Header
21 ******************************************************************************/
22 #ifndef POSITIONING_CLIENT_INCLUDE_NAVIINFO_API_H_
23 #define POSITIONING_CLIENT_INCLUDE_NAVIINFO_API_H_
24
25 /*****************************************************************************
26  *                                 Include                                   *
27  *****************************************************************************/
28 #include <vehicle_service/positioning_base_library.h>
29 #include "Sensor_Common_API.h"
30 #include "Vehicle_API.h"
31 #include "Sensor_API.h"
32 #include <vehicle_service/POS_gps_API.h>
33
34 /*****************************************************************************
35  *                                   Define                                  *
36  *****************************************************************************/
37 /* Command ID Definition */
38 #define CID_NAVIINFO_DELIVER                   (0x0205)    /* Navigation information setting CID  */
39 #define CID_NAVIINFO_SPEED_DELIVER             (0x0206)    /* Vehicle speed setting CID    */
40 #define CID_NAVIINFO_SETGPSTIME                (0x0207)    /* GPS time delivery CID  */
41
42 /* Positioning Level/GPS Information Positioning Status Information Definition */
43 #define NAVIINFO_DIAG_GPS_FIX_STS_NON          (0)         /* Not fix      */
44 #define NAVIINFO_DIAG_GPS_FIX_STS_2D           (1)         /* 2D positioning      */
45 #define NAVIINFO_DIAG_GPS_FIX_STS_3D           (2)         /* 3D positioning      */
46
47 /* Reception status definition */
48 #define NAVIINFO_DIAG_GPS_RCV_STS_NOTUSE       (0)         /* Not used      */
49 #define NAVIINFO_DIAG_GPS_RCV_STS_SEARCHING    (1)         /* Searching      */
50 #define NAVIINFO_DIAG_GPS_RCV_STS_TRACHING     (2)         /* Tracking in progress  */
51 #define NAVIINFO_DIAG_GPS_RCV_STS_NOTUSEFIX    (3)         /* Positioning not used    */
52 #define NAVIINFO_DIAG_GPS_RCV_STS_USEFIX       (4)         /* Positioning use      */
53
54 /* Date and Time Status Definition */
55 #define NAVIINFO_NAVI_GPS_TD_STS_NOTFIX        (0)
56 /* Time not calibrated after receiver reset  */
57 #define NAVIINFO_NAVI_GPS_TD_STS_RTCBACKUP     (1)
58 /* Time output by RTC backup(Time Calibration Result)*/
59 #define NAVIINFO_NAVI_GPS_TD_STS_FIX           (2)         /* Time calibration completed    */
60
61 /* ++ Porting from PastModel002 enabled APIs */
62 #define CID_VEHICLEIF_GET_VEHICLE_DATA         0x0102      /* Vehicle sensor information acquisition CID    */
63 #define CID_VEHICLEIF_COMM_WATCH               0x0103      /* Vehicle Sensor Information Disruption Monitoring CID  */
64 #define CID_SENSORIF__CWORD82__REQUEST               0x0800      /* Vehicle sensor information setting CID    */
65
66 #define VEHICLE_RET_ERROR_OUTOF_MEMORY         (-8)        /* Shared memory allocation failure  */
67 #define VEHICLE_RET_ERROR_INVALID              (-10)       /* CANID undetermined    */
68
69 /* -- Porting from PastModel002 enabled APIs */
70
71 /*****************************************************************************
72  *                               Typedef                                     *
73  *****************************************************************************/
74
75 /*****************************************************************************
76  *                                 Struct                                    *
77  *****************************************************************************/
78 /*****************************************************************************
79  * TAG     : NAVIINFO_DELIVER_MSG
80  * ABSTRACT   : Navigation information delivery message structure
81  * NOTE     :
82  *****************************************************************************/
83 typedef struct {
84     T_APIMSG_MSGBUF_HEADER       hdr;                      /* Message header    */
85     NAVIINFO_ALL                 dat;                      /* Message data section    */
86 } NAVIINFO_DELIVER_MSG;
87
88 /*****************************************************************************
89  * TAG     : NAVIINFO_SPEED_DELIVER_MSG
90  * ABSTRACT   : Navigation Information (Vehicle Speed) Delivery Message Structure
91  * NOTE     :
92  *****************************************************************************/
93 typedef struct {
94     T_APIMSG_MSGBUF_HEADER       hdr;                      /* Message header    */
95     u_int16                      navi_speed;               /* Vehicle speed information          */
96     u_int8                       reserve[2];               /* reserve          */
97 } NAVIINFO_SPEED_DELIVER_MSG;
98
99 /*****************************************************************************
100 *                           Function prototype                                  *
101 *****************************************************************************/
102 #ifdef __cplusplus
103 extern "C" {
104 #endif
105 extern int32 VehicleSetVehicleData(PNO pid, VEHICLE_MSG_SEND_DAT *p_data);
106 #ifdef __cplusplus
107 }
108 #endif
109
110 #endif  // POSITIONING_CLIENT_INCLUDE_NAVIINFO_API_H_