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 18-12-2016, 14:13   #16
Registered User

Join Date: Oct 2012
Location: Brighton, UK
Boat: Westerly Oceanlord
Posts: 513
Re: Sending waypoints/routes over IP

Quote:
Originally Posted by barnakiel View Post
This is due to how my wifi nmea router works: it muxes serial and net ports. So whatever appears on a serial, gets forwarded to a net and vice-versa. However things that appear on the net do not get forwarded back to the same net.

In other words, my router sends serial data to wifi OK and also wifi to serial works OK. What it refuses to do is taking up WPTs from one device on the wifi network and sending them onwards to another device on this network.

I am not sure how to bite this. Maybe the router should 'echo' the WPTs over the net. Or maybe my challenge is using TCP (not UDP).
What are you using on your router?
muttnik is offline   Reply With Quote
Old 18-12-2016, 15:37   #17
Registered User

Join Date: Aug 2009
Location: between the devil and the deep blue sea
Boat: a sailing boat
Posts: 20,437
Re: Sending waypoints/routes over IP

Quote:
Originally Posted by muttnik View Post
What are you using on your router?
TCP

The router is set to AP mode.

So my wifi devices are clients, the router acts as a server.

b.
barnakiel is offline   Reply With Quote
Old 18-12-2016, 15:45   #18
Registered User

Join Date: Aug 2009
Location: between the devil and the deep blue sea
Boat: a sailing boat
Posts: 20,437
Re: Sending waypoints/routes over IP

OK.

Sorted out.

Now my router too forwards the WPT back to the network. So all instances of OpenCPN that are on this network receive it.

But how do I get OpenCPN do display these waypoints?

I receive them (as seen in the nmea monitor window, phrase ECWPL, direction incoming) but they do not pop up on OpenCPN screen, nor do they come up in the WPTs menu.

So I guess either bad WPT format, or else ... time to dig into OpenCPN manual.

Thanks to all,
b.
barnakiel is offline   Reply With Quote
Old 18-12-2016, 17:04   #19
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,630
Images: 2
Re: Sending waypoints/routes over IP

Why doesn't Method B work?
Why are you reconnecting back to Opencpn? What is it needed for?
If you are doing that, isn't there a way to put a filter on the incoming stream?


Windows - Send Waypoints over IP? wifi? to NSS8.

--------------
Simrad NSS8 with wifi ...listening for NMEA183 & 2000 .. over IP.
.. I want to ..create routes to port over to chartplotter

NSS SImrad wont accept waypoint or route data via wifi. Uss USB or SD to copy.

============
Method A
Hakan -suggested which works.
Code:
NavMonPC
Bridge
 |  
 |--Com1  <---WP --- Com1 O-PORT
 |  
 |--Com2  ----WP --> Com2 O-MAIN  Net-IP-UDP ---> IP-UDP NSS8 (or use IP-TCP)
Method A allows to send a WPT or a route to another device via IP (ethernet cable or a wifi link). In my case the other device is wired into a router.

================
Method B
Barnakiel - Suggested and tried (Don't get this at all?)

Code:
|OUT ---->Com2 (virt)--> NavMonPC ---> Net IP-UDP 
   |                  
Opencpn                      
   |
   | IN <---Com1 (real)
Hakan
Not sure NavMon & OpenCPN can tap into the same port at once?
I need OpenCPN to be on the net port because my nmea data comes in this way.
Result: ONE WP via COM1 (to "GPS")-->COM2-->UDP & COM1-->COM2-->UDP & COM1 ... feedback loop.

Fully faulty method B (one OpenCPN instance - this loops back).

===========
Method C Two Wireless devices
Example: sending wpts from one wireless device to another wireless device over a wifi router.

Code:
wifi --ip-udp-->  wifi router -- ip-udp --> wifi
Same trick between two wireless devices. How the IP router should treat an incoming WPT. Is there anything like an 'echo' command that would send the WPT back over the network so that other connected devices could pick it up?

Hakan Response:
Two wireless devices on the same network segment (like 192.168.1.xx) no problem using protocol UDP. UDP is like a radio broadcast without a specific receiver, everyone is listening as long they're tuned to the same port, like 10110.
The router doesn't care what's broadcast.

==============
Method D
Barnakiel
Code:
2 x laptops running OpenCPN, both on same 192.168.x.x network
 1 x wireless router, AP; creator of the above mentioned network.
The intention: to send WPTs wirelessly between these two laptops.
Wpt sent is not recieved... due to how my wifi nmea router works: it muxes serial and net ports. So whatever appears on a serial, gets forwarded to a net and vice-versa. However things that appear on the net do not get forwarded back to the same net.
serial ---> wifi - OK
wifi ---> serial - OK
IP UDP serial ---> IP UDP serial - NO (and the reverse)
..due to firewall settings on the router?
Using TCP
The router is set to AP mode.
So my wifi devices are clients, the router acts as a server.
---
Changed to UDP Broadcast
Now my router too forwards the WPT back to the network. So all instances of OpenCPN that are on this network receive it.
rgleason is offline   Reply With Quote
Old 18-12-2016, 18:19   #20
Registered User

Join Date: Aug 2009
Location: between the devil and the deep blue sea
Boat: a sailing boat
Posts: 20,437
Re: Sending waypoints/routes over IP

Quote:
Originally Posted by rgleason View Post

Why doesn't Method B work?

Why are you reconnecting back to Opencpn? What is it needed for?

If you are doing that, isn't there a way to put a filter on the incoming stream?

(...)
Why B does not work:

You can filter but you do not because you want the incoming stream to come in because it it is the incoming stream that OpenCPN outputs then to IP. The problem is it also outputs to COM1 and so the WPT goes back to COM2 and again to IP, and so on and forth. So it loops.

So method B (sending and receiving from same OpenCPN instance) is a no no.

Why reconnect back to OpenCPN:

Because OpenCPN cannot send WPTs to IP. But it does forward on IP WPTs received on a serial port.

Except that the incoming WPT must be sent from another instance (or another program). If you try doing this from one instance of OpenCPN you run into above mentioned plan B limitation.

Cheers,
b.
barnakiel is offline   Reply With Quote
Old 18-12-2016, 18:29   #21
Registered User

Join Date: Aug 2009
Location: between the devil and the deep blue sea
Boat: a sailing boat
Posts: 20,437
Re: Sending waypoints/routes over IP

Quote:
Originally Posted by rgleason View Post

(...)

Changed to UDP Broadcast

Now my router too forwards the WPT back to the network.

So all instances of OpenCPN that are on this network receive it.

Thanks.

I am using TCP. I have found the solution though. Now I do get the WPT into the other device but ... (read on).

But the WPTs (that do get received as proven by content of the nmea monitor window on the receiving machine) do not get shown in the receiving OpenCPN - not on the screen nor in the WPTs menu.

I did not have Internet connection earlier and could not see what OpenCPN manual says about receiving waypoints into OpenCPN and getting them displayed.

(My Garmin unit just displays a received WPT as soon as it gets transferred.)

Do the received waypoints show in your receiving OpenCPN??? Once received - do they display?

Cheers,
b.
barnakiel is offline   Reply With Quote
Old 18-12-2016, 18:30   #22
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,630
Images: 2
Re: Sending waypoints/routes over IP

Okay, so you need the loop to send the waypoints (only) back to O so they can be sent on somewhere via a different port.

Is it the WP that gets doubled in the feedback loop or the other data?
If it is other data use a filter on O out or navmonpc out.
If it is the WP data repeating I guess you are SOOL s--- out of luck.

Opencpn could use two connect channels perhaps.
Or some way to tag data going out and then filter it coming in, or perhaps a filter that eliminates the same sentence within a certain period.
rgleason is offline   Reply With Quote
Old 18-12-2016, 18:33   #23
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,630
Images: 2
Re: Sending waypoints/routes over IP

Ah ah it is just the waypoints .
Must be some way to use 1 opencpn...
rgleason is offline   Reply With Quote
Old 18-12-2016, 18:38   #24
Registered User

Join Date: Aug 2009
Location: between the devil and the deep blue sea
Boat: a sailing boat
Posts: 20,437
Re: Sending waypoints/routes over IP

I had a long search of the manual. I cannot find any 'how to receive waypoints' reference. It seems to only talk about sending waypoints to say a GPS unit. The point is I want the reverse - I want to receive waypoints over the net (or wire) and see them displayed in 'my' OpenCPN.

Maybe it cannot be done.

b.
barnakiel is offline   Reply With Quote
Old 18-12-2016, 18:44   #25
Registered User

Join Date: Feb 2010
Location: Tierra del Fuego
Boat: Phantom 19
Posts: 6,208
Re: Sending waypoints/routes over IP

Barnakiel...
Nothing like that is implemented, OpenCPN does not do anything with the WPT sentences it receives. Feature request in flyspray is the way to change it...

Pavel
nohal is online now   Reply With Quote
Old 18-12-2016, 18:48   #26
Registered User

Join Date: Aug 2009
Location: between the devil and the deep blue sea
Boat: a sailing boat
Posts: 20,437
Re: Sending waypoints/routes over IP

Quote:
Originally Posted by nohal View Post
Barnakiel...
Nothing like that is implemented, OpenCPN does not do anything with the WPT sentences it receives. Feature request in flyspray is the way to change it...

Pavel
Pavel,

THX. This was my intuition too from today's experiments.

barnakiel
barnakiel is offline   Reply With Quote
Old 18-12-2016, 18:57   #27
Registered User

Join Date: Aug 2009
Location: between the devil and the deep blue sea
Boat: a sailing boat
Posts: 20,437
Re: Sending waypoints/routes over IP

Quote:
Originally Posted by rgleason View Post
Okay, so you need the loop to send the waypoints (only) back to O so they can be sent on somewhere via a different port.

Is it the WP that gets doubled in the feedback loop or the other data?
If it is other data use a filter on O out or navmonpc out.
If it is the WP data repeating I guess you are SOOL s--- out of luck.

Opencpn could use two connect channels perhaps.
Or some way to tag data going out and then filter it coming in, or perhaps a filter that eliminates the same sentence within a certain period.
Yep.

But we need to use a flyspray to get it.

I will have a look at these spryfly things tomorrow and write two requests:

- one for enabling IP as 'send WPT to ...' ,
- one for enabling WPL receipt and display,

I think one more for allowing GGL or RMC to AIS sentence conversion. This has been discussed before too. (To enable a second object to be tracked).

Would be nice to have a bit more advanced nmea multiplexer on OpenCPN too - if anything future networking will be more advanced rather than less.

Cheers,
b.
barnakiel is offline   Reply With Quote
Old 18-12-2016, 23:37   #28
Registered User

Join Date: Oct 2012
Location: Brighton, UK
Boat: Westerly Oceanlord
Posts: 513
Re: Sending waypoints/routes over IP

Quote:
Originally Posted by barnakiel View Post
TCP
I see the issue is, if not resolved then pinned down. My question was actually about software used on the router for NMEA forwarding. kplex runs on routers and doesn't echo back data on the same connection you receive it unless you tell it too ("loopback=yes") so I was wondering if the problem was that you were using udp broadcast but the AP was configured for wireless isolation so clients couldn't see each other.

...but if that part of the puzzle is resolved then great...
muttnik is offline   Reply With Quote
Old 19-12-2016, 08:00   #29
Registered User

Join Date: Aug 2009
Location: between the devil and the deep blue sea
Boat: a sailing boat
Posts: 20,437
Re: Sending waypoints/routes over IP

Quote:
Originally Posted by muttnik View Post
I see the issue is, if not resolved then pinned down. My question was actually about software used on the router for NMEA forwarding. kplex runs on routers and doesn't echo back data on the same connection you receive it unless you tell it too ("loopback=yes") so I was wondering if the problem was that you were using udp broadcast but the AP was configured for wireless isolation so clients couldn't see each other.

...but if that part of the puzzle is resolved then great...

For parallel networking I use any software. For muxing and interfacing either ser2net or kplex.

This particular problem I had was indeed kplex not sending back until I implicitly declared loopback on TCP interface.

Interestingly, as you can see in comment from Pavel, even when the WPTs get thru ... they do not get displayed in OpenCPN. For OpenCPN does not dispaly incoming WPLs...

So we have now WPTs flying from our laptops to our GPS units, but not the other way round! Life ;-)

