Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
python power
#reads the data (power) from the AER2 on solarBEAT #imports al the necssecary packages import urllib2 Source=urllib2.urlopen("http://upp.nl/application/").read() Source = Source.split(":1865")[1] parameter = Source.split("}]}")[0] totalpower_false = parameter.split("total")[1] totalpower = totalpower_false.split(":")[1] tot_power = round(float(totalpower.split(",")[0]),3) power_false = parameter.split("power")[1] power = round(float(power_false.split(":")[1]),1) up_score = round(100*power/4000,1) print "the power of the AER2 on solarBEAT is:" print power,"Watt" print "the total kWh of the AER2 on solarBEAT since installation is:" print tot_power,"kWh" print "the upp-score is:" print up_score,"%"
run
|
edit
|
history
|
help
0
PyEnum
python
mergeTrees
on_off_3
Data structures
Defining
Python learning
Fold an array
Lists
Counter() in collections