amigos, sou novo aki, consegui um codigo fonte de um velocimetro para medir a velocidade da internet, porem trb com conexões acima de 2 megas, alguém saberia onde eu devo alterar pois já tentei em alguns pontos mas da erro. segue abaixo o codigo fonte. obrigado. function repete() { unloadMovie("imagem"); ponteiro._rotation = 232; calcular = 0; estatisticas.taxa.text = "0 kbps"; estatisticas.porcentagem.text = "0%"; estatisticas.transferidos.text = "0 KB"; estatisticas.restantes.text = "Calculando..."; estatisticas.barra.gotoAndStop(1); estatisticas.gotoAndStop(1); txtTotal.text = "Aguarde..."; txtTotalB.text = "Aguarde..."; _root.ponteiro.parar(); clearInterval(mg); antes = new Date(); if (velocidade_real <= 283) { loadMovie("velo_load.swf?" + strarr[random(strarr.length)] + "=" + random(1.000000E+011), "imagem"); arquivo = 1; } else if (velocidade_real <= 564) { loadMovie("velo_load_300.swf?" + strarr[random(strarr.length)] + "=" + random(1.000000E+011), "imagem"); arquivo = 2; } else if (velocidade_real <= 768) { loadMovie("velo_load_600.swf?" + strarr[random(strarr.length)] + "=" + random(1.000000E+011), "imagem"); arquivo = 3; } else { loadMovie("velo_load_1200.swf?" + strarr[random(strarr.length)] + "=" + random(1.000000E+011), "imagem"); arquivo = 4; } // end else if velocidade = 0; somar = 10; x = 0; vez = 0; total_bites = 0; } // End of the function function _porc(ftotal, fcarregados) { ++calcular; if (calcular == 12) { agora = new Date(); fim = dateDiff("ms", antes, agora) / 1000; if (parseFloat(fcarregados / fim / 1000) != 0) { estatisticas.taxa.text = formatNumber(fcarregados / fim / 1000, 2) + " KBps"; } // end if calcular = 0; } // end if estatisticas.porcentagem.text = parseInt(fcarregados / ftotal * 100) + "%"; estatisticas.transferidos.text = FormatNumber(fcarregados / 1000, 2) + " KB"; estatisticas.restantes.text = FormatNumber((ftotal - fcarregados) / 1000, 2) + " KB"; estatisticas.barra.gotoAndStop(parseInt(fcarregados / ftotal * 100)); } // End of the function function _girar(total) { agora = new Date(); fim = dateDiff("ms", antes, agora) / 1000; tempo_total = fim; ponteiro._rotation = 232; estatisticas_est_tem = FormatNumber(total / 1000, 2) + " KB"; estatisticas_est_seg = FormatNumber(fim, 3) + " segundos"; total = total * 8 / fim / 1000; total_bites = total; if (parseFloat(FormatNumber(total, 2)) >= 1000) { txtTotal_text = FormatNumber(total / 1000, 2) + " Mbps"; estatisticas_est_bt = FormatNumber(total / 1000, 2) + " Mbps"; } else { txtTotal_text = FormatNumber(total, 2) + " Kbps"; estatisticas_est_bt = FormatNumber(total, 2) + " Kbps"; } // end else if if (parseFloat(FormatNumber(total / 8, 2)) >= 1000) { txtTotalB_text = FormatNumber(total / 8 / 1000, 2) + " MBps"; estatisticas_est_by = FormatNumber(total / 8 / 1000, 2) + " MBps"; } else { txtTotalB_text = FormatNumber(total / 8, 2) + " KBps"; estatisticas_est_by = FormatNumber(total / 8, 2) + " KBps"; } // end else if velocidade_real = total / 8; vez = 0; velocidade = 0; somar = 10; girado = 230; if (parseFloat(total) <= 20) { velocidade = parseFloat(total) * 1.100000E+000 + 230; } else if (parseFloat(total) <= 40) { velocidade = (total - 20) * 9.000000E-001 + 252; } else if (parseFloat(total) <= 60) { velocidade = total - 40 + 270; } else if (parseFloat(total) <= 100) { velocidade = (total - 60) * 5.250000E-001 + 291; } else if (parseFloat(total) <= 200) { velocidade = (total - 100) * 2.000000E-001 + 314; } else if (parseFloat(total) <= 500) { velocidade = (total - 200) * 6.666667E-002 + 340; } else if (parseFloat(total) <= 1000) { velocidade = (total - 500) * 9.200000E-002 + 364; } else if (parseFloat(total) <= 1500) { velocidade = (total - 1000) * 7.600000E-002 + 412; } else if (parseFloat(total) <= 2000) { velocidade = (total - 1500) * 7.800000E-002 + 449; } else { velocidade = 490; } // end else if intMostra = setInterval(_mostrares, 1000); velocidade = (velocidade - 230) / 200; } // End of the function function _mostrares() { clearInterval(intMostra); estatisticas.gotoAndStop(2); estatisticas.est_tem.text = estatisticas_est_tem; estatisticas.est_seg.text = estatisticas_est_seg; txtTotal.text = txtTotal_text; estatisticas.est_bt.text = estatisticas_est_bt; txtTotalB.text = txtTotalB_text; estatisticas.est_by.text = estatisticas_est_by; mg = setInterval(giro, 20); } // End of the function function giro() { ponteiro._rotation = ponteiro._rotation + velocidade; ++vez; if (vez == 198) { velocidade = 0; clearInterval(mg); _root.ponteiro.giro(); } // end if } // End of the function function dateDiff(p_Interval, p_Date1, p_Date2, p_firstdayofweek, p_firstweekofyear) { var dt1 = new Date(p_Date1); var dt2 = new Date(p_Date2); var iDiffMS = dt2.valueOf() - dt1.valueOf(); var dtDiff = new Date(iDiffMS); var nYears = dtDiff.getUTCFullYear() - 1970; var nMonths = dtDiff.getUTCMonth() + (nYears != 0 ? (nYears * 12) : (0)); var nQuarters = parseInt(nMonths / 3); var nWeeks = parseInt(iDiffMS / 1000 / 60 / 60 / 24 / 7); var nDays = parseInt(iDiffMS / 1000 / 60 / 60 / 24); var nHours = parseInt(iDiffMS / 1000 / 60 / 60); var nMinutes = parseInt(iDiffMS / 1000 / 60); var nSeconds = parseInt(iDiffMS / 1000); var nMilliseconds = iDiffMS; var iDiff = 0; switch (p_Interval.toLowerCase()) { case "yyyy": { return (nYears); } case "q": { return (nQuarters); } case "m": { return (nMonths); } case "y": case "d": { return (nDays); } case "w": { return (nDays); } case "ww": { return (nWeeks); } case "h": { return (nHours); } case "n": { return (nMinutes); } case "s": { return (nSeconds); } case "ms": { return (nMilliseconds); } } // End of switch } // End of the function function FormatNumber(num, decimalNum, bolLeadingZero, bolParens, bolCommas) { if (isNaN(parseInt(num))) { return ("NaN"); } // end if var tmpNum = num; var iSign = num < 0 ? (-1) : (1); tmpNum = tmpNum * Math.pow(10, decimalNum); tmpNum = Math.round(Math.abs(tmpNum)); tmpNum = tmpNum / Math.pow(10, decimalNum); tmpNum = tmpNum * iSign; var tmpNumStr = new String(tmpNum); if (!bolLeadingZero && num < 1 && num > -1 && num != 0) { if (num > 0) { tmpNumStr = tmpNumStr.substring(1, tmpNumStr.length); } else { tmpNumStr = "-" + tmpNumStr.substring(2, tmpNumStr.length); } // end if } // end else if if (bolCommas && (num >= 1000 || num <= -1000)) { var iStart = tmpNumStr.indexOf("."); if (iStart < 0) { iStart = tmpNumStr.length; } // end if for (iStart = iStart - 3; iStart >= 1; iStart = iStart - 3) { tmpNumStr = tmpNumStr.substring(0, iStart) + "," + tmpNumStr.substring(iStart, tmpNumStr.length); } // end of for } // end if if (bolParens && num < 0) { tmpNumStr = "(" + tmpNumStr.substring(1, tmpNumStr.length) + ")"; } // end if if (length(tmpNumStr.split(".")[1]) == 0) { return (tmpNumStr.split(".")[0]); } else if (length(tmpNumStr.split(".")[0]) == 0) { return ("0," + tmpNumStr.split(".")[1]); } else { return (tmpNumStr.split(".")[0] + "," + tmpNumStr.split(".")[1]); } // end else if } // End of the function estatisticas.gotoAndStop(1); estatisticas.barra.gotoAndStop(1); estatisticas.porcentagem.text = "0%"; estatisticas.transferidos.text = "0 KB"; estatisticas.restantes.text = "Calculando..."; str = "zxs;ase;wqs;dfe;sft;iuh;loiu;cdf;dse;gyy;sas;fgh;saa;fgh;fsa;qwe;xsd;vh;mj;kj;r;as;wet;nhy;muu;ccd;vfv;zal;juw;qqc;zaz;azz;zza;aaz;aza;cdf;fdc;dfc;dcf;fcds;uyr;qwi;nbn;mkm;zzxs;awqfi;bfg;ds;wewrtyy;uyu;jh;jxvf;dsf;fds;fdsf;gh;gjuyu;ety;dsad;trethgfb;bvc;dsdas;ewe;tr;tyuytu;ty;xdsa;sxdggh;yth;jy;fdsf;x"; strarr = str.split(";"); antes = new Date(); loadMovie("velo_load.swf?" + strarr[random(strarr.length)] + "=" + random(1.000000E+011), "imagem"); stop; velocidade_real = 0; estatisticas_est_tem = ""; estatisticas_est_seg = ""; txtTotal_text = ""; estatisticas_est_bt = ""; txtTotalB_text = ""; estatisticas_est_by = ""; velocidade = 0; somar = 10; girado = 232; atrito = 9.750000E-001; x = 0; vez = 0; total_bites = 0; tempo_total = 0; arquivo = 1; ba_taxa = 0; calcular = 0; //set ();