masayuki2009 commented on code in PR #1454:
URL: https://github.com/apache/nuttx-apps/pull/1454#discussion_r1045718067


##########
netutils/iperf/iperf.c:
##########
@@ -267,9 +267,10 @@ static void iperf_report_task(FAR void *arg)
       printf("%7.2lf-%7.2lf sec %10ju Bytes %7.2f Mbits/sec\n",
              ts_diff(&last, &start),
              ts_diff(&now, &start),
-             now_len,
-             (((double)(now_len - last_len) * 8) /
-             ts_diff(&now, &last) / 1e6));
+             now_len -last_len,
+             (double)((now_len - last_len) * 8 / 1000000) /

Review Comment:
   The result would be like this:
   
   ```
    mode=tcp-server sip=10.0.2.15:5001,dip=0.0.0.0:5001, interval=1, time=0
   accept: 10.0.2.2,57866
   
              Interval         Transfer         Bandwidth
   
      0.00-   1.01 sec   38229664 Bytes     inf Mbits/sec
      1.01-   2.02 sec   40237600 Bytes  318.71 Mbits/sec
      2.02-   3.03 sec   38111840 Bytes     inf Mbits/sec
      3.03-   4.04 sec   37212480 Bytes     inf Mbits/sec
      4.04-   5.05 sec   37773120 Bytes  299.19 Mbits/sec
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to