Files
Feeding_control_system/main.py

38 lines
720 B
Python
Raw Normal View History

# main.py
import time
from config.settings import Settings
from core.system import FeedingControlSystem
def main():
# 加载配置
settings = Settings()
# 初始化系统
system = FeedingControlSystem(settings)
try:
# 系统初始化
system.initialize()
print("系统准备就绪5秒后开始下料...")
time.sleep(5)
# 启动下料流程
system.start_lower_feeding()
# 保持运行
while True:
time.sleep(1)
except KeyboardInterrupt:
print("收到停止信号")
except Exception as e:
print(f"系统错误: {e}")
finally:
system.stop()
if __name__ == "__main__":
main()