Re: [PATCH] command-nas: fix cmd_nas_get_cell_location_info_cb
Hello Cezary, I think for that particular problem it wuld suffice to wrap the three cell-objects in an array called cells. I drafted a commit for this, but am currently sitting in a train and can only test it in a few hours. Looking at the surrounding code there appear to be more for-loops, that might produce similar problems. Without breaking existing codes, it might be worthwile to ask the original author about his intention on this. Until later Aiyion On 3/6/22 18:37, Cezary Jackiewicz wrote: Dnia 2022-03-06, o godz. 18:25:57 Jan-Niklas Burfeind napisał(a): Correct order of rsrp and rsrq parameters for print_lte_info. Signed-off-by: Jan-Niklas Burfeind Hi, BTW, syntax is invalid. Output is not valid json format. Could you also proper format output? Ex: missing keys after serving_cell_id: # uqmi -d /dev/cdc-wdm0 --get-cell-location-info { "intrafrequency_lte_info": { "tracking_area_code": 11041, "global_cell_id": 2742796, "channel": 3526, "band": 8, "frequency": 900, "duplex": "FDD", "serving_cell_id": 49, { "physical_cell_id": 49, "rsrq": -70.80, "rsrp": -10.40, "rssi": -47.20 }, { "physical_cell_id": 10, "rsrq": -78.50, "rsrp": -17.90, "rssi": -50.90 }, { "physical_cell_id": 50, "rsrq": -78.40, "rsrp": -18.50, "rssi": -50.90 } } } ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Re: [PATCH] command-nas: fix cmd_nas_get_cell_location_info_cb
Dnia 2022-03-06, o godz. 18:25:57 Jan-Niklas Burfeind napisał(a): > Correct order of rsrp and rsrq parameters for print_lte_info. > > Signed-off-by: Jan-Niklas Burfeind Hi, BTW, syntax is invalid. Output is not valid json format. Could you also proper format output? Ex: missing keys after serving_cell_id: # uqmi -d /dev/cdc-wdm0 --get-cell-location-info { "intrafrequency_lte_info": { "tracking_area_code": 11041, "global_cell_id": 2742796, "channel": 3526, "band": 8, "frequency": 900, "duplex": "FDD", "serving_cell_id": 49, { "physical_cell_id": 49, "rsrq": -70.80, "rsrp": -10.40, "rssi": -47.20 }, { "physical_cell_id": 10, "rsrq": -78.50, "rsrp": -17.90, "rssi": -50.90 }, { "physical_cell_id": 50, "rsrq": -78.40, "rsrp": -18.50, "rssi": -50.90 } } } -- Pozdrawiam, Cezary Jackiewicz ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel
[PATCH] command-nas: fix cmd_nas_get_cell_location_info_cb
Correct order of rsrp and rsrq parameters for print_lte_info. Signed-off-by: Jan-Niklas Burfeind --- This was introduced in d647f8d89f68 uqmi: add more diagnostics commands Currently --get-cell-location-info prints the rsrq and rsrp values swapped. I ignored the checkpatch.pl warning for line lengths, as the long line is already in the codebase and only got swapped in their order. commands-nas.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/commands-nas.c b/commands-nas.c index 01ca3b8..ff7a6c3 100644 --- a/commands-nas.c +++ b/commands-nas.c @@ -772,8 +772,8 @@ cmd_nas_get_cell_location_info_cb(struct qmi_dev *qmi, struct qmi_request *req, for (i = 0; i < res.data.intrafrequency_lte_info_v2.cell_n; i++) { cell = blobmsg_open_table(, NULL); print_lte_info(res.data.intrafrequency_lte_info_v2.cell[i].physical_cell_id, - res.data.intrafrequency_lte_info_v2.cell[i].rsrq, res.data.intrafrequency_lte_info_v2.cell[i].rsrp, + res.data.intrafrequency_lte_info_v2.cell[i].rsrq, res.data.intrafrequency_lte_info_v2.cell[i].rssi); if (res.data.intrafrequency_lte_info_v2.ue_in_idle) blobmsg_add_u32(, "cell_selection_rx_level", @@ -798,8 +798,8 @@ cmd_nas_get_cell_location_info_cb(struct qmi_dev *qmi, struct qmi_request *req, for (j = 0; j < res.data.interfrequency_lte_info.frequency[i].cell_n; j++) { cell = blobmsg_open_table(, NULL); print_lte_info(res.data.interfrequency_lte_info.frequency[i].cell[j].physical_cell_id, - res.data.interfrequency_lte_info.frequency[i].cell[j].rsrq, res.data.interfrequency_lte_info.frequency[i].cell[j].rsrp, + res.data.interfrequency_lte_info.frequency[i].cell[j].rsrq, res.data.interfrequency_lte_info.frequency[i].cell[j].rssi); if (res.data.interfrequency_lte_info.ue_in_idle) blobmsg_add_u32(, "cell_selection_rx_level", -- 2.35.1 ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/mailman/listinfo/openwrt-devel