cmcmahon
Posts: 6
Joined: Wed Dec 03, 2008 12:34 am

Output Stream

Wed Dec 10, 2008 11:47 pm

I am able to bring the GGA message into my program. Use GPS tools to seperate it into Lat, Long etc.... And I am converting it to SPCS83.

I need to be able to reassemble the converted data and send it back out a ifferent COM port in a way that GPSGate will recognize it as valid GPS Data.

I am able to do everything but get GPSGate to recognize it. I setup the output port, and try to use the .Write Function but that takes my string and converts it to an Integer...

What i need is a way to send the recompiled String abd send it back out the serial port in tact....

Hopefully this is making sense. It appears to me that I am just missing something easy

Thank You

User avatar
johan
GpsGate
Posts: 15342
Joined: Wed Aug 04, 2004 10:40 pm
Location: Sweden
Contact: Website

RE: Output Stream

Thu Dec 11, 2008 3:17 pm

Post some of your code to demonstrate what you mean.

Regards,
Johan

Franson Support

cmcmahon
Posts: 6
Joined: Wed Dec 03, 2008 12:34 am

RE: Output Stream

Thu Dec 11, 2008 5:31 pm

txtEasting.Text = (objPos.Easting * 3.28083333)
txtNorthing.Text = (objPos.Northing * 3.28083333)
txtZone.Text = objPos.Zone
txttime.Text = objFix.UTC
toutput.Text = "$GPGGA," & txttime.Text & "," & txtNorthing.Text & ",N," & txtEasting.Text & ",E"



Try
objPort.Write(toutput.Text)
txtCOut.Text = objPort.Write(toutput.Text)



Thats a small section.... In GPSGate it shows that data is comming in but its not considered GPS Data.

I realized after looking at this line:

txtCOut.Text = objPort.Write(toutput.Text)

that what i was actually seeing was the number of bytes written to the serial port and not the actual string that is being sent.


Maybe my issue is that GPSGate doesnt like the stream it is being sent. If thats the case what needs to be changed for GPS gate to accept the feed.

Keep in mind that the only data we are interested in is the Northing , Easting and Time

User avatar
johan
GpsGate
Posts: 15342
Joined: Wed Aug 04, 2004 10:40 pm
Location: Sweden
Contact: Website

RE: Output Stream

Thu Dec 11, 2008 5:39 pm

GpsGate will not filter any data unless you have added a filter in GpsGate.

GpsGate will not recognize your data as NMEA data or GPS data, simply because the data you send is not NMEA formatted. This does not mean however that GpsGate will not be able to forward it.

If you get a number at the other end, it is because you send a number. Make sure you send the string you intend to send.

Use a the debugger you find in Visual Studio, step through your code and find your errors. Watch and examine the variables. Read the documentation about _each_ method you call on _each_ object. Do not assume anything work in a particular way unless you have carefull examined your code step by step in the debugger that it really do what you intend. And you have carefully read each part of the documentation for each call you make. If you do that, you will soon see where things are not what you believe it was.

You will for example see where this "number" comes from.

Regards,
Johan

Franson Support

cmcmahon
Posts: 6
Joined: Wed Dec 03, 2008 12:34 am

RE: Output Stream

Thu Dec 11, 2008 6:31 pm

In GPSGate I do not (that i am aware of) have a method of outputting to a file other than by using the File Recorder / NMEA Filter. I am definately not at this point sending out a Tru GGA message as is clearly seen from the missing data in the sentence I am sending.

The Port.Write function looks like it is working as it states .... I have provided it a string it sends data and returns Bytes Written which is the "number" I was seeing.

How do I take a look at Exactly what GPSGate is recieving?

User avatar
johan
GpsGate
Posts: 15342
Joined: Wed Aug 04, 2004 10:40 pm
Location: Sweden
Contact: Website

RE: Output Stream

Thu Dec 11, 2008 6:34 pm

Have you connected your application to one of GpsGate's outputs and then you write data back to GpsGate? Or what have you done?

Regards,
Johan

Franson Support

cmcmahon
Posts: 6
Joined: Wed Dec 03, 2008 12:34 am

RE: Output Stream

Thu Dec 11, 2008 6:48 pm

Data flow is as follows

GPSDevice -> GPSGate (Com1) -> GPSConverter (VCom11) -> GPSGate (VComm12)


Everything seems to be working fine up until i send to GPSGate the last time. I can understand GPS gate telling me that it sees Data but it is Unknown.

I am not concerned that GPSGate see the input on VCom 12 as valid GPSData... I am Concerned that it is getting the string in it's entirety as defined by


toutput.Text = "$GPGGA," & txttime.Text & "," & txtNorthing.Text & ",N," & txtEasting.Text & ",E"


What type of output can i setup in GPSGate that will simply let me monitor that.. I was hoping I could simply use the File Recorder but that doesnt seem to be working for me.

Return to “GpsTools”