Add NR network type on neighboring cell info 84/230484/1 accepted/tizen/unified/20200423.054531 submit/tizen/20200422.071205
authorsinikang <sinikang@samsung.com>
Fri, 10 Apr 2020 05:56:58 +0000 (14:56 +0900)
committersinikang <sinikang@samsung.com>
Fri, 10 Apr 2020 05:56:58 +0000 (14:56 +0900)
Change-Id: I844973bc465af5e3720a9e429ef52afa17ac47d4
Signed-off-by: sinikang <sinikang@samsung.com>
include/TelNetwork.h
packaging/libtapi.spec
src/tapi_network.c

index c350cc45d7d754ad30b38fa9e48cd85890478f77..57ed313e2ad0d72ada20416b036b35413122b78c 100644 (file)
@@ -142,6 +142,12 @@ extern "C"
  */
 #define TAPI_NETWORK_LTE_NEIGHBORING_CELL_LIST_MAX 24
 
+/**
+ * @brief Definition for the maximum New Radio neighboring cell list.
+ * @since_tizen 6.0
+ */
+#define TAPI_NETWORK_NR_NEIGHBORING_CELL_LIST_MAX 24
+
 /* This value defines the network mode */
 /**
  * @brief Definition for the "set network mode to automatic" value.
@@ -664,6 +670,19 @@ typedef struct {
        int base_station_longitude; /**< Longitude of the current base station */
 } TelNetworkCdmaCellInfo_t;
 
+/**
+ * @brief The structure type for New Radio cell info.
+ * @since_tizen 6.0
+ */
+typedef struct {
+       int cell_id;    /**< Cell ID (@c -1 indicates that cell ID information is not present) */
+       int lac;        /**< Location area code (this field is ignored when @a cell_id is not present) */
+       int pcid;       /**< Physical cell id */
+       int nrarfcn;    /**< New Radio Absolute Radio Frequency Channel Number */
+       int tac;        /**< Tracking area code */
+       int rssi;       /**< RSSI in dBm(signed) */
+} TelNetworkNrCellInfo_t;
+
 /**
  * @brief The structure type for serving cell info.
  * @since_tizen 2.3
@@ -677,6 +696,7 @@ typedef struct {
                TelNetworkUmtsCellInfo_t umts;  /**< UMTS cell info */
                TelNetworkLteCellInfo_t lte;    /**< LTE cell info */
                TelNetworkCdmaCellInfo_t cdma;  /**< CDMA cell info */
+               TelNetworkNrCellInfo_t nr;      /**< New Radio cell info */
        } cell;
 } TelNetworkServingCellInfo_t;
 
@@ -693,6 +713,8 @@ typedef struct {
        TelNetworkUmtsCellInfo_t umts_list[TAPI_NETWORK_UMTS_NEIGHBORING_CELL_LIST_MAX];/**< UMTS cell info list */
        int lte_list_count;/**<LTE cell info list count*/
        TelNetworkLteCellInfo_t lte_list[TAPI_NETWORK_LTE_NEIGHBORING_CELL_LIST_MAX];/**<LTE cell info list*/
+       int nr_list_count;/**<New Radio cell info list count*/
+       TelNetworkNrCellInfo_t nr_list[TAPI_NETWORK_NR_NEIGHBORING_CELL_LIST_MAX];/**<New Radio cell info list*/
 } TelNetworkNeighboringCellInfo_t;
 
 /**
index b1022148dddf9cb7e0b14b5fb89e02f67ae5ddb4..25f519ab99085451fbdbeccc50ea8e8f06efac06 100644 (file)
@@ -1,6 +1,6 @@
 %define major 0
 %define minor 8
-%define patchlevel 38
+%define patchlevel 39
 
 Name:           libtapi
 Version:        %{major}.%{minor}.%{patchlevel}
index 68a122bb20b46902853da41db1fdaae92f81d888..7b827f6e8d3354ef92fdda1f19be121eb691a710 100644 (file)
@@ -800,6 +800,13 @@ static void on_response_get_neighboring_cell_info(GObject *source_object,
                                list.serving.cell.lte.earfcn = v2;
                                list.serving.cell.lte.tac = v3;
                                list.serving.cell.lte.rssi = v4;
+                       } else if (!g_strcmp0(key, "n_serving")) {
+                               g_variant_get(value, "(iiiii)", &v0, &v1, &v2, &v3, &v4);
+                               list.serving.cell.nr.cell_id = v0;
+                               list.serving.cell.nr.lac = v1;
+                               list.serving.cell.nr.nrarfcn= v2;
+                               list.serving.cell.nr.tac = v3;
+                               list.serving.cell.nr.rssi = v4;
                        } else if (!g_strcmp0(key, "c_serving")) {
                                g_variant_get(value, "(uuuuii)", &v0, &v1, &v2, &v3, &v4, &v5);
                                list.serving.cell.cdma.system_id = v0;