'Subscribe MQTT events.
This method must be run in the event loop and returns a coroutine.'

def async_added_to_hass(self):

    @callback
    def message_received(topic, payload, qos):
        'Handle    new    MQTT    messages.'
        self._last_image = payload
    return mqtt.async_subscribe(self.hass, self._topic, message_received, self._qos, None)
