DIGITIZR.TXT      USING DIGITIZERS FOR DRAWING MAPS
===========================================================================
Document version: 8.3.2
Document dated:   25 Feb 1999
Author(s):        Bob Bruninga, WB4APR <bruninga@nadn.navy.mil>
                  Ken Swaggart, W7KKE
ABSTRACT
DIGITIZR.TXT      How to use digitizers to draw APRS maps.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

With the help and inspiration of Ken W7KKE, MAPFIX.bas now lets you rapidly
digitize maps and see the map on the screen as you draw it.  Most of the
instructions on using the digitizer within MAPFIX are included in that
program.  But the following is a more detailed set of set up ideas and
cautions..

The program should work with any Digitizer that outputs individual POINT
coordinates in the format XXX,YYY,C.  Where XXX and YYY are ASCII numeric
values from 3 to 5 digits in length, and C may contain ASCII characters
indicating the status of the PEN, Mouse, or Buttons on the mouse.  The
digitizer should operate in the POINT mode, so that a data point is only
output when the operator presses a button or puts the PEN to the digitizer
surface.  The characters included in C are only used, if they end with the
numeral "3", which is the 4th button on a 4 button digitizer mouse.  With this
type of mouse, you can use button 1 for adding points (the default mode), or
button 4 to move the cursor with no action...

The program is set up to operate at 9600,N,8,1.  To use the digitizer in
MAPFIX, you must issue the FILES-OPEN command to OPEN the COMM port
for the digitizer.  Once the plotter is initialized, entering a point with the
digitizer will always ADD a new point immediately after the current point
indicated by the small white circle.  Use EDIT-BEGIN to begin a new map
feature with the Digitizer.  This command prompts you for the name
of the new feature and then will use the first tablet point as the STARTing
point.  All future clicks of the mouse add to this feature.  You can also
use the traditional EDIT-NEW comand with the mouse, but you must FIRST move
the cursor to the starting point before doing EDIT-NEW.  MAPFIX has
HOTKEYS F4, F7, F8, F10 etc for beginning new features with a single key
stroke.

  1. Place a map, on the digitizerer.  It should be a Mercator
projection with lat and long lines parallel with edge of plotter.  MAPFIX
will calibrate itself with the location of the map, but the map must be
alligned so that a LAT line gives the same Y reading on both sides of the
digitizer surface.

  2. MAPFIX aligns to the scale of the MAP by having you choose a lat/long
in the vicinity of the upper left map corner and the lower right corner.
These points are used to calibrate the plotter surface to the map.  If your
map is not a perfect MERCATOR, you can minimize the error by NOT choosing the
extreme corners of the map, but choose points closer to your area of operation,
say in the center of the upper left Quadrant and the center of the lower right
quadrant.  Also if it is not true mercator, only do small sections at a
time and realign the map orthogonally each time.

  3. Run MAPFIX.  To start a NEW map from scratch, type NEW when asked for
a map filename.  You must then select the LAT/LONG of your origin for your map
and a scale in Pixels-per-degree.  Note that finer and finer resolutions make
smaller and smaller maps since there is a limit to the data values stored for
each data point.  When asked for a LAT/LONG in decimal degrees, decimal
fractions are fine. IE: 35.6 or 124.55, etc.  When asked for LAT/LONG in
degrees and minutes, separate the degrees and minutes with a COMMA such as
DD,MM.xx where minutes can be entered with decimal fractions if needed.

  4. Each map feature prompts for a feature name to ease in any debugging.
Then just point to each position you wish to digitize. The program beeps and
displays the converted data on the screen.  After each point is added, any
other MAPFIX command may be used.  In otherwords, if you dont like a point
that you just entered, just hit EDIT-DELETE, or EDIT-MOVE to MOVE it!

  5. Add Labels to the map at any time by moving the cursor to the desired
map location, and pressing LABELS-ADD.  Remember that the names are right
justified so that the label will appear to the left of the point specified.

  6.  Remember to save your map occassionally using the Ctrl-S command.  After
each save, you can just continue on with the next point, or QUIT the program.
If things get screwed up, hit the SPACE bar to re-draw the map.  If they are
still screwed up, consider saving the map, and using an EDITOR to check things
out and fix them according to the definition of a map given in README.MAP.

NOTE:  APRS and MAPFIX have troubles with a feature with only one point.
They are seen as straight lines to the ORIGIN.  To fit it. Save the map.
Then try the TASK CLEAR command.  Watch to see if any features such as
long shorellines go away.  If not, you were successfull.  ANother way is
to just save and reload the map.  This will uaually fix the last line in
the file.

   7.  To add your new map to APRS, add the map file to your APRS MAPS
