Advertisement
NubeColectiva

Test Conexión Internet con Python

Aug 5th, 2023 (edited)
1,312
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.40 KB | None | 0 0
  1. import speedtest as st
  2.  
  3. server = st.Speedtest()
  4. server.get_best_server
  5.  
  6. # Test de Descarga
  7. descarga = server.download()
  8. descarga = descarga / 1000000
  9. print(f"Velocidad de Descarga: {descarga} MB/s ")
  10.  
  11. # Test de Subida
  12. subida = server.upload()
  13. subida = subida / 1000000
  14. print(f"Velocidad de Subida: {subida} MB/s")
  15.  
  16. # Test Ping
  17. ping = server.results.ping
  18. print(f"Velocidad de Ping: {ping}")
Tags: python test
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement