# **Using the GSMCAD program with GPS for data collection in the field and as a quick and efficient way of creating ARC/INFO geologic map coverages**

## 

## Van Williams

U.S. Geological Survey

Box 25046

Denver, Colorado 80225

Telephone: (303) 236-1289

Fax (303) 236-1289

# Introduction

GSMCAD is a Microsoft Windows program designed specifically for field
and office compilation of geologic maps. It was developed by the U.S.
Geological Survey for in-house use and is made available to the general
public for a nominal charge as Open-file report 96-007 (Williams and
others, 1996). It can also be downloaded for free on the internet at URL
http:/ncgmp.cr.usgs.gov/ncgmp/gsmcad/gsmcwww.htm. Program documentation
is in the form of a Windows help file, GSMCAD.HLP.

Line and point data can be entered from a digitizing tablet, by drawing
on screen with a mouse, by reading in a table or DXF file, and by
connecting to a GPS (global positioning satellite) radio receiver. The
maps and drawings created can be plotted on an inkjet or a pen plotter,
printed on any Windows-compatible printer, or exported to DXF files or
ARC/INFO coverages.

The program is designed to be efficient to use, easy to learn, and
require minimal special equipment. It allows ARC/INFO coverages to be
created and color geologic maps produced from ARC without the user
having to be trained in the use of the ARC/INFO program.

# Goals

A primary goal in development of GSMCAD is to maximize productivity by
simplifying procedures and minimizing unnecessary keystrokes, mouse
movements, or body movements. The second goal is to minimize training
time and mistakes by making the program intuitive and easy to learn,
supplying comprehensive and context sensitive on-line help, and
conforming to a layout similar to popular Windows and drafting programs.
The third goal is to empower the field geologist and recruit him to join
in digital data production by providing an easy and comprehensible way
to create and control his own digital data without extensive recourse to
"GIS experts". This must be done in such a way that the results will
still meet quality standards and be available in industry-standard
formats such as DXF and ARC/INFO coverages. A fourth goal is to speed
production and accuracy and minimize repeated trips to the same area by
enabling the geologist to digitally collect point and line data and
compile his map in the field. The fifth goal is to keep the program
small and simple so as to minimize the expense of equipment needed to
run the program.

# Why use GSMCAD?

There are many possible techniques for digital compilation of geologic
data into GIS data sets, and powerful commercial software at reasonable
prices is increasingly available. Under what circumstances might GSMCAD
still be a useful additional tool?

The most likely benefit is in situations where speed, simplicity, and
economy are necessary, and resources are limited. Possible examples are
as follows:

### 

## u Mapping programs just beginning conversion from conventional to digital methods might find it useful to quickly become productive.

##  

## u When field geologists are reluctant to give much time to generating digital data but the "GIS experts" do not have enough time to do all the conversion to digital format for the geologists.

##  

## u When data entry is available only through temporary semi-skilled students, whose turnover is rapid. 

## 

## u For direct digital entry and compilation of data in the field using GPS and laptop computers 

## 

## u For geologists or geology students that want to be able to work on their maps at home.

## 

## u For geologists working in isolated offices with little technical support.

## 

## u For geological surveys in developing countries where access to equipment and understanding of technology is limited.

##  

## u Any geologist who wants to get typical geologic field data into digital format quickly and easily.

# Field data collection 

GSMCAD can be used in combination with a GPS receiver for data
collection in the field in two modes. In situations where most
observations are made from a vehicle, a GPS receiver outputting NMEA
(National Marine Electronics Association standard for navigational data)
\$GPGGA sentences can be connected directly to the serial port on a
laptop running GSMCAD. When the \<GPS cursor\> option under the DISPLAY
menu is toggled on, the GPS position will drive the screen cursor just
as the mouse or digitizer puck would. Observation points can be
digitized with a keystroke. The points are linked either to notes typed
into a text file on the spot, a table of values, structure symbols
having azimuth and inclination attributes (such as strike and dip), or
digital photographs. When the GPS cursor reaches the side of the screen
window, the window will redraw centered on the current position.

A second mode is less "high-tech" but more practical. Observations are
recorded in a simple field book as the positions are recorded as
waypoints in the memory of the GPS receiver. At the end of the day the
GPS unit is connected to the laptop and the day's waypoint coordinates
are downloaded into a file that is subsequently read to generate
observation points in the GSMCAD database. The station number from the
fieldbook is an attribute of those points so they can be linked to data
copied in from the fieldbook. In the future it may be possible to
download files entered on the outcrop in a palm-size computer instead of
in a fieldbook (such as Fieldlogger files on a Apple Newton).

Both methods work best if a preliminary map is digitized and printed
over a basemap before going to the field. Lines sketched on the map or
on airphotos in the field can be transferred to the database by
digitizing on screen with the mouse, by reference to pre-existing
digitized lines and GPS points. A digital orthophotoquad (DOQ) or
vectorized basemap can be displayed behind the map vectors to guide line
placement. At present digital raster graphics (DRG) cannot be displayed.
If digital bases are not available, the same result can be achieved by
taking a small or roll up digitizer to the field.

# General capabilities

# 

The following partial list summarizes some of the capabilities and
characteristics of the GSMCAD program.

## Database creation

New geodetic (lat, lon) databases corresponding to standard USGS series
maps are quickly and simply created by specifying the type of map and
entering coordinates for the northwest corner. An outline frame or grid
of lines is automatically created. The program determines the projection
parameters of the base map and stores them in a projection file. A
preliminary plot file is generated listing the definition and plotting
characteristics of the most common entities on geologic maps. Unusual
projections and map outlines are also supported but require more user
input. Projections supported include Mercator, Universal Transverse
Mercator (UTM), Transverse Mercator, Oblique Mercator, Lambert Confor­mal
Conic, Albers Equal Area, Equidistant Conic, and Polyconic. Cartesian
databases in ground meters for cross sections and inches for correlation
diagrams are also easily generated.

## Attribution of lines and points on entry

All GSMCAD entities have three numeric attributes (CODE, P1, P2) stored
in the database. Other attributes may be stored in associated lookup
files. Before any entity can be created the three basic attributes must
be entered (or continued from the previous entry). The first attribute
(CODE) is linked in the plot file to a description of what that code
represents, such as "thrust fault, certain" or "bedding attitude
symbol". A pull-down menu listing the code next to the description
allows the user to select the geologic feature to be represented without
having to remember the code. Defining the entities from the manuscript
map as they are entered is more efficient than classifying the spaghetti
bowl of unclassified lines that sometimes results from scanning.

Attributed polygons can be created from lines and label points in a
GSMCAD database using the GSMPBLD program (Selner and Taylor, 1993), but
that step is done more easily in ARC/INFO. The polygons to be created
are attributed in GSMCAD by creating a text entity representing the
geologic letter symbol within the polygon. These text entities may be
visible or not. GSMCAD text entities can include any number of built in
leaders, and the far end of a leader is sufficient to create an
attributed label point in the polygon where the leader terminates. While
text points are being created, buttons labeled with various geologic
symbols appear on the side of the screen so that the user can switch
from labeling one unit to labeling another by clicking on the
appropriate button.

Types of entities supported by GSMCAD include lines, splined lines, 3-D
(profile) lines, polygonal shapes, linkable data points, rotational data
points (strike and dip), unlinked symbol points, text points with
(optional) leaders, and splined text.

## Efficient tablet digitizing

Attribution of lines and points traced from original copy on a
digitizing tablet is done using the keys on the digitizer keypad as the
entities are created. Three standard numeric attributes of CODE,
PARAMETER 1, and PARAMETER 2 are applied to all entities, but only need
to be entered when there is a change from the previous entity. The
speaker on the computer pronounces audible prompts for data entry and
echoes the keys pressed for confirmation. This minimizes the need to
look from the tablet to the screen. The \<0\> key starts an entity and
sets additional points, and the \<1\> key ends the entity (creating or
snapping to nodes for the first and last points of lines). The \<4\> and
\<5\> keys have similar functions except that they snap to the nearest
point before setting a coincident point, assuring a gap-less connection
on lines even when points are set beyond the automatic snap distance.
The \<2\> and \<3\> keys close polygons. The \<8\> key starts automatic
collection of points that continues until some other key is pressed. The
effect is similar to repeatedly pressing the \<0\> key or to holding the
\<0\> key down while moving the puck, except that the program measures
distance traveled and angle of inflection to minimize collection of
unnecessary points. On curves, points may be as close as every 0.03
inches and on straight segments as distant as 0.3 inches. Use of the
\<8\> key requires a steady hand but is the fastest way to enter line
data. Entities partially digitized may be abandoned by pressing the
\<E\> key. The screen window can be changed by digitizing new corners
(\<B\> key) or a new center point (\<C\> key). Rotatable symbols can be
entered either by keying in the rotation angle or by digitizing the
observation point and a point on the end of the symbol so that the
program can calculate the rotation.

Both mouse and digitizing tablet are active at the same time so that
points digitized on screen can be combined with those from the tablet if
convenient. Existing entities can be edited from the digitizing tablet.

## Symbol sets and fonts

