protected override Task <IObservable <LocalisationData> > InitializeCore() { return(Task.Run( () => { IObservable <GeoData> geoDataObservable = ToGeoData(ToNmeaSentence(SerialConnection.CreateCharListener(this.SerialPortName, this.SerialBaudRate, Parity.None, 8, StopBits.One))); return ( from geoData in geoDataObservable select new LocalisationData { RawData = geoData, GpsStatus = (geoData.PositionData.NbSatellites < 4 || geoData.PositionData.Quality == FixType.None || geoData.PrecisionData.Hdop > 4 ? GpsStatus.SignalLost : GpsStatus.Reliable) }).Publish().RefCount(); })); }