fixed race condition, loadingWidget is not yet defined
don't hide loading indicater if data.json request is still pending
timeout the getting of sensor values to prevent long waiting times