Sailing Software Utilities for the PC

Over the last 15 years I've developed a number of software utilities to support my sailing activities.  These utilities range from an inventory and maintenance record keeper to navigation functions.  All of these early programs were developed using Visual Basic for Applications (VBA) as provided in MS Excel.  I used that development platform because it was included by Microsoft in the Office programs.  This also had the advantage of integration with the Excel workbook structure to maintain the various databases used by these utilities.  There are a number of limitations of this platform, which made me consider moving to the standard Visual Basic (now part of Visual Studio).
Two things have finally motivated me to make this move.

  1. Microsoft has released a fairly complete version of Visual Basic in Visual Studio Community, which they provide at no charge. 
  2. Although I have seen no announcements from Microsoft on the future of VBA, I fully expect them to drop support in some future release of Office.


So I have started looking to convert some of my VBA programs to Visual Studio (VS), but in the meantime I have developed a few small programs as teaching projects to allow me to develop some familiarity with VS.  These programs are still under development, but they are complete enough to provide me some useful functionality.  Others may not find them very useful.

Current list of programs and utilities:

GPX File Utility
The GPXFileUtility allows me to display and edit the contents of a GPX file.  GPX files have become the standard for most navigation programs for the exchange and backup of waypoint, route, and track records.  I use OpenCPN as my principal PC navigation software and it uses the GPX file format to export and import navigation data.  I use the track data from OpenCPN to create a visual record of many of my cruises on Sarah on this website.  Early on I discovered that little blips in Sarah's instrument network can produce erroneous track records in the GPX file exported from OpenCPN.  Correcting these errors was time consuming and tedious as it required paging through hundreds of trk records to find the ones in error.  So I developed the initial version of GPXFileUtility to provide a quick means of finding those errors and eliminating them.  I also included the ability to display and edit "wpt", "rte" and "trk" records in a GPX file.  Finally I added the ability to save the GPX file in other formats.  The program will convert a GPX file to a kml file for display using Google Earth or to a csv (Comma-Separated) file for import into programs that do not natively process GPX files.

Caveat: This program is really a quick and dirty implementation of a file editor.  It needs a lot of work, if not a re-write.  In the mean time it has been useful to me so I've posted it on the web site.
The latest version of the program can be installed online HERE.
This a short YouTube video that shows how I use the GPXFileUtility to edit the contents of a GPX file.
For the past 8 years (since 2007) I have largely been cruising on the East Coast of the USA, and have been taking full advantage of free downloads of the NOAA Electronic Navigation Chart (ENC) and Raster Navigation Chart (RNC) libraries.  This is a fantastic service, which makes chart updates available within days of when a revised version has been created.  The only drawback is trying to determine when an updated chart is available and should be downloaded into my PC chart library.
So my second VS project was to develop a program to compare the contents of the latest versions of the NOAA Product Catalogs (xml files) to the charts on my hard drive.  The program identifies the charts on my PC for which NOAA has published an update and then downloads the updates and copies them into my PC chart libraries.  Early in the development of the program I added support for the U.S. Army Corps of Engineers (USACE) charts.

Shortly before I got the initial version of this program working, one of the developers associated with OpenCPN released a plug-in that does everything I was developing.  I almost abandoned this program, but it was still a good VS learning project so I finished the initial development.  Also developing this program has helped me to better understand how NOAA manages their chart library (see below).  Then I discovered there were a lot of chart management functions that could be performed by this software.  So ChartManager has become an ongoing development project.
The latest version of the ChartManager can be installed online HERE

Once the program has been installed it will check for updates every time it is started.  The user has the option to install or skip any update.  There is also an option on the Help menu to check for a program update should you skip the automatic check, but then decide to install the new version after all.  Eventually the auto check will be removed, and updates will only happen when requested by the user..
The current status of all program bugs can be viewed in a pdf file HERE.
The history of program updates can be viewed in a pdf file HERE.
The installation process will generate multiple warnings from Windows, your network security software and your browser that this application may be malware.  I plan to fix that in the future, but for now if you want to use this program you will have to ignore those warnings and consider this website to be a trusted source.
Also the program requires Microsoft .NET framework 4.5 or later, which means the program will not run under Windows xp or earlier OS.
ChartManager Video Tutorials on YouTube
I've created a series of tutorials on the various ChartManager functions and uploaded them to YouTube.
As new features are added to the program (or I discover a need) I will create more of these tutorials.  The ChartManager Help menu provides access to these tutorials via your browser.
Below is a YouTube overview of the ChartManager program
The following video covers getting started with the ChartManager program.
And the next video covers using Chart Collections (called Groups in the video)
With version an inventory of Paper Charts has been added to ChartManager.  This initial implementation does nothing more than support the entry and maintenance of an inventory of charts.  Future releases of ChartManager should add more functionality.  The following video provides an overview of this feature.
With version, the Export and Import functions were added to ChartManager.  The video states that these functions can be used to transfer data from one system to another.  That is not totally correct.  It can be used in that matter to replace the files of one system with those of another mirror system, but there is no capability to merge the files of one system with those of another.  That capability has not yet been added to the program.  Until that update has been implemented, the Export/Import functions provide principally a backup/recovery capability.  The backup/recovery is performed for the internal program tables (e.g., Collection criteria, Paper Chart Library contents, etc.), not the chart library.  Presumably you can just download the library in case of a system failure that causes the loss of the chart library.  If you are going to be without internet access for a period of time, then a normal system backup should be used to protect the library, or just copy the folder that contains the library to an external hard drive or thumb drive.
With version 1.7.5 ChartManager can import a shape in the form of a Google Earth placemark in a kml file to define the area limits of a chart collection.  The video below demonstrates this feature.
ChartManager is still very much a work in progress.  I spent a great deal of time trying to identify the best means to determine if there is a updated version of a chart available on the NOAA server.  Initially I just compared the date of the download zip file to last-modified date for the primary chart (*.BSB for RNC and *.000 for ENC) on my PC.  That worked OK, but then just before Jan 1, 2016 NOAA put up new zip files for all charts in the RNC catalogue.  I did not believe they really updated every chart on the same date, and I did not want to download the entire library if many of the charts have not been changed in any meaningful way.
Here is a link to the only documentation I can find on the NOAA site for what constitutes a RNC chart update.
Here is the equivalent page for ENC updates.
After several weeks of experimenting with various strategies for the RNC files I contacted NOAA and got an immediate and useful response.  I've left several strategies in place in the program so that a user can experiment with the download criteria themselves.  Here is a link to a document that describes how the various download criteria implemented by the program.  This document can also be downloaded from the Help menu in the program.

With version 1.6.4 most of the functionality I originally planned for is complete.  The program still needs tweaking and I'm sure I'll continue to find bugs as I expand the number chart libraries that the program manages for me.  Currently most of my development efforts are toward incorporating charts from sources other than NOAA and USACE.  I am currently working with four such sources, and all are limited to the RNC chart format.
  1. Sources that provide a chart catalog that can be downloaded and parsed as an xml file.
    These sources provide a catalog that roughly conforms to those of NOAA, but do not provide the information I need to integrate the charts from this source into the Chart Collections.  These sources allow individual charts to be downloaded in zip files, and can be kept current in the same manner as the program does for the NOAA charts.  However, the catalogs for these sources appear to not be generated or hosted by the national hydrographic offices, but by the developer of the Chart Download feature in OpenCPN.  The catalogs for the only sources in this class that I've found are hosted on the GitHub site, not a government site such as NOAA and USACE.  I assume the Chart Download developer is generating these catalogs on GitHub because the national website provides only links for individual charts, not a catalog - or at least not one in the NOAA format.  The two sources in this class that I've been working with are Argentina and Brasil.  Peru also appears to provide RNC charts for free online download.  I'm not investing a lot of development time on these catalogs as the ChartManager can get the Brasil and Peru charts directly from those country's web sites, and the Argentina RNCs appear to have disappeared from the Internet. 
  2. Sources that provide the entire chart library in a single zip file with no catalog of the contents.  In this case the program can download the charts and install them on a PC, but there is no catalog from which to select charts based on geographic criteria, nor from which to identify charts that have been modified and need to be updated in the library.  The only example I have of this source are the charts from New Zealand which provides a single zip file of the chart library that is updated annually as well as a separate zip file for monthly changes.  Although the charts cannot be individually downloaded, ChartManager does generate a catalog of the charts that can be used to create Chart Collections.
  3. Sources that provide an on-line catalog in the form of an HTML document.  The only examples I have of this type of source are Brasil and Peru, and several European countries that provide download links to their Inland Electronic Navigation Charts (IENC) on an HTML page.  Brasil offers what appears to be a complete catalog of RNC charts with links to zip files for most of the charts.  The charts without download links are identified as under development.  Peru provides only a few charts and they are compressed in the "rar" format for which I do not have uncompress utility.  The program will parse these HTML pages and create a local catalog of all charts available for download.  The downloading of the charts is done by a separate process, similar to the one for NOAA RNCs.  I started working with the IENC sources, but never competed it because each of the IENC sources uses a different presentation for the download links.  I didn't want to write code specific to each such country.  If ever return to Europe for a barge tour of the inland waterways as I did in 1985 and 1986, I will likely be motivated to compete this part of the program.
  4. Proprietary chart sources.
    These sources generate and sell charts derived from the various national hydrographic offices as value-added re-sellers.  There is normally no online catalog that can be downloaded, and even if one were available the individual charts must be purchased and are normally copy protected.  Currently my only source for this class of chart is NV, which are BSB/RNC charts.  Most of the other such sources produce vector charts rather than RNCs.  I have included support for SoftCharts in this class.  SoftCharts is a defunct chart source from back in the late 90's and early 2000's.  I have a small library of these charts from when I first started working with electronic charts, so I added them to the program.  Very few users will have a use for this feature.  I only use these charts for rough planning of ocean passages and for publishing chart images on this website (no copywrite protection on these charts).
