How to get the Temperature another way?

HI!!!, please, I need to get the temperature and use it in a notification, only I use

this in appDelegate{}

var temperature: NSNumber = 0
var t: NSNumber = 0.0 

let tempNotification = ESTTelemetryNotificationTemperature { (tempInfo) in
    var temperature = tempInfo.temperatureInCelsius
    self.optenerDatos(temperatura: temperature)
}
deviceManager.register(forTelemetryNotification: tempNotification)

and

func optenerDatos(temperatura: NSNumber){
    var i = temperatura
    t = i
    //print(i)
}

Was the way I found to get the value, is there another way?. Please help me!!! u.u

So hmm, I assume this doesn’t work for you? Did you enable the Estimote Telemetry packet on your beacon? You can do that with the Estimote iOS app, from the App Store.

yes, I enable de Estimote Telemetry, but the question is about, if is it correct to extract the temperature value as I do in my code. The way I get the data is because I need to use this value in messages. just I need a feedback about to get telemtry values or if the implement code that I use is correct.

The code looks good. I’m still not clear if it works for you, and you’re just asking if that’s the correct way to do it. Or if it doesn’t, and you’re asking how to fix it (: