Пример #1
0
 def __load_option_settings(self):
     # Assist ALSA fireface driver to handle MIDI messages from Fireface 400.
     if self.__name == 'Fireface400':
         FFOptionReg.build_single_option(self.__option_cache,
                                         'midi-low-addr', '0x00000000', True)
     req = Hinawa.FwReq()
     frames = pack('<3I', *self.__option_cache)
     req.transaction(self.get_node(), Hinawa.FwTcode.WRITE_BLOCK_REQUEST,
                     self.__regs[0], len(frames), frames)
Пример #2
0
 def __create_single_option_initial_cache(self, cache):
     default_params = {
         'auto-sync': {
             'internal': True,
             'base-441': True,
             'base-480': True,
             'double': True,
             'quadruple': True,
         },
         'front-input': {
             'in-1': False,
             'in-7': False,
             'in-8': False,
         },
         'rear-input': {
             'in-1': True,
             'in-7': True,
             'in-8': True,
         },
         'phantom-power': {
             'mic-7': False,
             'mic-8': False,
             'mic-9': False,
             'mic-10': False,
         },
         'spdif-in': {
             'optical': False,
             'track-maker': False,
         },
         'spdif-out': {
             'professional': False,
             'emphasis': False,
             'non-audio': False,
             'optical': False,
         },
         'instruments': {
             'drive': False,
             'limit': True,
             'speaker-emu': False,
         },
         'wdclk-out': {
             'single-speed': True,
         },
         'in-error': {
             'continue': True,
         },
     }
     for target, params in default_params.items():
         for item, enable in params.items():
             FFOptionReg.build_single_option(cache, target, item, enable)
Пример #3
0
 def set_single_option(self, target, item, enable):
     FFOptionReg.build_single_option(self.__option_cache, target, item,
                                     enable)
     self.__write_cache_to_file()
     self.__load_option_settings()