The GSMCAD symbol set includes 155 of the most common symbols appearing
on USGS geologic maps. Seventy of the symbols are rotating symbols that
may have associated inclination angles posted nearby such as the bedding
strike and dip symbol. Thirteen are symbols to be placed along a
decorated line such as triangular teeth along a thrust fault. The
remaining seventy two are miscellaneous symbols such as those
representing quarries, drill holes, and mine shafts. Additional symbols
can be defined by the user. The line decorations are automatically
positioned at specified intervals along the appropriate line. Polygonal
areas can be automatically filled with randomly oriented symbols or
hatchures to produce a zipatone-like overprint. Posting points on the
rotatable symbols are automatically positioned, but can be moved by hand
to eliminate overposting. All symbols are carried as lines at the
defined map scale on export to ARC or DXF, eliminating the need for
special symbol sets in ARC, ArcView, AutoCad, or MapInfo. Observational
symbols (in contrast to line decorations) are also carried as attributed
points so that specialized ARC/INFO symbol sets or AutoCad blocks can be
used if desired.

GSMCAD fonts include many specialized geologic letter symbols as well as
subscripts and superscripts in addition to the Cambrian, Triassic, and
Pennsylvanian symbols. Unfortunately these letter symbols are not
exportable. Various ARC font sets include subsets of this collection,
but I am unaware of any as comprehensive as the GSMCAD font set. The
most common special symbols are translated from GSMCAD fonts to ARC
fonts in ARC/INFO by the GSMDRAW.AML arc macro language program.

## CAD-like editing

A complete set of CAD editing functions is available. Entities can be
moved, dragged, copied deleted, or changed; singly, in groups, or
globally. Entities can also be queried and lines broken (nodes added).
Points within entities can be moved, added, or deleted. Nodes can be
moved. All editing features can be accessed via pull-down menus and most
can be invoked with a single keystroke. Use of hot key commands and
mouse pointer is the fastest way to edit and accounts for much of the
efficiency of GSMCAD. Attributes can also be changed by on-screen
editing of data tables.

## Node editing

Correct topology for construction of polygons is partially achieved in
GSMCAD by various operations on nodes. Nodes can be created by creating
a line or by breaking a line. They can be selected and moved, carrying
with them the ends of the associated lines. If one node is created or
moved to a point within a defined snap distance of another, its position
will be moved to coincide with the older node and it will merge with the
older node and cease to exist separately. If the \<nodes\> option under
the DISPLAY menu is toggled on, hanging nodes will be displayed as red
squares and snapped nodes as black circles. Eliminating all hanging
nodes on lines that should bound geologic units is the first step toward
proper polygon topology.

## Export / import 

The general utility of GSMCAD is based on its ability to produce
ARC/INFO coverages and CAD drawings in DXF format through its export
functions. Both exports transfer all the special symbols, and the export
to ARC transfers the most common special letter symbols. The export to
ARC process is a combination of the GSMCAD export function and two arc
macro language (AML) programs that run under ARC. The process is
relatively quick and transparent, so the user does not have to trained
in ARC/INFO to produce necessary coverages and a graphics file of a
geologic map in about 20 minutes.

The GSMCAD to ARC export produces 18 ASCII files that must be
transferred to an ARC workspace. Those files are mostly paired ARC
generate files of ground meter coordinates and attributes, but include
three lookup files and a partial metadata summary. Entities are placed
in those files according to their code description in the active GSMCAD
plot file. For example, lines described as contacts are placed in the
files used to generate the polygon coverage. The GSMARC.AML program
converts the arc generate files into four coverages. The first is a
geologic unit polygon coverage, the second includes all faults and other
lines, the third includes points defining the location and attributes of
symbols and arcs that draw out the symbols, and the fourth includes the
visible text and leaders similar to an annotation layer. The GSMDRAW.AML
program reads these coverages, lookup tables, and optionally a basemap
grid to produce a graphics (.GRA) file of a colored geologic map on a
base. The .GRA file can be printed using the ARC/INFO RTL or POSTSCRIPT
commands.

The DXF import command is less sophisticated than the DXF export, so
only lines, polylines, and text are brought into GSMCAD. The primary
function is to bring in lines vectorized from scans or collected from
air photos on a digital photogrammetric plotter. Additional
import/export features beyond those built into GSMCAD are provided by
the GSMGIS DOS program (Selner and others, 1995) included with GSMCAD.

## Printer or plotter output

GSMCAD uses the standard Windows printer drivers to print parts of the
map at any scale or all of the map fit to page size. It also produces
HPGL2 output to drive a pen plotter or inkjet plotter. Colored geologic
maps can be produced directly from GSMCAD if the polygons shapes have
been built. It also has the unusual capability of plotting a properly
registered drawing on a paper or film basemap mounted in a pen plotter
by using the included HPGLUTIL utility.

## Cross section from profile line

A preliminary cross section diagram can be generated automatically from
a profile line. A profile line is a special type of GSMCAD entity
digitized with elevation values for each point. The points that should
be digitized are where the line crosses known elevations such as
topographic contours, ridge crests and valley bottoms, and geologic
contacts and faults. The generated database will be in ground meter
coordinates and includes a frame and labeled elevation tics. The ground
profile is intersected by tics at geologic contacts and faults, and the
tics project downward at the apparent dip calculated from the actual dip
entered while digitizing the profile line.

# History

GSMCAD is a Microsoft Windows program based on the GSMAP system of
programs developed by Gary I. Selner and Richard Taylor starting about
1985. GSMAP was developed because commercial software specialized for
the production of geologic maps on personal computers was not available.
GSMAP was continually improved as personal computer capabilities
increased and the 9th version was released in 1993 as U.S. Geological
survey Open-File Report 93-511 (Selner and Taylor, 1993). In the absence
of alternatives there was considerable interest despite slowness and
difficulty of use. Many geologists in the USGS, state surveys, and
government surveys around the world were trained and used the software
in the late 80's and early 90's.

The advent of MS Windows offered opportunities to increase the speed and
ease of use of computer programs, but GSMAP could not take advantage of
these opportunities because it is a MSDOS-based program compiled from
Quickbasic code. The answer was Visual basic, which allowed Quickbasic
code to be ported to the Windows environment. The author began working
with Gary Selner on the conversion in 1994 and began testing in 1995.
The first official version was released in 1996 as GSMCAD (GSMAP CAD) to
distinguish it from the DOS line that Gary Selner intended to continue.
In the Windows environment many enhancements were possible, and revised
versions of GSMCAD have been released on the Web frequently as new
features are added.

The utility of GSMCAD is sometimes questioned as the ARC/INFO GIS
program becomes more firmly established as the preferred (even required)
method of producing digital geologic maps at the USGS and in the wider
world. However, the difficulty of learning ARC and the expense of
required equipment made rapid conversion to ARC/INFO difficult, so
GSMCAD was enhanced to produce ARC generate files, and AML (arc macro
language) programs were written to run within ARC/INFO and produce ARC
coverages and graphic image files of geologic maps from GSMCAD
databases. This allowed geologists and temporary student employees to
produce good digital data without the intimidating challenge and
training expense of learning ARC/INFO. Additional benefits were that the
easy step of learning GSMCAD was good preparation for learning ARC/INFO
as the geologists' confidence increased, and that digitizing and editing
in GSMCAD was faster than in ARC/INFO. The GSMCAD to ARC conversion was
based on a method developed by Greg Green and Gary Selner (Selner and
others, 1995). The structure of the ARC coverages produced by the AMLs
was influenced by the ALACARTE AML program (Fitsgibbons and Wentworth ,
1991).

The latest enhancements to GSMCAD have emphasized direct digital
collection of points and lines in the field using GPS receivers, laptop
computers, and digital orthophoto images.

# The Future

The GSMCAD program is better optimized for the geologic data input needs
of many USGS central region National Cooperative Geologic Mapping Team
geologists than any available commercial program. The proliferation and
sophistication of new commercial programs suggests that this may not be
true in the future. Until that time the author intends to continue
adding features to the program that facilitate his own mapping or that
are requested by other users. The most likely features to be added next
are background display of digital raster graphic topographic maps and
linking with Apple Newton/Fieldlogger or palmtop data logger systems.
Other possibilities include optimization for direct export to Adobe
Illustrator/Avenza Map Publisher, export of ARC/INFO shape files, and
linking to Microsoft Access and dBASE files.

**REFERENCES**

Fitzgibbon, Todd, and Wentworth, Carl, 1991, ALACARTE User Interface -
AML Code and Demonstration Maps, Version 1.0: U. S. Geological Survey
Open-File Report 91-587A

Selner, Gary. I., Green, Gregory N., and Hoffman, J.D., 1995, GSMGIS: A
program to import and/or export data between GSMAP data bases and
various commercial and public domain products including ARC/INFO, GRASS,
IDRISI, EarthVision, GIV, Rockware STEREO, and MAPINFO: U. S. Geological
Survey Open-File Report 95-570, 34 p., one 3.5-inch disk

Selner, Gary. I., and Taylor, Richard B., 1993, System 9, GSMAP, and
other programs for the IBM PC and compatible microcomputers, to assist
workers in the earth sciences: U. S. Geological Survey Open-File Report
93-511, 363 p.

Williams, V.S., Selner, G.I., and Taylor R. B., 1996, GSMCAD, a new
computer program that combines the functions of the GSMAP and GSMEDIT
programs and is compatible with Microsoft Windows and ARC/INFO: U.S.
Geological Survey Open-File Report 96-007, 18 p., one 3.5-inch disk.