Cruisers Forum
 

Go Back   Cruisers & Sailing Forums > Seamanship, Navigation & Boat Handling > OpenCPN
Cruiser Wiki Click Here to Login
Register Vendors FAQ Community Calendar Today's Posts Log in

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 11-06-2012, 15:23   #1
Registered User

Join Date: Jun 2012
Location: on SaltyPaws
Boat: Helia 44
Posts: 66
route_pi - Great Circle and Composite Routes

At the moment OpenCPN does not support plotting of Great Circle and Composite Routes. According to the documentation, it requires an external application. (Great Circle and Composite Routes | Official OpenCPN Homepage)

My plan is to close this gap, by writing a plugin for OpenCPN that enables plotting of Great Circle and Composite Routes directly via the Gui. Working from the source code of existing plugins I have coded a "Hello World" plugin, with both menu and config menu to Wxformbuilder form.

Currently I am working out how to add routes to OpenCPN. I have worked my way through ocpn_plugin.h, but I could not find a direct function to enter waypoints or routes into OpenCPN.

My next approach was to use the NMEA data stream to write a route to OpenCPN. I created a pair of virtual com ports, and recorded a route exported with OpenCPN to GPS. ($GPWPL,3734.013,N,02402.569,E,003*66 etc). I then played this NMEA data stream (which I had saved to file) back to OpenCPN with VDR plugin. Unfortunately OpenCPN did not use the NMEA data to plot the route.

Other than writing the route to GPX file, which the user than manually needs to open, I am running out of ideas to add a route to OCPN from the plugin API. Dave/Nohal/SethDarth or other developers: any ideas how to implement this? Thank you for your support

My code & NMEA text file is in github: https://github.com/SaltyPaws/route_pi
SaltyPaws is offline   Reply With Quote
Old 12-06-2012, 04:10   #2
Registered User

Join Date: Mar 2010
Location: Normandy, France
Boat: Flush Poker, 8.25m (Point Barre)
Posts: 340
Re: route_pi - Great Circle and Composite Routes

To my knowledge, this is not possible yet.

With 3.0 released, we can work on expanding the API to enable such features for future versions.

Maybe the new JSON feature could also help.
SethDart is offline   Reply With Quote
Old 12-06-2012, 09:24   #3
Registered User

Join Date: Jun 2012
Location: on SaltyPaws
Boat: Helia 44
Posts: 66
Re: route_pi - Great Circle and Composite Routes

Ok No luck with the current version of the API. Does it make sense to make a feature request for this API functionality or is this something you are working on anyway? Another API feature that would be nice to have, is to extract coordinates using a mouse click (we know the cursor position, but we cant catch a mouse click in the API, can we?)

A second question, on the NMEA route: Should OCPN be able to accept the routes using NMEA, or is this also something that has not been implemented?

If this is the case, I will proceed using the GPX file export route, and I will implement direct route plotting once the API has been updated.

I have decided I will also add SAR patterns to this plugin, as that would be very similar functionality.
SaltyPaws is offline   Reply With Quote
Old 29-07-2012, 14:15   #4
Registered User

Join Date: Jun 2012
Location: on SaltyPaws
Boat: Helia 44
Posts: 66
Re: route_pi - Great Circle and Composite Routes

An update on the status of route_pi. I have added Vicente's formulas for great distance calculations. I have also added GPX export capability. The (unpolished) plugin is now capable of exporting great circle routes. next I will add limited circle routes. Please have a look and let me know what you think.
SaltyPaws is offline   Reply With Quote
Old 07-08-2012, 13:19   #5
Registered User

Join Date: Jun 2012
Location: on SaltyPaws
Boat: Helia 44
Posts: 66
Re: route_pi - Great Circle and Composite Routes

Development update: Limited circle capability has been added. The plugin is quite functional. I will do some more cleanup of the code, add loxodromic routing and issue
SaltyPaws is offline   Reply With Quote
Old 07-08-2012, 23:26   #6
Registered User

Join Date: Dec 2008
Boat: Journeyman
Posts: 705
Re: route_pi - Great Circle and Composite Routes

FYI, the next beta release will do interactive Greate Circle routing using the standard routing tool. (Available now in the master branch)
JesperWe is offline   Reply With Quote
Old 23-10-2012, 10:39   #7
Registered User

Join Date: Jun 2012
Location: on SaltyPaws
Boat: Helia 44
Posts: 66
Re: route_pi - Great Circle and Composite Routes

Plugin has been issued on the plug ins page, functionality is additional to OpenCPN's even in the new version.
SaltyPaws is offline   Reply With Quote
Old 23-10-2012, 18:13   #8
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 17,766
Images: 2
Re: route_pi - Great Circle and Composite Routes

Pretty nice! Thank you.
rgleason is offline   Reply With Quote
Reply


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


Advertise Here


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


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.