diff pathloss/main.c @ 66:599fac1b882d

pathloss: implement FSL
author Mychaela Falconia <falcon@freecalypso.org>
date Fri, 25 Oct 2024 08:12:28 +0000
parents b3f04535eb14
children 0cfea66a15f3
line wrap: on
line diff
--- a/pathloss/main.c	Fri Oct 25 07:42:53 2024 +0000
+++ b/pathloss/main.c	Fri Oct 25 08:12:28 2024 +0000
@@ -8,6 +8,7 @@
 #include <stdlib.h>
 #include <string.h>
 #include <strings.h>
+#include "range_func.h"
 
 #define	MAX_FIELDS	5
 static char linebuf[256], *fields[MAX_FIELDS];
@@ -269,6 +270,10 @@
 	path_loss_ul = ms_power + bts_ant_gain - bts_rxs - misc_loss;
 	printf("Path loss budget: %.2f dB DL, %.2f dB UL\n", path_loss_dl,
 		path_loss_ul);
-	/* distance calculations will go here */
+	/* distance per various models */
+	printf("FSL: %.2f m DL, %.2f m UL\n",
+		rf_range_freespace(freq_dl, path_loss_dl),
+		rf_range_freespace(freq_ul, path_loss_ul));
+	/* Egli and Hata coming next */
 	exit(0);
 }