This project is read-only.

possible to read raw GPS data from tcp/ip port?

Oct 28, 2010 at 3:58 AM

hullo all,

I'm new to c# and I'm having a bit of a problem understanding the framework. I was wondering if it's possible to parse raw GPS data from a network tcp/ip port with GPS.NET.

I want to make a listening server that listens on a specific port for NMEA sentences and when I do get those data, do I use the NmeaInterpreter or some other class? I know the NmeaInterpreter has a public parse(...) function but throwing NMEA sentences dosen't seem to trigger any events that I hook up like the positions.

I assume those only works when it's hooked up to a 'device' like the example I saw on the thread where an NmeaEmulator was hooked up to the NmeaInterpreter via a VirtualDevice class.

I did see a NetworkDevice class but I couldn't get it working. Is this class the one I need to set up a listening port and hook up the interpreter to it?

hopefully someone could shed some light on this. thank you.

Nov 4, 2010 at 9:41 PM

Yes, it just takes a few lines of code:

Dim loGPS As GeoFramework.Gps.Nmea.NmeaInterpreter
Dim loEndpoint As New IPEndPoint(Net.IPAddress.Parse(""), 1)
Dim loDevice As New GeoFramework.Gps.IO.NetworkDevice(Sockets.AddressFamily.InterNetwork, Sockets.SocketType.Stream, Sockets.ProtocolType.Tcp, loEndpoint)
loGPS = New GeoFramework.Gps.Nmea.NmeaInterpreter

Insert your own address and port number for the Endpoint