From: Michal Sojka Date: Wed, 11 Feb 2009 08:15:02 +0000 (+0100) Subject: Bitrate increased to 54 Mbps, lowered mimimum deadline. X-Git-Url: http://rtime.felk.cvut.cz/gitweb/frescor/fwp.git/commitdiff_plain/3e231ec00a51f8ead13b2d717275ae33a7f3b40a Bitrate increased to 54 Mbps, lowered mimimum deadline. --- diff --git a/fwp/mngr/fwp_admctrl.c b/fwp/mngr/fwp_admctrl.c index 575a8b4..6ff6a32 100644 --- a/fwp/mngr/fwp_admctrl.c +++ b/fwp/mngr/fwp_admctrl.c @@ -145,9 +145,9 @@ int fwp_admctrl_utilization(struct fres_sa_scenario *scenario, void *priv, { int utilization = 0; - const int rate = 22*1000*1000; - const bool erp_ofdm = false; - const bool short_preamble = false; + const int rate = 54*1000*1000; + const bool erp_ofdm = true; + const bool short_preamble = true; struct fres_sa_contract *c, *c_new = NULL; long int period_usec; fres_block_basic *basic; @@ -191,10 +191,11 @@ int fwp_admctrl_utilization(struct fres_sa_scenario *scenario, void *priv, tmp_usec = frame_duration(ACK_FRAME_SIZE, rate, erp_ofdm, short_preamble) + ASIFSTIME_USEC; duration_usec += fragments * tmp_usec; + //printf("duration: %ld ms\n", duration_usec/1000); /* TODO: If STA-to-STA, multiply it by two. Note that * AP may use different values for backoff. */ - duration_usec *= 2; /* For demo, we have always STA-to-STA */ + //duration_usec *= 2; /* For demo, we have always STA-to-STA */ basic = fres_contract_get_basic(c->contract); period_usec = fosa_rel_time_to_msec(basic->period)*1000; @@ -214,14 +215,13 @@ int fwp_admctrl_utilization(struct fres_sa_scenario *scenario, void *priv, if (utilization >= 10000 * 96/100) { goto not_schedulable; } - scenario->utilization = utilization/100; /* For GUI */ basic = fres_contract_get_basic(c_new->contract); /*int d = c->deadline_usec;*/ - long int d = fosa_rel_time_to_msec(basic->period)*1000; + long int d = fosa_rel_time_to_msec(basic->period)*1000; if (d <= 0) d = 100*1000*1000; - if (d < 50000) { + if (d < 30000) { goto not_schedulable; };