digital преди 8 години
родител
ревизия
1aae316bf0
променени са 2 файла, в които са добавени 0 реда и са изтрити 69 реда
  1. 0 39
      lib/beewatch/pinapi/__init__.py
  2. 0 30
      lib/beewatch/server/__init__.py

+ 0 - 39
lib/beewatch/pinapi/__init__.py

@@ -41,45 +41,6 @@ class BeeWeighingScale(digilib.pin.PinAPIBase):
     """handles all load cells"""
     pass
 
-# class PinAPIBee(digilib.pin.PinAPIBase):
-#     """will be configurable via yaml file"""
-#     action_in_process = False
-#     def __init__(self):
-#         super(PinAPIBee,self).__init__()
-#         self.engine_controller = digilib.pin.EnginesController(
-#             left=[4,17],
-#             right=[27,22],
-#         )
-#         self.text_to_func = {
-#             "turn":self.engine_controller.turn
-#         }
-#     def __enter__(self):
-#         if self.action_in_process:
-#             lpin.debug("action already in process, not entering")
-#             return False
-#     def call(self,func_name,args,respond_method,kwargs):
-#         ttf = self.text_to_func
-#         if func_name in ttf.keys():
-#             try:
-#                 task = curio.run(
-#                     ttf[func_name](
-#                         # self.bee_api,
-#                         *args,
-#                         respond_method=respond_method,
-#                         **kwargs,
-#                     )
-#                 )
-#             except:
-#                 tb = traceback.format_exc()
-#                 print(tb)
-#                 respond_method(tb)
-#         else:
-#             respond_method("Unknown command")
-
-
-
-
-
 
 
 

+ 0 - 30
lib/beewatch/server/__init__.py

@@ -117,36 +117,6 @@ class ConnHandlerBeeWatch(digilib.network.ConnHandlerBase):
         self.send(text)
 
 
-# class BeeAPI(object):
-#     def __init__(self, config_file=None):
-#         super(BeeAPI, self).__init__()
-#         lapi.info("BeeAPI")
-#         self.engine_controller = digilib.pin.EnginesController(
-#             left=[4,17],
-#             right=[27,22],
-#         )
-#         self.text_to_func = {
-#             "turn":self.engine_controller.turn
-#         }
-#     def call(self,func_name,args,respond_method,kwargs):
-#         ttf = self.text_to_func
-#         if func_name in ttf.keys():
-#             try:
-#                 task = curio.run(
-#                     ttf[func_name](
-#                         # self.bee_api,
-#                         *args,
-#                         respond_method=respond_method,
-#                         **kwargs,
-#                     )
-#                 )
-#             except:
-#                 tb = traceback.format_exc()
-#                 print(tb)
-#                 respond_method(tb)
-#         else:
-#             respond_method("Unknown command")
-