code: def register_listener(self, listener, reading=False):
          
          listener_id = hashable_identity(listener)
          self._listeners[listener_id] = (listener, reading)
          logger.debug(
                      'Register listener for {}'
                      .format(self.name))
docs: Add a callback function that is called when sensor value is updated.
          The callback footprint is received_timestamp, timestamp, status, value.
  
          Parameters
          ----------
          listener : function
              Callback signature: if reading
              listener(katcp_sensor, reading) where
                  `katcp_sensor` is this KATCPSensor instance
                  `reading` is an instance of :class:`KATCPSensorReading`
              Callback signature: default, if not reading
                  listener(received_timestamp, timestamp, status, value)