'Get the latest data the MH-Z19 sensor.'

@Throttle(MIN_TIME_BETWEEN_UPDATES)
def update(self):

    self.data = {}
    try:
        result = self.co2sensor.read_mh_z19_with_temperature(self._serial)
        if (result is None):
            return
        (co2, temperature) = result
    except OSError as err:
        _LOGGER.error('Could    not    open    serial    connection    to    %s    (%s)', self._serial, err)
        return
    if (temperature is not None):
        self.data[SENSOR_TEMPERATURE] = temperature
    if ((co2 is not None) and (0 < co2 <= 5000)):
        self.data[SENSOR_CO2] = co2