or local sub directory, and then use an EDITOR to add the MAPNAME, center
decimal coordinates, and range to your MAPLIST.xxx file.  You may need to
suppress some of the existing maps in the distro version of MAPLIST.xxx,
by placing a * at the beginning of the map name, in order to keep the
total number of active maps in your list below the 170 limit.  Remember
that you must place the new map in the proper order (more detailed maps
must follow bigger maps that cover the same area) to get the right map
to display when you have overlapping maps.  While running APRS,
if maps overlap, you can temporarily look at a map beneath a map by hitting
MAPS-SHOW-ALT.  Then remember to fix the order of the maps in your
MAPLIST.xxx  file later on to customize the list to your satisfaction.


MOVING THE PAPER MAP ON THE TABLET, OR RESETTING THE TABLET TO ANOTHER MAP

This is surprisingly simple!  FIrst do a FILES-SAVE to save what you have
already.  Then without stoppping the program, place the new paper map on
the digitizer and do another FILES-OPEN and align the new map.  MAPFIX
will then re-set the coordinates to the new map, and you can keep on
digitizing!  This is neat, when you have 4 or 6 of the 24,000 scale
maps that you are going to use to build ONE APRS map file. 


CALCOMP DRAFTING TABLE MODEL 23360 (Used by WB4APR):
----------------------------------------------------
Use the onboard menu labels and mouse button 0 to configure the digitizer as
indicated above and in the prompts within MAPFIX.  I set it up for 200 LPI
since that is more than adequate.  Plug in the serial port, run MAPFIX.bas and
start drawing!  Do not get too fussy with lots of dots, remember that there is
a 2999 point limit in APRS, so don't waste points with fancy curves where
three points will do!


SUMAGRAPHICS MMII 1812 digitizer tablet:
-----------------------------------------
Use the sumagraphics SEND.COM program to configure the tablet as follows:

SEND /1 /S96 /Czaz8c8cFBe

For more info on these tablets contact W2g3zfj@unix.asb.com and/or
WJ8T snabkey@wingsbbs.com.


CALCOMP Model 4110 Plotter (Used by W7KKE):
-------------------------------------------

Data is serial ASCII, even parity, with 4 characters of x position and 5
characters of Y.   W7KKE thinks the 1st Y character is pen status.
(if so, he is gonna have to modify MAPFIX to make it work)

Power input is pin 24 +12vdc at 290-300 ma. Pin 25 is power return.

Data Ranges:  X: 0=left  4000=right   y: 0=bottom  4000=top

Pen status:  0 = point mode  1 = run mode, pen down   9 = run mode, pen up

Set the "A/B" switch on back next to the D25 plug to B for POINT mode

Pin connections:
1    NC
2    +/- 15 v RS-232 data output from plotter.
3    + 5v from board (probably for some original interface device)
4    "             "                      "
5    0/+5v TTL data output
6    "                "
7    Ground (data return)
8-11 baud rate.
12 - 23 Unknown. Appear to be open.
24   +12 vdc  power input
25   ground


BAUD RATE PROGRAMMING PINS:

BAUD RATE      8     9     10     11   (X = connection to GND)

  1200         .     X      .     .
  4800         .     X      X     .
  9600         .     X      X     X    (use this for MAPFIX.bas)



TEKTRONIX 4957 GRAPHIC TABLET (used by WA1VJH):
-----------------------------------------------

INITIALIZATION STRING: ESC Z, ESC Q, ESC M1, ESC F3, ESC C0, ESC x

ALSO, MAPFIX.BAS WILL HAVE TO BE MODIFIED AS FOLLOWS TO ACCEPT THE DATA
STRING FROM THE 4957:  Use the SEARCH-FIND command to find them

 FROM: digix1 = 5000 - VAL(LEFT$(a$, 5))
   TO: digix1 = 5000 - VAL(MID$(a$, 2, 5))
 FROM: digiy1 = VAL(MID$(a$, 7, 5))
   TO: digiy1 = VAL(MID$(a$, 8, 5))
 FROM: digix2 = 5000 - VAL(LEFT$(a$, 5))
   TO: digix2 = 5000 - VAL(MID$(a$, 2, 5))
 FROM: digiy2 = VAL(MID$(a$, 7, 5))
   TO: digiy2 = VAL(MID$(a$, 8, 5))
 FROM: x = 5000 - VAL(RIGHT$(a$, a - 1))
   TO: x = 5000 - VAL(MID$(a$, 2, a - 1))
 FROM: y = VAL(MID$(a$, a + 1, B - (a)))
   TO: y = VAL(MID$(a$, a + 2, B - (a)))
 FROM: Btn = VAL(RIGHT$(a$, 1))
   TO: Btn = VAL(MID$(a$, B + 1, 2))

ALSO NOTE THAT THE 4957 BUTTON NUMBER 3 WILL FUNCTION IN PLACE OF THE
DESCRIBED MAPFIX BUTTON 4 DUTIES.   DE GARNET/WA1VJH

