Configure Xastir with Garmin 530HCx Friday, March 22, 2013 6:39 AM

1. Install Oracle Virtual Box Art Botterel helped me download and install VirtualBox from this link: https://www.virtualbox.org/ .

2. Install Virtual Machine with Xastir Lee Bengston built virtual machine on Squeeze which can be downloaded via the link below. http://71.171.111.149:1080/xastir/Xastir‐Debian6‐VBox.7z

We unzipped and double‐clicked Lee Bengston's prepackaged virtual machine. We were able to configure the station and see APRS data over the Internet right away on APRS.fi. This new VM has VBoxLinuxAdditions installed, and no serial port assigned so that the user can assign the applicable one. user account (username = user, pw = linux) to automatically log in. In this case, there is also a root password, which is "xastir".

2. Connecting the Garmin and Kenwood

1. Connected the Garmin Rino 530HCx to the USB port on the back of the computer, turned it on with Windows XP running but without Linux or Xastir running. It appears in device manager as “Garmin USB GPS” as below:

When I right click on properties it shows as being at Location O (USB Device) as below

(((Note: My Kenwood THD72A uses COM4 for Outpost and with the Kenwood MCP‐4A configuration software. I configured the Kenwood as shown in the Kenwood configuration notes page and it appears to be able to receive packet information on station position in the field. Not sure I can send that data yet and haven’t had much time to test. Right now focusing on the Garmin. AJM)))

2. Start Oracle VirtualBox Manager to configure the USB interface. a. Windows asks to find a driver for the attached device. I wasn’t sure where to point windows and pointed it to the folder with the Garmin USB driver here: :\Garmin\USB_Drivers but it doesn’t seem to make sense that a windows driver would work for linux. Maybe it doesn’t matter where you point it but it does seem to find a driver of some kind allowing it to talk to virtual box. Not sure if there may be a

Xastir Page 1 problem introduced at this step, but a driver appears to install and the entry above in device manager above disappears and an entry “Virtual Box USB” appears under Universal Serial Bus Controllers as shown below. Note that certain versions of linux should have a garmin driver associated with it as per this source: http://www.lovelysystems.com/data‐transfer‐from‐gpsmap‐60csx‐to‐a‐linux‐pc/ “According to the GPSMan manual linux kernels > 2.6.11 ship with a driver for garmin devices (http://sourceforge.net/projects/garmin‐gps/)“

I am not sure if Virtual Box is using these drivers or something else. Anyway, when I start Virtual box the windows device manager changes as below:

b. In Virtual Box Manager: 1. Click on Settings 2. Click on USB: a). Enable USB Controller is checked b). Under USB Device Filters I see two entries are checked: Silicon Labs CP2102 USB to UART Bridge Controller [0100] ((This is the Kenwood TH D72A – ignore this for the moment) Unknown device 091E:0003 [0001] ((This is the Garmin 530HCx))

Xastir Page 2 (((3. I do not think that a Serial Port needs to be configured for use with the Garmin 530HCx. I do think you need to do so for the Kenwood D‐72A. The D‐72A uses COM4 for many programs such as Outpost and the Kenwood MCP‐4A programming software and while it uses a USB cable connector I understand that there is a serial to USB chip in the D‐72A and the USB is not truly a USB connector but a serial type of connection. I configured a serial port in the following manner for the Kenwood D‐72A as below:

4. I run the Xastir Debian 6 XFCE Virtual Machine and open a terminal window by clicking on the icon at the bottom of the screen that shows a small black desktop with a cursor. Type “gpsman” at the command prompt and configure this program for the Garmin Rino as per the modified instructions pasted below from the GPSMan developer site. These instructions are for a different serial GPS unit and I have to modify them to the USB Rino. Be sure to see my notes indicated by "((( Note here AJM)))": http://www.words2u.net/pmwiki/?n=GPSMAN.4InterfacingWithGPSUnits

Communicating with the GPS Unit: Once you set up GPSMan (which is done the first time it is run), your interface changes. From

Xastir Page 3 now on, when you run it, three windows will open - Lists, Map, and GPS Receiver. Let's take a look first at the Receiver interface, which is used for connecting the computer to the GPS unit, uploading and downloading data to/from the GPS, and selecting some settings.

Receiver Interface • Device - lists the device file used to communicate with the GPS. In my case, it is the serial port, /dev/ttyS0. (((NOTE that in my case the Rino is on USB0 therefore use /dev/ttyUSB0 AJM))) • Linux will read and write to this device. The Baud rate is the speed of communication. The baud rate button can only be used for serial connections with the Garmin protocol. • Protocol - this lists communications protocols with the GPS. In the case of Garmin Geko 201 and eTrex (which is what I am using with a serial connection), the Garmin protocol is the best choice. You have to set this protocol on the GPS unit as well, in Setup - Interface - I/O Format. For USB GPS units, the Garmin USB protocol communicates much faster and more reliably, but you must have a Linux kernel with the garmin_gps driver. To check if you have this driver enabled try to find it in the kernel drivers. First, type uname -a to see your active kernel (in my case, it is 2.6.24-19-generic). Then check in /lib/modules/2.6.24-19-generic/kernel/drivers/usb/serial/ if the driver named garmin_gps.ko is listed. ((((I have used the Garmin USB protocol on GPSMan and on the Garmin. AJM)))) • Real Time Track Log - this is used to collect data in real time, for example during a car ride, with the GPS connected to a laptop. Since I do not have a Linux laptop, I am going to defer details till later. (((I don't know if this needs to be enabled???))) • Offline - this button indicates whether GPSMan is communicating with a GPS. Moving the mouse over the button will change the label to 'check'. If a GPS unit is connected to the computer, clicking the button will check the communications, and when contact is established, display a green 'online' label. At this point, the 'Turn Off' button will be activated, and would allow the user to turn the GPS off. If there is no connection to a GPS unit (cable is not installed, protocol is not Garmin, or GPS is turned off), the 'Turn Off' button is disabled and the 'offline' button does not change. The connection to the GPS is also closed if there is a change of protocol. (((I don't know if turning the GPS online in GPSMan here will goof things up if Xastir tries to use GPSMan internally or vice versa if it might be required to do so. AJM))) Recapping: To communicate with your GPS unit, connect the serial or USB cable to both the computer and the GPS, turn the GPS on, launch GPSMan, and click the offline button. GPSMan will check the connection and attempt to communicate with the device. If successful, the 'offline' label on the button will change to a green 'online' label, and the 'Turn off' button will be enabled. Once communications with the GPS have been established, the two rows of buttons at the bottom of the window are used to transfer data to and from the GPS. This will be discussed next. Clicking the (now active) Turn Off button will turn off the GPS unit and return the 'online' button to 'offline'. (((So far with the settings above this seems to work for my Rino)))

Pasted from

and here: http://www.lovelysystems.com/data‐transfer‐from‐gpsmap‐60csx‐to‐a‐linux‐pc/

Data transfer from GPSmap 60CSx to a linux PC

Last month Lovely Systems and Telesis sponsored me a brand new Garmin GPSmap 60CSx - thanks a lot! During evaluations for the Loccata project I previously could play around with a Garmin eTrex

Xastir Page 4 Summit. This is gonna show you a way to transfer data such as waypoints or tracks from your garmin device to your PC and the other way round. There might be nicer applications or easier solutions for this, please let me know about them. Connecting the device with your PC According to the GPSMan manual linux kernels > 2.6.11 ship with a driver for garmin devices (http://sourceforge.net/projects/garmin-gps/) To see if you're having the drivers installed and can connect to your GPS device plug in the cables, whatch your syslog tail -f /var/log/messages and power on your device. You should see something like: usb 3-2: new full speed USB device using uhci_hcd and address 3 usb 3-2: new device found, idVendor=091e, idProduct=0003 usb 3-2: new device strings: Mfr=0, Product=0, SerialNumber=0 usb 3-2: configuration #1 chosen from 1 choice usbcore: registered new driver usbserial drivers/usb/serial/usb-serial.c: USB Serial support registered for generic usbcore: registered new driver usbserial_generic drivers/usb/serial/usb-serial.c: USB Serial Driver core drivers/usb/serial/usb-serial.c: USB Serial support registered for Garmin GPS usb/tty garmin_gps 3-2:1.0: Garmin GPS usb/tty converter detected usb 3-2: Garmin GPS usb/tty converter now attached to ttyUSB0 usbcore: registered new driver garmin_gps drivers/usb/serial/garmin_gps.c: garmin gps driver v0.23

Now you also know that your device has been attached to /dev/ttyUSB0: usb 3-2: Garmin GPS usb/tty converter now attached to ttyUSB0

The CD included in the package of the 60CSx only comes with USB drivers for windows. If you don't have the driver you can download it on the sourceforge project page http://sourceforge.net/projects/garmin-gps/ Luckily i already used a Garmin eTrex Summit before and had it's driver installed previously. These drivers also worked for connecting the 60CSx.

Permission settings

Note: If you want to upload data (such as waypoints or tracks) to your device you need to change the permissions.

By default users must not read or write from/to the device: frisi:/ # l /dev/ttyUSB* crw-rw---- 1 root uucp 188, 0 Dec 29 10:00 /dev/ttyUSB0

We change the permissions so ever user can read and write to the device: frisi:/ # chmod o+rw /dev/ttyUSB0

Other maybe more elegant solutions can be found here : http://www.gpsbabel.org/os/Linux_Hotplug.html (((NOTE I pasted this link below. Perhaps the trouble I am having has to do with permissions in terms of reading and write from/to the device??? I do seem to be able to )))

Hotplug vs. Garmin USB on Linux There are two common hazards with Garmin USB on Linux. About the middle of 2005, most distributions started shipping with a driver called 'garmin_gps' that claims a USB Garmin device and makes it accessible via a serial port. If you want to use that driver and it actually works for you (a depressingly uncommon situation) this is OK and you can access the device as 'ttyUSB0' or whatever that driver names your dev node. If you want to use GPSBabel's own very well supported USB code and access it as 'usb:', you must remove that driver via rmmod and probably prevent it from loading again. It is our strong recommendation to use the latter approach. By default, only root can access the USB devices directly as we do for the 'usb:' case. It is possible to have the system automatically set the permissions on a USB device when it's detected. This eliminates the need for GPSBabel to run as root when using a device controlled by libusb, such as the Garmin 60CSx, VistaC, or LegendC units. The steps to address both of these issues are simple for an admin. (((Note I am not sure how to log in as an admin into my build of Xastir or whether this can be done automatically or would make any difference????))) The locations of files may vary between distributions and even versions, but the following example may hopefully help inspire you: Fedora Fedora Core 2 Fedora Core 3 Fedora Core 4 • Edit /etc/hotplug/usb.usermap and insert the following: # Garmin garmin 0x0000 0x091e 0x0000 0x0000 0x0000 0x00 0x00 0x00 0x00 0x00 0x00 0x00000000 • Create a file named /etc/hotplug/usb/garmin to adjust ownership and permissions to your needs. A single user workstation may find a very simple policy to look like: #!/bin/bash

if [ "${ACTION}" = "add" ] && [ -f "${DEVICE}" ] then

Xastir Page 5 # Uncomment next line for FC4 to remove conflicting kernel module # rmmod garmin_gps chmod 666 $DEVICE fi • Make that executable with chmod 755 /etc/hotplug/usb/garmin. That's it, you should now be able to use your USB Garmin. Just use "usb:" as your filename instead of an entry in /dev. For example: gpsbabel -t -r -w -i garmin -f usb: -o gpx -F blah.gpx will make a backup copy of the tracks, routes, and waypoints for you. Fedora Core 5 Fedora Core 6 Fedora Core 7 Fedora Core 8 FC5 replaces hotplug with udev, rendering ineffective the above attempt to keep the kernel driver peanut butter out of our chocolate. For FC5, the correct approach appears to be to add 'blacklist garmin_gps' to the end of /etc/modprobe.conf. If you modify the above, you can usually save yourself a reboot cycle by running /sbin/rmmod garmin_gps as root. If you want udev to create the devices so they are readable and writable by non-priveleged users, create a file /etc/udev/rules.d/51-garmin.rules with contents SYSFS{idVendor}=="091e", SYSFS{idProduct}=="0003", MODE="0666" Libusb must be in the range of version 0.1.10 to 0.1.12 in order for Garmin USB to work. Fedora Core 14 As above for FC5, but add blacklist garmin_gps to the end of /etc/modprobe.d/blacklist.conf instead. SuSe SuSe 10.1 See instructions for Fedora Core 5. SuSe 10.1 is reported to need a manual upgrade of libusb. Ubuntu Dapper Drake To keep the OS from loading the (frequently dysfunctional) kernel garmin_gps module, edit /etc/modprobe.d/blacklist and add the lines # stop garmin_gps serial from loading for USB garmin devices blacklist garmin_gps To allow the USB devices to be read and written by a non-privileged user, create a file named /etc/udev/rules.d/51-garmin.rules with the following contents:

SYSFS{idVendor}=="091e", SYSFS{idProduct}=="0003", MODE="666" Ubuntu Edgy The instructions above for Dapper Drake seem to apply, but another peril awaits users of Ubuntu 7.04 with kernel 2.6.20-15. This product ships with a kernel built with CONFIG_USB_SUSPEND which apparently breaks the libusb support that we need. Recompile your kernel without this options and/or contact your support provider for current status or help. In April of 2008, Babel-head Bill Wohler reported that Debian kernel 2.6.24 included a fix for this problem. Ubuntu Feisty Roger Dean reports that in June 2007, Ubuntu released a downloadable update for Feisty 7.04, kernel 2.6.20-16. This seems to fix the problem described above on his system at least. (This was written 2006-May-16 Please let the gpsbabel-misc list know if there is any progress on this.) Ubuntu Gutsy There has been a lot of confusion on the GPSBabel list about Gutsy. Gutsy apparently already includes the entry in blacklist, so that should be helpful. Of course, if you're building your own static kernels, you must remember to deconfigure garmin_gps. Some users report the 'Edgy' problem above has been fixed and some are claiming it's not. Some report that the rules syntax given above for Dapper Drake work successfully and othere report that USBSYSTEM!="usb_device", GOTO="garmin_rules_end" ACTION!="add", GOTO="garmin_rules_end" ATTRS{idVendor}=="091e", ATTRS{idProduct}=="0003", MODE="0660", GROUP="plugdev" LABEL="garmin_rules_end" is required in the udev rules file. If you can help clarify this, please contact us. Ubuntu Hardy It appears that Hardy is more like Dapper than Gutsy. Create /etc/udev/rules.d/51-garmin.rules with SYSFS{idVendor}=="091e", SYSFS{idProduct}=="0003", MODE="666" and do a sudo udevcontrol reload_rules. Debian To keep the OS from loading the kernel garmin_gps module, edit /etc/modprobe.d/blacklist and add the lines # stop garmin_gps serial from loading for USB garmin devices blacklist garmin_gps To allow the USB devices to be read and written by a non-privileged user, create a file named /etc/udev/rules.d/51-garmin.rules with the following contents: SYSFS{idVendor}=="091e", SYSFS{idProduct}=="0003", MODE="666", GROUP="plugdev" Mandriva To keep the OS from loading the kernel garmin_gps module, edit /etc/modprobe.d/blacklist-mdv and add the lines # stop garmin_gps serial from loading for USB garmin devices blacklist garmin_gps To allow the USB devices to be read and written by a non-privileged user, create a file named /etc/udev/rules.d/51-garmin.rules with the following contents: SYSFS{idVendor}=="091e", SYSFS{idProduct}=="0003", MODE="666", GROUP="plugdev"

Pasted from

Applications

Recherche I've been doing quite some research on applications to load data to and from my garmin gps

Xastir Page 6 device. Some of the links i found are listed on http://del.icio.us/frisi/gis. The apps i'll describe in this section are GPSMan and GPSbabel. I'd love to have a kde application for this, so i considered using GRASS GIS (which i did not yet try out). KGIS started in 2002, had no development the last years, so i don't think this is very promising.

GPSMan You can download GPS Manager from it's official website http://www.ncc.up.pt/gpsman/. GPSMan is very well documented, a PDF describing it's features, installation and usage and giving information on the data types waypoint, track, route and group can be found on the website too. Start GPS Manager by providing the device your garmin is located at: frisi@frisi:~> gpsman usb=/dev/ttyUSB0 &

You will see the main window with buttons named Data, GPS receiver, Map, Definitions and Options. Configuration First configure GPSMan using the Options menu. • set the GPS Model to Garmin • in Receiver parameters ○ set the Default protocol to Garmin NOT Garmin USB (((Note: I have not done the procedure in the above section. I can't get this to run when I do Garmin protocol but can get it to talk when I do Garmin USB. I don't understand why they recommend thisAJM))) ○ check accept all characters to allow spaces and other chars too (eTrex Summit could not handle these, the 60CSx can do) (((I did do this))) ○ you can leave the other settings untouched • in Serial port and files set the serial port to /dev/ttyUSB0 or whatever device you got in Connecting the device with your PC

These are the must-have settings to connect your device. You might want to have a look at the documentation for more information on the other settings.

Transfer data To download Data you can either invoke the Receiver window under the GPS receiver menu or use the menuitems in there (GPS receiver / get / ...). To connect the device hit the check button. If it got connected successfully it turns green and the label changes to online.

The GPS receiver menu allows you to connect to your device and up- and download data. To import waypoints simply click on WPoint in the get (download) area (this works the same for Tracks and Routes) If you want your waypoints to show up in the map check Display items on map (you can also change this for any item later) The downloaded items now show up in the Lists menu. It is accessible via Data / Lists but should pop up automatically when you start up GPSMan.

Note Read documentation on data (p. 20 and following in the pdf) to see what you can do with waypoints, tracks and so on

Save/export data To save your Tracklog to display it on maps, share it with friends or simply archive it for computing statistics later on, you can use the save and export functions.

Xastir Page 7 The Lists menu lets you manage, edit, import and export waypoints, routs and tracks. I don't know which is the standard format for sharing waypoints and tracks. GPX which is an XML format seems very promising to me but i don't know if GPSTrans, MapSend or Ozi are wider used. For the time being i use save instead of export to save the files in a gpsmap internal format to not lose any information when exporting.

GPSbabel GPSbabel is an application to convert spatial information given in a certain data and projection into various other formats. You can download the most recent version on the homepage http://www.gpsbabel.org. I'm using GPSbabel not only for conversions but also to upload waypoints of http://geocaching.com caches to my garmin. The format of these *.LOC files is geocaching.com-specific and supported by gpsbabel too: http://www.gpsbabel.org/htmldoc-1.3.0/fmt_geo.html I used gpsbabel to convert the file GCN8A0.loc and upload it to my garmin device: gpsbabel -i geo -f GCN8A0.loc -o garmin,power_off=0 -F /dev/ttyUSB0 to get a waypoint file you can use with GPSMan try something like: gpsbabel -i geo -f GCN8A0.loc -o gpsman -F GCN8A0-gpsman.wpt you can also download data from your device using gpsbabel, see http://www.gpsbabel.org/htmldoc-development/fmt_garmin.html for more details.

Outlook Now that i found a way to transfer data from my garmin to the PC, i want to play with this data and my GPS device a little more.

Statistics I'm interested in some statistical information on my bike tours such as distance, average speed, vertical meters up/down, elevation charts. GPSMan can do a lot of this already: In the Lists view double click a track. In the track menu that will pop up you can click the Compute button to get some statistical information and a menu for generating plots such as elevation sideview by time or by distance.

Maps GPSMan can display waypoints with different icons and tracks in a map (see screenshot).

GPSMan can also use maps in the background, but i need to find out how to obtain and use maps for this. There are also some online services that let you upload tracks and generate a map with your track. One of these is http://www.gpsvisualizer.com/map. There is a tutorial how to integrate a route in google maps on http://www.marengo- ltd.com/gps/.

Xastir Page 8 MapSource I did not yet play with the map support of the 60Csx (eTrex Summit did not have it). I need to check if there are any applications for linux, of if i can use it with an emulator. According to the Garmin FAQ garmin does not plan to ship mapsource for other operating systems than windows atm.

Eingestellt von fRiSi um 22:32

Labels: GPS, linux

Pasted from

But still get this error in Xastir:

Xastir Page 9 I can however track the positions of other Rino’s moving about in the field as shown here:

I just can’t get Xastir to see the position of the radio attached to the computer, but it does correctly plot the positions of the radio’s talking to it….

Do I need to hit PTT from the field radios to update their positions or will the base rino poll them at the interval selected?

This thread appears promising for my purposes: http://www.mail‐archive.com/[email protected]/msg03684.html

As does this one http://www.mail‐archive.com/[email protected]/msg02409.html

This thread indicates the Rinos should be polled at automatic intervals: http://www.mail‐archive.com/[email protected]/msg02398.html

Xastir Page 10 Other goal topo maps for Idaho saved on hard drive"

Xastir Page 11