Open Source Telephony
 help / color / mirror / Atom feed
From: JongSeok Won <wjs890204@gmail.com>
To: ofono@ofono.org
Subject: [PATCH 1/2] netmon: support cell type LTE
Date: Mon, 20 Jul 2020 17:40:52 +0900	[thread overview]
Message-ID: <20200720084052.8617-1-wjs890204@gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 1746 bytes --]

---
 include/netmon.h |  3 +++
 src/netmon.c     | 24 +++++++++++++++++++++++-
 2 files changed, 26 insertions(+), 1 deletion(-)

diff --git a/include/netmon.h b/include/netmon.h
index a99d6ca9..53f9d393 100644
--- a/include/netmon.h
+++ b/include/netmon.h
@@ -72,6 +72,9 @@ enum ofono_netmon_info {
 	OFONO_NETMON_INFO_EARFCN, /* int */
 	OFONO_NETMON_INFO_EBAND, /* int */
 	OFONO_NETMON_INFO_CQI, /* int */
+	OFONO_NETMON_INFO_PCI, /* int */
+	OFONO_NETMON_INFO_TAC, /* int */
+	OFONO_NETMON_INFO_SNR, /* int */
 	OFONO_NETMON_INFO_INVALID,
 };
 
diff --git a/src/netmon.c b/src/netmon.c
index 9eacb3ca..320c8425 100644
--- a/src/netmon.c
+++ b/src/netmon.c
@@ -138,7 +138,7 @@ static void netmon_cell_info_dict_append(DBusMessageIter *dict,
 			intval = va_arg(*arglist, int);
 
 			CELL_INFO_DICT_APPEND(dict, "TimingAdvance",
-					intval, uint8_t, DBUS_TYPE_BYTE);
+					intval, uint32_t, DBUS_TYPE_UINT32);
 			break;
 
 		case OFONO_NETMON_INFO_PSC:
@@ -213,6 +213,28 @@ static void netmon_cell_info_dict_append(DBusMessageIter *dict,
 					intval, uint8_t, DBUS_TYPE_BYTE);
 			break;
 
+		case OFONO_NETMON_INFO_PCI:
+			intval = va_arg(*arglist, int);
+
+			CELL_INFO_DICT_APPEND(dict, "PhysicalCellId",
+					intval, uint16_t, DBUS_TYPE_UINT16);
+			break;
+
+		case OFONO_NETMON_INFO_TAC:
+			intval = va_arg(*arglist, int);
+
+			CELL_INFO_DICT_APPEND(dict, "TrackingAreaCode",
+					intval, uint16_t, DBUS_TYPE_UINT16);
+			break;
+
+		case OFONO_NETMON_INFO_SNR:
+			intval = va_arg(*arglist, int);
+
+			ofono_dbus_dict_append(dict, "SingalToNoiseRatio",
+					DBUS_TYPE_INT32, &intval);
+
+			break;
+
 		case OFONO_NETMON_INFO_INVALID:
 			break;
 		}
-- 
2.17.1

             reply	other threads:[~2020-07-20  8:40 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-20  8:40 JongSeok Won [this message]
2020-07-21 13:55 ` [PATCH 1/2] netmon: support cell type LTE Denis Kenzior
2020-07-27  2:30   ` JongSeok Won
2020-07-28 11:53     ` cathereenblai.rmaine0421

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200720084052.8617-1-wjs890204@gmail.com \
    --to=wjs890204@gmail.com \
    --cc=ofono@ofono.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox