Hi

I have started developing a driver for the TCS2 controller used by Alluna Optics Telescopes (I am not affiliated). This is the first indi driver I develop. Nevertheless, after some fiddling, I managed to clone the indi 'skeleton' focuser driver and got it to handshake the device. Now, before going deeper, I have a few design questions:

  • are new drivers expected to be inside the 'drivers' subfolder, or should new drivers be shipped separate from indi?
  • can I later add more functionality not related to focusing to the same driver? The TCS2 can do more than just drive the focuser, e.g. it opens the dust cover and controls climate, rotator (if existing). Would it still be OK, to have the driver in drivers/focuser? There seems to be no category for such multi-purpose "telescope control" devices.
  • can I somehow switch the serial line to line buffering? Or, is the only supported method to read until the next 'newline' character?
  • some device commands like FocuserGoTo send multiple lines back (it reports every small focuser step). Should I capture and process those messages in the TimerHit method or in the MoveAbsFocuser method? The output looks like this:
I# // indicates that focuser starts moving
K#number // indicates current focuser position
K#number
...
J# // indicates that focuser stopped moving
  • In case the TimerHit is only expected to send its own commands to the device, e.g. check temperature, do I need take care of not sending commands while the focuser is moving or is this already guranteed by the framework (single threaded execution)?
  • Is there a programmer's guide for timing issues in indi? I.e., about how to avoid blocking I/O and methods to run for too long.
Thanks,
Peter
 

Read More...