Cheers,
b.
barnakiel is offline   Reply With Quote
Old 19-12-2016, 08:11   #30
Registered User

Join Date: Jan 2015
Location: Victoria BC
Boat: Rafiki 37
Posts: 1,390
Re: Sending waypoints/routes over IP

Quote:
Originally Posted by Hakan View Post
alctel....
Well, there's a way although not really straightforward. I agree there's no way to convince the waypoint/route manager to contact a network port instead of a serial COM port. That would be a feature request using Flyspray but I tested and solved it this way: (I'm on Windows so all refers to that.)
I've one OCPN main instance open, here I call it O-main. I also have a OCPN portable instance open. How to set up a portable instance for simultaneously use with a O-main on Windows is another story. If you don't know pls read wiki or ask me here. I'll call that instance O-port.
I also used a free virtual serial port app set up as a COM1 bridge to COM2.
I had the waypoint to be copied in my O-port. From there I sent the WP to COM1.
In O-main I used two connections, COM2 for incoming messages and a Net-IP-UDP connection for output, see my screen shot below. On the same image you can see what happened in the O-main NMEA debug window. A WP coming in on COM2 and directly reflected out to the IP-ort. (Although in opposite order but that's the same second so windows print can be randomly.)
If your Simrad is not listened to UDP you have to set the IP connection as TCP instead.
As said not the most convenient way and there can for sure be other solutions as well. But this is one way. And I do agree OCPN is great.
Håkan
I tried this last night quickly and couldn't get it to work - will give it another shot tonight, and will keep an eye on the debug console.

For the 'main' opencpn, do you do any string filtering?

Oh, and thanks for the great suggestions/feedback everyone!
__________________
www.saildivefish.ca
alctel is offline   Reply With Quote
Reply

Tags
route


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
Sending Routes to serial ports OPENCPN moteje OpenCPN 1 26-09-2013 04:25
Sending Routes to serial ports moteje OpenCPN 0 25-09-2013 23:35
Sending WPT and Routes to Nasa Clipper Repeater Frankiez OpenCPN 5 20-09-2011 10:25
Garmin and Uploading Waypoints / Routes unbusted67 Marine Electronics 5 04-05-2011 11:35
Routes Leave Permanent Waypoints on Chart yachtvalhalla OpenCPN 18 22-12-2009 21:42

Advertise Here


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


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.