Cruisers Forum
 


Reply
  This discussion is proudly sponsored by:
Please support our sponsors and let them know you heard about their products on Cruisers Forums. Advertise Here
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 14-10-2010, 02:46   #1
Registered User

Join Date: Oct 2010
Posts: 1
OpenCPN - NMEA Data from TCP Input

Hello everyone,
first of all sorry for my english.
I am new to OpenCPN.
I am trying to receive nmea data from an internet server, but I am not able to configure it. I already tried tcp2rs, but when i configure opencpn to listen to com1 where data was redirected it says "Could not open serial port COM1.

Any idea.
Tnx
framen is offline   Reply With Quote
Old 14-10-2010, 11:36   #2
Registered User

Join Date: May 2010
Posts: 1
In windows, try with GPSGate from www.franson.com.

You can to make a bridge from IP to one o more virtual COM ports in your PC.

I Use OpenCPN on board across my WIFI, and anywhere by Internet.

I have connected both RS232 ports from AIS and NMA to a double Serial/IP converter (Moxa Device Servers NPort® 5210 - 2-port RS-232 serial device servers) and this adapter to my router, then I can to access data fron LAN, WIFI and Internet with OpenCPN.

Best regards, Carmelo Milla
www.olaje.com
cmilla is offline   Reply With Quote
Old 05-10-2012, 14:28   #3
Registered User

Join Date: Dec 2007
Posts: 175
Re: OpenCPN - NMEA Data from TCP Input

Any opensource solutions to this challenge?
night0wl is offline   Reply With Quote
Old 05-10-2012, 15:29   #4
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 7,394
Re: OpenCPN - NMEA Data from TCP Input

nightOwl...

This feature is scheduled for inclusion in the next full Release of OpenCPN, Version 3.2, due later this fall.

Thanks
Dave
bdbcat is offline   Reply With Quote
Old 05-10-2012, 17:27   #5
Moderator Emeritus
 
Paul Elliott's Avatar

Cruisers Forum Supporter

Join Date: Sep 2006
Posts: 4,663
Images: 4
Re: OpenCPN - NMEA Data from TCP Input

Quote:
Originally Posted by night0wl View Post
Any opensource solutions to this challenge?
NavMonPc will bridge / route NMEA data between TCP/IP and RS232 ports (virtual and physical RS232 ports). It's not open source, and it is a Windows-only program, but it is free.
__________________
Paul Elliott, S/V VALIS - Pacific Seacraft 44 #16 - Friday Harbor, WA
www.sailvalis.com
Paul Elliott is offline   Reply With Quote
Old 06-10-2012, 06:30   #6
Registered User

Join Date: Jul 2012
Location: The Netherlands
Posts: 32
Re: OpenCPN - NMEA Data from TCP Input

VSPE will do this too in Windows 32 bit, for free.
Windows 64 bits will cost you money, because fees have to be paid to microsoft to prove that the software is safe (right..).
You can find out more through Eterlogic's website.
MAS3 is offline   Reply With Quote
Old 11-10-2012, 14:54   #7
Registered User
 
jram's Avatar

Join Date: Oct 2010
Posts: 72
Re: OpenCPN - NMEA Data from TCP Input

Any linux offerings that will do this? I was hoping to use my Raspberry Pi as a navigation information bridge.
jram is offline   Reply With Quote
Old 11-10-2012, 17:54   #8
Registered User

Join Date: Apr 2012
Location: New Hampshire
Boat: CWorker 4 ASV
Posts: 17
Re: OpenCPN - NMEA Data from TCP Input

Quote:
Originally Posted by jram View Post
Any linux offerings that will do this? I was hoping to use my Raspberry Pi as a navigation information bridge.
The socat utility should be able to do that.

Interestingly enough, I also just happen to fix some code in my branch that allows AIS data to be read from a TCP/IP connection. I'm still getting used to GitHub, but I also noticed what seems to be other efforts to revamp the data streams which might make the use of external utilities unnecessary?
rolker is offline   Reply With Quote
Old 12-10-2012, 07:24   #9
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 7,394
Re: OpenCPN - NMEA Data from TCP Input

Hey guys....

If you really need this right now, and feel like hacking, have a look at ais.cpp, line 3190. We already have an undocumented way to get AIS data from TCP/IP. You could do the same for GPS data, if you want to play....

