Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion source/db/wifi_db.c
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ static int init_radio_config_default(int radio_index, wifi_radio_operationParam_
wifi_radio_feature_param_t Fcfg;
memset(&Fcfg,0,sizeof(Fcfg));
memset(&cfg,0,sizeof(cfg));
ULONG curr_txpower = 0;

wifi_radio_capabilities_t radio_capab = g_wifidb->hal_cap.wifi_prop.radiocap[radio_index];

Expand Down Expand Up @@ -188,7 +189,13 @@ static int init_radio_config_default(int radio_index, wifi_radio_operationParam_
cfg.beaconInterval = 100;
}
cfg.fragmentationThreshold = 2346;
cfg.transmitPower = 100;

if (wifi_hal_getRadioTransmitPower(radio_index, &curr_txpower) != RETURN_OK) {
wifi_util_dbg_print(WIFI_DB,"%s:%d: Failed to fetch TX power for radio_index=%d\n",
__func__, __LINE__, radio_index);
curr_txpower = 0;
}
cfg.transmitPower = curr_txpower;
cfg.rtsThreshold = 2347;
cfg.guardInterval = wifi_guard_interval_auto;
cfg.ctsProtection = false;
Expand Down
2 changes: 2 additions & 0 deletions source/webconfig/wifi_easymesh_translator.c
Original file line number Diff line number Diff line change
Expand Up @@ -364,6 +364,7 @@ webconfig_error_t translate_radio_object_to_easymesh_for_radio(webconfig_subdoc_
em_op_class_info->id.type = em_op_class_type_capability;
em_op_class_info->id.op_class = oper_param->operatingClasses[i].opClass;
em_op_class_info->op_class = oper_param->operatingClasses[i].opClass;
em_op_class_info->tx_power = oper_param->transmitPower;
em_op_class_info->max_tx_power = oper_param->operatingClasses[i].maxTxPower;
em_op_class_info->num_channels = oper_param->operatingClasses[i].numberOfNonOperChan;
for(int k = 0; k < oper_param->operatingClasses[i].numberOfNonOperChan; k++) {
Expand All @@ -380,6 +381,7 @@ webconfig_error_t translate_radio_object_to_easymesh_for_radio(webconfig_subdoc_
em_op_class_info->id.op_class = oper_param->operatingClass;
em_op_class_info->op_class = oper_param->operatingClass;
em_op_class_info->channel = oper_param->channel;
em_op_class_info->tx_power = oper_param->transmitPower;
no_of_opclass++;
proto->set_num_op_class(proto->data_model,no_of_opclass);
}
Expand Down
Loading