Created
November 15, 2017 08:35
-
-
Save markroxor/3bdfe34c762697809ddef0d3d226a831 to your computer and use it in GitHub Desktop.
wip
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import urllib2 | |
import json | |
import pickle | |
import time | |
while True: | |
response = urllib2.urlopen('http://122.252.246.246:8081/MMTSLiveeng.html') | |
html = response.read() | |
js = json.loads(html) | |
print(js) | |
#print(js['FL']) | |
f = open("stations",'r') | |
stats = pickle.load(f) | |
f.close() | |
#for st in js: | |
# print st | |
f = open("stations","wb") | |
f.close() | |
time.sleep(1) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment