PMK2DUP

From DynonDocs
Jump to: navigation, search

If you are an advanced user or software developer, you can use the PMK2DUP command line utility to create User Waypoint files from sources other than Google Earth. You will need to convert source data to a simple XML format as described below, and then run it through the PMK2DUP utility to create the User Waypoint DUP file.

First, you need to install the Dynon USR Export utility. Once you have installed it, you will find the command line utility here:

C:\Program Files\Dynon Avionics\Dynon USR Export\PMK2DUP.exe

(or in "\Program Files (x86)" if you are running 64-bit Windows)

Copy this file to somplace more convenient, e.g. C:\Temp.

Consider the following input file named "In.pmk" also located in C:\Temp:

<?xml version="1.0" encoding="UTF-8"?>
<kml xmlns="http://www.opengis.net/kml/2.2" xmlns:gx="http://www.google.com/kml/ext/2.2" xmlns:kml="http://www.opengis.net/kml/2.2" xmlns:atom="http://www.w3.org/2005/Atom">
<Document>
	<Folder>
		<name>Dynon</name>
		<Placemark>
			<name>WP001</name>
			<description>KRNT
Altitude: 32 - 4500
			</description>
			<LookAt>
				<longitude>-122.2157</longitude>
				<latitude>47.49314</latitude>
			</LookAt>
		</Placemark>
		<Placemark>
			<name>WP002</name>
			<description>Begin Cruise
Altitude: 4500 - 4500
			</description>
			<Point>
				<coordinates>-122.2299,47.58273,0</coordinates>
			</Point>
		</Placemark>
		<Placemark>
			<name>WP003</name>
			<description>Begin Descent
Altitude: 4500 - 606
			</description>
			<LookAt>
				<longitude>-122.2604</longitude>
				<latitude>47.77481</latitude>
			</LookAt>
			<Point>
				<coordinates>-122.2604,47.77481,0</coordinates>
			</Point>
		</Placemark>
		<Placemark>
			<name>WP004</name>
			<description>KPAE
Altitude: 606
			</description>
			<LookAt>
				<longitude>-122.2816</longitude>
				<latitude>47.90699</latitude>
			</LookAt>
		</Placemark>
	</Folder>
</Document>
</kml>


To convert this to a DUP file, use the following command line:

C:\Temp>PMK2DUP Out.dup In.pmk

The command syntax is:

PMK2DUP [path]<outfilename> [path]<infilename> [[path] <infilename> ...]

where <outfilename> is the filename of the output file (please append the .DUP extension), and <infilename> is the filename of the input file. If you specify more than one input file, all will be added to the DUP file.

Line breaks inside the <description> element will be preserved for display on SkyView, which helps for formatting things neatly on the display.

Disclaimer: command line use of the PMK2DUP utility is currently unsupported. Use at your own risk. If you find a bug in it, we'd like to hear about it, but we do not promise to investigate or fix it. This utility creates only User Waypoint DUP files and has no capability to generate other types of DUP files.