Code:
   /*
     A special test for a user defined FIFO
     To use this method, do the following:
     a.  Create a fifo            $mkfifo /tmp/aisfifo
     b.  netcat into the fifo     $nc {ip} {port} > /tmp/aisfifo
     sample {ip} {port} could be  nc 82.182.117.xx 6401 > /tmp/aisfifo
     c.  hand edit opencpn.conf and make AIS data source like this:
     [Settings/AISPort]
     Port=Serial:/tmp/aisfifo

     This also works if you have an ascii ais log
     for which you can simply $cat ais.log > /tmp/aisfifo
     */
    if(m_pPortName->Contains(_T("fifo")))
    goto port_ready;
This interface is unsupported, and will go away in the next Release.

Have Fun
Dave
bdbcat is offline   Reply With Quote
Old 12-10-2012, 08:22   #10
Registered User

Join Date: Apr 2012
Location: New Hampshire
Boat: CWorker 4 ASV
Posts: 17
Re: OpenCPN - NMEA Data from TCP Input

Dave, I updated the existing socket code and committed it to my master branch on github.

https://github.com/rolker/OpenCPN

Is that code going to disappear as well in the next release? If so, will it be replaced with something that will allow me to connect to a TCP server to receive AIS messages?

My use for this functionality is for monitoring the transmission of area notices via AIS regarding Right Whale detection off of Boston.

Right Whale Listening Network, Cornell, Bioacousti

To monitor this from my office, I have access to the Coast Guard's National AIS data feed so I made a few updates to the socket code in ais.cpp so I can skip the suggested step of setting up a virtual serial port.

The updates include:
- Make a TCP source show up in the config gui (TCP/IP:server shows up instead of None)
- Allow port to be specified and defaults to previously hard coded one if omitted. (ex TCP:IP:aisserver:12345)
- Since the data stream I get includes extra meta data, the NMEA part (From '!' to the checksum) gets extracted and anything else is discarded, which should make this flexible enough to use with other sources which might include timestamps and such.

The data stream I use includes live data from all US waters, so it's a good stress test for OpenCPN's AIS functionality!

It would be nice if future versions would support the functionality I mention above and I'm willing to lend a hand in the coding to make that happen.

Roland
rolker is offline   Reply With Quote
Old 12-10-2012, 11:36   #11
Marine Service Provider
 
bdbcat's Avatar

Join Date: Mar 2008
Posts: 7,394
Re: OpenCPN - NMEA Data from TCP Input

Roland...

The implementation will change for the next release, but the functionality will remain. If you have something that works now, I would not recommend investing too much more effort in making it production worthy. It will all change shortly.

You will still need to hack the code to filter out the specific message you want. This sounds like a good place for a PlugIn.....

Glad you got it to work for your specific case with the existing code, though.

Dave
bdbcat is offline   Reply With Quote
Old 12-10-2012, 12:19   #12
Registered User

Join Date: Apr 2012
Location: New Hampshire
Boat: CWorker 4 ASV
Posts: 17
Re: OpenCPN - NMEA Data from TCP Input

Dave,

I got it to work, almost. It runs for a while and then the AIS data stops updating. I haven't debugged the reason, and don't feel like doing so it is all going to change anyway.

I noticed Pavel's datastream branch on GitHub. I assume this will be the new code to replace this functionality correct? I just fetched it and am looking at it now. I'll see if I can lend a hand in testing it.

Roland
rolker is offline   Reply With Quote
Reply

Tags
nmea

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
NMEA 2K and OpenCPN - How? sapster77 OpenCPN 18 13-03-2013 11:29
Interfacing NMEA Data to Computer bobfnbw Marine Electronics 81 07-03-2012 08:46
Setup Ubuntu GPSd/GPSLib, AIS and Other NMEA Data bluearcus OpenCPN 8 31-08-2010 02:50
Connectors and NMEA Logger for Depth and Lat / Long Data Skylark Navigation 1 17-08-2010 07:34
Data Converter NMEA to Ethernet ticki Marine Electronics 2 21-03-2010 13:37

Advertise Here


All times are GMT -7. The time now is 21:48.


Google+
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Social Knowledge Networks
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2024, vBulletin Solutions, Inc.

ShowCase vBulletin Plugins by Drive Thru Online, Inc.