this.speedBytes being the total number of transferred bytes, converted to bits after *8, I was wondering if the total shouldn't be divided by 1000 rather than 1024 in order to get a a result in kbits/s, that is :
var up_kps = (((this.speedBytes * 8) / (this.up_dur / 1000)) / 1000).toFixed(0);
var down_kps = (((this.speedBytes * 8) / (this.down_dur / 1000)) / 1000).toFixed(0);
Am I missing something here ? Thanks !