def _hm_read_address(self):
        """Reads from the DCB and maps to yaml config file."""
        response = self._hm_send_address(self.address, 0, 0, 0)
        lookup = self.config['keys']
        offset = self.config['offset']
        keydata = {}
        for i in lookup:
            try:
                kdata = lookup[i]
                ddata = response[i + offset]
                keydata[i] = {
                    'label': kdata,
                    'value': ddata
                }
            except IndexError:
                logging.info("Finished processing at %d", i)
        return keydata
def _hm_read_address ( self ) : response = self . _hm_send_address ( self . address , 0 , 0 , 0 ) lookup = self . config [ 'keys' ] offset = self . config [ 'offset' ] keydata = { } for i in lookup : try : kdata = lookup [ i ] ddata = response [ i + offset ] keydata [ i ] = { 'label' : kdata , 'value' : ddata } except IndexError : logging . info ( "Finished processing at %d" , i ) return keydata
Reads from the DCB and maps to yaml config file.