Use --imscope flag to enable/disable imscope
This commit is contained in:
@@ -734,18 +734,19 @@ int main( int argc, char **argv ) {
|
||||
printf("ALL RUs ready - init gNBs\n");
|
||||
|
||||
for (int idx=0;idx<RC.nb_nr_L1_inst;idx++) RC.gNB[idx]->if_inst->sl_ahead = sl_ahead;
|
||||
if (IS_SOFTMODEM_DOSCOPE) {
|
||||
if (IS_SOFTMODEM_DOSCOPE || IS_SOFTMODEM_IMSCOPE_ENABLED) {
|
||||
sleep(1);
|
||||
scopeParms_t p;
|
||||
p.argc = &argc;
|
||||
p.argv = argv;
|
||||
p.gNB = RC.gNB[0];
|
||||
p.ru = RC.ru[0];
|
||||
#ifndef ENABLE_IMSCOPE
|
||||
load_softscope("nr", &p);
|
||||
#else
|
||||
load_softscope("im", &p);
|
||||
#endif
|
||||
if (IS_SOFTMODEM_DOSCOPE) {
|
||||
load_softscope("nr", &p);
|
||||
}
|
||||
if (IS_SOFTMODEM_IMSCOPE_ENABLED) {
|
||||
load_softscope("im", &p);
|
||||
}
|
||||
}
|
||||
|
||||
if (NFAPI_MODE != NFAPI_MODE_PNF && NFAPI_MODE != NFAPI_MODE_VNF && NFAPI_MODE != NFAPI_MODE_AERIAL) {
|
||||
|
||||
@@ -522,11 +522,10 @@ int main(int argc, char **argv)
|
||||
lock_memory_to_ram();
|
||||
|
||||
if (IS_SOFTMODEM_DOSCOPE) {
|
||||
#ifndef ENABLE_IMSCOPE
|
||||
load_softscope("nr", PHY_vars_UE_g[0][0]);
|
||||
#else
|
||||
}
|
||||
if (IS_SOFTMODEM_IMSCOPE_ENABLED) {
|
||||
load_softscope("im", PHY_vars_UE_g[0][0]);
|
||||
#endif
|
||||
}
|
||||
|
||||
for (int inst = 0; inst < NB_UE_INST; inst++) {
|
||||
|
||||
@@ -99,6 +99,7 @@ void get_common_options(configmodule_interface_t *cfg, uint32_t execmask)
|
||||
uint32_t start_websrv = 0;
|
||||
uint32_t noS1 = 0, nonbiot = 0;
|
||||
uint32_t rfsim = 0, do_forms = 0;
|
||||
uint32_t enable_imscope = 0;
|
||||
int nfapi_index = 0;
|
||||
char *logmem_filename = NULL;
|
||||
check_execmask(execmask);
|
||||
@@ -158,6 +159,10 @@ void get_common_options(configmodule_interface_t *cfg, uint32_t execmask)
|
||||
set_softmodem_optmask(SOFTMODEM_DOSCOPE_BIT);
|
||||
}
|
||||
|
||||
if (enable_imscope) {
|
||||
set_softmodem_optmask(SOFTMODEM_IMSCOPE_BIT);
|
||||
}
|
||||
|
||||
if (start_websrv) {
|
||||
load_module_shlib("websrv", NULL, 0, NULL);
|
||||
}
|
||||
|
||||
@@ -76,6 +76,7 @@ extern "C"
|
||||
#define CONFIG_HLP_256QAM "Use the 256 QAM mcs table for PDSCH\n"
|
||||
#define CONFIG_HLP_CHESTFREQ "Set channel estimation type in frequency domain. 0-Linear interpolation (default). 1-PRB based averaging of channel estimates in frequency. \n"
|
||||
#define CONFIG_HLP_CHESTTIME "Set channel estimation type in time domain. 0-Symbols take estimates of the last preceding DMRS symbol (default). 1-Symbol based averaging of channel estimates in time. \n"
|
||||
#define CONFIG_HLP_IMSCOPE "Enable phy scope based on imgui and implot"
|
||||
|
||||
#define CONFIG_HLP_NONSTOP "Go back to frame sync mode after 100 consecutive PBCH failures\n"
|
||||
//#define CONFIG_HLP_NUMUES "Set the number of UEs for the emulation"
|
||||
@@ -188,6 +189,7 @@ extern int usrp_tx_thread;
|
||||
{"sync-ref", CONFIG_HLP_SYNC_REF, 0, .uptr=&SYNC_REF, .defintval=0, TYPE_UINT, 0}, \
|
||||
{"A" , CONFIG_HLP_TADV, 0, .iptr=&softmodem_params.command_line_sample_advance,.defintval=0, TYPE_INT, 0}, \
|
||||
{"E" , CONFIG_HLP_TQFS, PARAMFLAG_BOOL, .iptr=&softmodem_params.threequarter_fs, .defintval=0, TYPE_INT, 0}, \
|
||||
{"imscope" , CONFIG_HLP_IMSCOPE, PARAMFLAG_BOOL, .uptr=&enable_imscope, .defintval=0, TYPE_UINT, 0}, \
|
||||
}
|
||||
// clang-format on
|
||||
|
||||
@@ -235,6 +237,7 @@ extern int usrp_tx_thread;
|
||||
{ .s5 = { NULL } }, \
|
||||
{ .s5 = { NULL } }, \
|
||||
{ .s5 = { NULL } }, \
|
||||
{ .s5 = { NULL } }, \
|
||||
}
|
||||
// clang-format on
|
||||
|
||||
@@ -288,6 +291,7 @@ extern int usrp_tx_thread;
|
||||
#define SOFTMODEM_4GUE_BIT (1<<22)
|
||||
#define SOFTMODEM_5GUE_BIT (1<<23)
|
||||
#define SOFTMODEM_NOSTATS_BIT (1<<24)
|
||||
#define SOFTMODEM_IMSCOPE_BIT (1<<25)
|
||||
|
||||
#define SOFTMODEM_FUNC_BITS (SOFTMODEM_ENB_BIT | SOFTMODEM_GNB_BIT | SOFTMODEM_5GUE_BIT | SOFTMODEM_4GUE_BIT)
|
||||
#define MAPPING_SOFTMODEM_FUNCTIONS {{"enb",SOFTMODEM_ENB_BIT},{"gnb",SOFTMODEM_GNB_BIT},{"4Gue",SOFTMODEM_4GUE_BIT},{"5Gue",SOFTMODEM_5GUE_BIT}}
|
||||
@@ -307,6 +311,7 @@ extern int usrp_tx_thread;
|
||||
#define IS_SOFTMODEM_4GUE_BIT ( get_softmodem_optmask() & SOFTMODEM_4GUE_BIT)
|
||||
#define IS_SOFTMODEM_5GUE_BIT ( get_softmodem_optmask() & SOFTMODEM_5GUE_BIT)
|
||||
#define IS_SOFTMODEM_NOSTATS_BIT ( get_softmodem_optmask() & SOFTMODEM_NOSTATS_BIT)
|
||||
#define IS_SOFTMODEM_IMSCOPE_ENABLED ( get_softmodem_optmask() & SOFTMODEM_IMSCOPE_BIT)
|
||||
|
||||
typedef struct {
|
||||
uint64_t optmask;
|
||||
|
||||
@@ -54,7 +54,7 @@ Add `-DENABLE_IMSCOPE=ON` to your `cmake` command. Build target `imscope`
|
||||
|
||||
## Running
|
||||
|
||||
Run with `-d` flag
|
||||
Run with `--imscope` flag
|
||||
|
||||
## Usage notes
|
||||
|
||||
|
||||
Reference in New Issue
Block a user