For all these source classes that are implemented, the program will generate a local catalog from a combination of any catalog that may be available (GitHub or national) and the data in the downloaded charts.  With version the initial catalogs are being generated, but I have not started work on integrating these sources into the Chart Collections.
Once I've got the RNC processing under control, I'll start working on vector chart sources, although I suspect this will be limited to IENC (inland charts) as only the U.S. appears willing to provide direct access to their ENC library at no charge.
In the future I will look to see if S-63 encrypted charts can be added to ChartManager.
Planned future enhancements include the following:
  1. Provide for a selection of charts for download by geographical area.  That is the user can specify an area bounded 3 or more geographical points and the program will build a list of all charts that intersect with that area.  This was implemented in, but it is done entering specific coordinates into text boxes.  With version the program can process a kml file generated in Google Earth to define the geographic area of a Collection.  This is my implementation of a graphical interface for selecting a geographic area.
  2. Provide an Export/Import function for the chart collections such that they can be created on one system and transferred to another.  This was added in, but the import function is not complete.  It is really a backup/restore feature.  It should not be used to transfer the collections from one system to annother (the program does not prevent this).  That enhancement is still in the future.
  3. Add support for other chart sources for which there is no catalog on the Internet.  This development started in version 1.6.4 for RNC charts.  It is a long way from completion.
  4. Add support for other charts sources that provide a different catalog format or provide less information in the catalog than that provided by NOAA.  This development also started in version 1.6.4 for RNC charts.
  5. Add more criteria for the generation of Chart Collections.  For example, enter a planned route as a gpx file and have the program create a collection of charts that cover the route.  The route based collection was added in, but still needs a few enhancements.
Here is another program that really doesn't do much, it is just a means by which I can explore the contents of the USCG Light Lists.  That interest starting in 2012 when I was heading south on the AICW to Florida and stopped off at my brother's home in N.C. for the family Thanksgiving reunion.
My brother's home was just off Albemarle sound on Yeopim Creek.  The largest scale chart for this area is shown on the right.  If you click on the image to open it at full resolution you will see there isn't much detail on the chart, so I was paying careful attention to the channel marks, and my depth sounder.  Later when I displayed my track (red line) on the chart using OpenCPN I discovered the track did not go between the two day marks at the creek entrance.  However, I definitely went between them.  The track conforms to the other marks, so I don't believe it was an error in my GPS positions.  The track increment was 0.1nm so it is possible my position at the moment I was between the marks was not captured.  However the distance shown on the chart from between marks to my track is a little over 0.1 nm, so my passage would have had to have been very precisely timed to produce this discrepancy.  It appeared to me the marks were not correctly plotted by NOAA on the chart.
Track on Entering Yeopim Creek
After I developed the ChartManager program described above, I was interested to see if NOAA or the USCG had ever corrected the position of the marks on this chart.  I had the latest version of this chart, but I had nothing to compare it with to see if the marks had been moved.  I no longer had the track file.  I wanted to plot the marks on the chart using the positions in the latest USCG Light List.  I noticed that the USCG web site publishes the weekly updated light list as an xml file.  I thought I could just convert the light list xml file to a gpx file and have OpenCPN plot the current positions of the marks as waypoints.
On the right is a screen capture of the opening form for the LightListManager program.  The small list box on the left side of the form provides a list of Light List volumes published by the USCG based on the USCG District.  I have selected district 5, which covers the mid-Atlantic region and the program has populated the form with all of the lights in that light list volume.  At the bottom left corner of the form is the "Save to GPX" button that will generate the light list as a gpx file.
The Light List Manager Showing Dist. 5 Lights

The Filtered Light List Saved to a gpx File
The screen capture on the left shows the secondary form that is used to generate the gpx file (this form is no longer part of the program, GPX export is done from the main form).  There are nearly 9,000 lights in this list, so I don't want convert the entire list.  Instead I have set a filter for the area around Yeopim creek (red circle).  When I clicked the "Start" button the program generated the gpx file with the file name shown in the msgbox (red arrow).  This filter limited the number of waypoints to 44.  The program will generate up to 100 (now 1,000) waypoints in a single file.  If the filter (or no filter) selects more than the file limit, multiple gpx files will be created.
I then imported the gpx file into OpenCPN and took the screen capture on the right.  The position of the lights from the light list are shown as waypoints on the chart.  You'll have to click on the image to display it at full resolution to see how the light list waypoint positions line up with the marks on the chart.
It appears the light list positions the marks a very small distance to the east of the charted positions.  Maybe that difference puts the marks close enough to my track for the 0.1 nm increment to miss my position between the marks.
So it appears the two day marks are accurately positioned in the light list.  There is no commercial traffic on Yeopim Creek, just fishermen and yachties, so if there were a discrepancy with the charted position of these marks it would likely never be reported to the USCG or NOAA or they might determine it was an insignificant discrepancy.

NOAA Chart with the Light List waypoints
I've made a number of enhancements to the program since the original use described above, but it still is just a display and export utility.
Although the program doesn't do much, if you are interested in playing with it, you can download and install it here.  
A User Guide is available here.  This guide is currently a work in progress and is incomplete.
A pdf file containing the update history of the program and a list of resolved and unresolved program bugs can be viewed here.  Both the User Guide and Update History can be displayed from within the program from the Help menu.
I've also started to document some of the uses for the program on a separate page.
Here is a video that provides an overview of the program functions.
The video below describe how to use Google Earth to filter the light lists to a specific geographic area.
The video below demonstrates the documentation that has been added to program on the Characteristics and Structure information provided in the USCG Light Lists
The video below shows how I use this program to maintain the latest data for the lights and marks on the electronic charts
This video demonstrates the Light List Radar program feature
The next video covers using LightListManager to assist in the navigation of an unfamiliar and uncharted inlet.
With regard to the export of the Light List entries to a GPX file as waypoints, the program by default uses the OpenCPN user icons provided by SV Revelations as the waypoint symbols.  To see these waypoint icons in the OpenCPN display, you must first download the icons and install them per the instructions on the OpenCPN website at  If you choose to not implement the user icons in OpenCPN or you use a different chart plotting system, the waypoints should display with the default waypoint symbol for whatever chart plotter you use.  In the future I plan to allow users to specify the waypoint symbols based on those available in the users chartplotter, OpenCPN or other.
Although not demonstrated in any of the videos above, the Radar Display can plot AIS targets if an AIS receiver or transponder is connected to the NMEA 183 network.  Until I implemented that capability in the LightListManager program I was not aware of how many Aid-to-Navigation (AtoN) targets are being broadcast by the USCG.  Most of these appear to be synthetic AIS targets showing the location of a physical light, but broadcast from a local USCG base station, rather than an AIS trasmitter attached to a light. I expect most of these AtoN broadcasts are associated with major commercial waterways.  Jacksonville, FL, where Sarah has been berthed for the past 4 years, is a major port and the St. John River is a major commercial waterway, so many of the critical lights (STJ sea buoy, jetty marks and range lights) are AtoN targets.  The AtoN broadcasts may be coordinated with vessel traffic on a waterway.  Normally the only AtoN targets I see on the St. John River are near the entrance.  Recently I noticed many more targets showing up for a few hours and then stopping.  I'm guessing a container or cruise ship was entering or leaving the St. John during that period.  To me, one obvious use of the AtoN broadcast would be to identify the location of crtical marks for uncharted inlets, such as the St. Augustine Inlet featured in the video above.  However the only AtoN target I have seen for this inlet is the Tolomato River #60, which marks the intersection of the inlet and the AJCW.  That mark is charted.  Because I have not left the Ortega River since 2014, I may be too far from the USCG base station that broadcasts those AtoN targets.  The targets I do receive appear to be sent by the base station in Jacksonville, Fl, about 5 nm from my berth on the Ortega River.
Previously I was aware that the USCG did provide AtoN AIS target broadcasts, but I had never noticed any on my chart plotter displays.  That may be because this is a recent implementation by the USCG and also because the target icons are displayed on top of the existing chart icon, making them hard to distinguish.  I suspect the main purpose of these broadcasts is to display the lights on a real radar display rather my psuedo radar display.  Unfortunately my 15 year old Raymarine radar display (C120) does not recognize the AtoN message type and they are not shown on the chart and radar displays.
Although I have developed several programs such as the LightListManager as aids in the navigation and operation of a small vessel, a secondary purpose is as a learning tool for myself.  This is one example of such a learning tool.
As just an exercise to see how many placemarks Google Earth can handle, I imported the contents of all USCG Light List Volumes, each entry as a separate placemark.  The result is the screen capture on the right (you'll need to click on it view the image at full resolution).  I wanted to make it a movie zooming from Sarah's berth in the Ortega River to cover all of N. America and then pan to the territories in the Western Pacific, but that was a bit much for GE.  Instead I captured the N. America still image with the Hawaiian Islands on the far left of the image.  Not shown are the lights in the W. Pacific (Guam, Samoa, Saipan, Tinian, etc.)
Anyway, it provides a decent perspective on just how many lights, marks and buoys the USCG keeps track of.
If you look closely at the image above you will see a couple of placemarks in Ontario, Canada.  Those are Private Administered (PA) marks not maintained by the USCG, but included in the light list.  The coordinates for these marks are in error and should be located in Lake Superior.  Apparently the USCG cannot change any of the data for thse PA entries in the Light List and must get corrections from the responsible agency.  That takes a long time.
On the left is a screen capture of the plotted location of an oil rig RACON mark.  The plotted location is in Tibet, the oil rig is in the Gulf of Mexico.
The video below shows how the Lockwoods Folly Inlet channel has changed in the last 25 years.  LightListManager allowed me to add channel marks to the Google Earth images.
NMEA 183 Input Display
I seem to be in a rut of producing programs that don't really do much, but are good learning exercises for myself.  This program provides a windows form to display the NMEA 183 input traffic on a computer.  Ever since I moved to Win7 I've missed the HYPERterminal program that was a very useful tool to debug and validate a connection to an on board NMEA 183 network.  This wasn't a big loss as most PC-based Chart Plotting programs (e.g., OpenCPN) provide a window that displays the raw NMEA 183 input.  However, I've wanted to add an NMEA interface for some of the other software I've developed (e.g., OffShoreNavigationVBA),so I decided to build a simple program to listen to the NMEA 183 computer port and display the traffic received.  NMEA183Input is the result of that decision.
Currently the program produces just the form shown above.  In the upper left hand corner are two drop down boxes to configure the NMEA 183 port.  The select COM port combobox contains a list of all COM ports configured on the system.  If there is only one COM port configured it will be automatically selected as shown in the screen capture above.  The combobox below that configures the Baud Rate of the selected port.  When both selections have been made, the Listen button at the bottom of the form becomes active.
In the screen capture above I have specified a Baud Rate of 4800 and clicked the Listen button, which has now changed to a Stop button to cease the display of NMEA 183 data.  In this case the program was run on my development machine, not my navigation PC, and the only NMEA inputs are from a GPS puck connected to one of the USB ports.  So there is no data from any navigation instruments, nor any data for the active navigation.
The Talker ID text box is updated with the ID from each sentence received.  The GPS data is updated by the contents of any RMA, RMB, RMC, GGA or GLL sentence received.  If there were any depth, wind or knotmeter instruments attached to the network, the data from those sources would be displayed in the Instrument Data section.  Similarly if a navigation route is active the contents of the RMB, BWC, and BWR sentences would be display in the Navigation Data section. 
The check boxes on the lower left side of the form can be used to change the units of the displayed values.  The linear units can be displayed in Feet and Nautical miles, Metric values or in Fathoms and Nautical Miles.  Headings and courses can be displayed as True or Magnetic (if one of the NMEA talkers provides the variation for the current area).  Finally the position data can be displayed in minutes and tenths of a minute, or seconds and tenths of a second.  The default values are selected in the screen capture.
I'm not sure what, if anything I'll do with this program.  I just wanted to learn how to set up and received serial data over a COM port, and parse the NMEA 183 sentences received.  That has been accomplished.  Anyone wishing to play with this program can do so by downloading it here.
I wrote another program to test my NMEA parsing routines that accepts input from a text file or from typed or pasted text.  I use this program (NMEAParse) to identify problems within the parsing code, which is used by other programs that accept NMEA 183 input, This program does not accept input from a serial port, but only from a file or data entry.  I use the NMEAInput program above to capture the NMEA data stream to a text file, then use the NMEAParse program to verify or debug the parsing code.  Again not much use to anyone but myself.  It can be downloaded here.