- renamed main.py to brewpi.py
git-svn-id: http://moon:8086/svn/projects/HendiControl@124 fda53097-d464-4ada-af97-ba876c37ca34
This commit is contained in:
@@ -1,6 +1,27 @@
|
|||||||
#!/usr/bin/python3
|
#!/usr/bin/python3
|
||||||
|
|
||||||
|
import time
|
||||||
|
import json
|
||||||
|
import configparser
|
||||||
|
from pid import Pid
|
||||||
|
from controller import Controller
|
||||||
|
from mass import Mass
|
||||||
|
from stirrer import Stirrer
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
|
|
||||||
|
fp = open("brewpi.cfg.json")
|
||||||
|
configJson = json.load(fp)
|
||||||
|
|
||||||
|
plant = Mass(configJson["WaterSim"])
|
||||||
|
ruehrer = Stirrer(configJson["Stirrer"])
|
||||||
|
ablauf = Controller(configJson["Controller"], plant, ruehrer)
|
||||||
|
|
||||||
|
fp = open("Rezept-001.json")
|
||||||
|
recipeJson = json.load(fp)
|
||||||
|
|
||||||
|
ablauf.start(recipeJson)
|
||||||
|
ablauf.stop()
|
||||||
|
|
||||||
print ("End of program.")
|
print ("End of program.")
|
||||||
|
|
||||||
|
|||||||
@@ -1,27 +0,0 @@
|
|||||||
#!/usr/bin/python3
|
|
||||||
|
|
||||||
import time
|
|
||||||
import json
|
|
||||||
import configparser
|
|
||||||
from pid import Pid
|
|
||||||
from controller import Controller
|
|
||||||
from mass import Mass
|
|
||||||
from stirrer import Stirrer
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
|
||||||
|
|
||||||
fp = open("brewpi.cfg.json")
|
|
||||||
configJson = json.load(fp)
|
|
||||||
|
|
||||||
plant = Mass(configJson["WaterSim"])
|
|
||||||
ruehrer = Stirrer(configJson["Stirrer"])
|
|
||||||
ablauf = Controller(configJson["Controller"], plant, ruehrer)
|
|
||||||
|
|
||||||
fp = open("Rezept-001.json")
|
|
||||||
recipeJson = json.load(fp)
|
|
||||||
|
|
||||||
ablauf.start(recipeJson)
|
|
||||||
ablauf.stop()
|
|
||||||
|
|
||||||
print ("End of program.")
|
|
||||||
|
|
||||||
Reference in New Issue
Block a user