Creation
This commit is contained in:
79
script/test/script.py
Normal file
79
script/test/script.py
Normal file
@@ -0,0 +1,79 @@
|
||||
import sys
|
||||
import time
|
||||
|
||||
#To add library folders from within the script
|
||||
#sys.path.append("./site-packages")
|
||||
|
||||
|
||||
import requests
|
||||
r = requests.get('https://api.github.com', auth=('user', 'pass'))
|
||||
print r.status_code
|
||||
print r.headers['content-type']
|
||||
r.close()
|
||||
|
||||
|
||||
def calc2(a):
|
||||
return a*2
|
||||
time.sleep(1)
|
||||
#import os
|
||||
#print os.environ
|
||||
#import calc
|
||||
|
||||
lib.load("calc")
|
||||
lib.load("cls")
|
||||
time.sleep(1)
|
||||
for x in range(3):
|
||||
print x
|
||||
while(True):
|
||||
print x*2
|
||||
break
|
||||
time.sleep(1)
|
||||
x=cls()
|
||||
#x.execute()
|
||||
#print dev.take()
|
||||
#print dev2.val
|
||||
time.sleep(1)
|
||||
print calc(4)
|
||||
|
||||
|
||||
|
||||
data = [1,2,3,4,5]
|
||||
path="group/data"
|
||||
|
||||
|
||||
saveData(path, data)
|
||||
read =loadData(path)
|
||||
|
||||
print read.tolist()
|
||||
|
||||
#plot(read)
|
||||
|
||||
|
||||
data = [ [1,2,3,4,5], [2,3,4,5,6], [3,4,5,6,7]]
|
||||
path="group/data2"
|
||||
|
||||
|
||||
saveData(path, data)
|
||||
read =loadData(path)
|
||||
|
||||
print read.tolist()
|
||||
|
||||
plot(read)
|
||||
|
||||
path = "group/data3"
|
||||
createData(path, 'i')
|
||||
for i in range(10):
|
||||
saveDataItem(path,i)
|
||||
|
||||
|
||||
path = "group/data4"
|
||||
createData(path, 'l', False, (0,0))
|
||||
for row in data:
|
||||
saveDataItem(path, row)
|
||||
|
||||
|
||||
|
||||
|
||||
"""
|
||||
It lives!!!!
|
||||
"""
|
||||
Reference in New Issue
Block a user