Index: trunk/Ohana/src/getstar/include/dvoImagesAtCoords.h
===================================================================
--- trunk/Ohana/src/getstar/include/dvoImagesAtCoords.h	(revision 26286)
+++ trunk/Ohana/src/getstar/include/dvoImagesAtCoords.h	(revision 26288)
@@ -27,10 +27,14 @@
 } Point;
 
+char *astromFile;
+char *coordsFile;
+double cmd_line_ra;
+double cmd_line_dec;
+int fullNames;
 int WITH_PHU;
 int SOLO_PHU;
 int ACCEPT_ASTROM;
-char *astromFile;
 
-// These functions belong to dvoImageOverap
+// These functions belong to dvoImagesAtCoords
 int  args_coords    	 PROTO((int argc, char **argv));
 int  ConfigInit_coords PROTO((int *argc, char **argv));
Index: trunk/Ohana/src/getstar/src/args_coords.c
===================================================================
--- trunk/Ohana/src/getstar/src/args_coords.c	(revision 26286)
+++ trunk/Ohana/src/getstar/src/args_coords.c	(revision 26288)
@@ -3,5 +3,6 @@
 void help () {
   fprintf (stderr, "USAGE: \n"
-	   "dvoImagesAtCoords [-astrom astrom_file] (coords_file)\n"
+	   "dvoImagesAtCoords [-astrom astrom_file] -coords coords_file\n"
+	   "dvoImagesAtCoords [-astrom astrom_file] (ra) (dec))\n"
     );
   exit (2);
@@ -18,4 +19,14 @@
   }
 
+  coordsFile = NULL;
+  if ((N = get_argument(argc, argv, "-coords"))) {
+    remove_argument (N, &argc, argv);
+    if (argv[N] == NULL) {
+      fprintf (stderr, "ERROR: no file provided with -coords\n");
+      exit (1);
+    }
+    coordsFile = strdup(argv[N]);
+    remove_argument (N, &argc, argv);
+  }
   astromFile = NULL;
   if ((N = get_argument(argc, argv, "-astrom"))) {
@@ -81,5 +92,19 @@
   }
 
-  if (argc != 2) help();
+  fullNames = 0;
+  if ((N = get_argument(argc, argv, "-full-names"))) {
+    remove_argument (N, &argc, argv);
+    fullNames = 1;
+  }
+
+  if (coordsFile) {
+      if (argc != 1) help();
+  } else {
+      // expect RA and DEC on command line
+      if (argc != 3) help();
+
+      cmd_line_ra = atof(argv[1]);
+      cmd_line_dec = atof(argv[2]);
+  }
 
   return (TRUE);
Index: trunk/Ohana/src/getstar/src/dvoImagesAtCoords.c
===================================================================
--- trunk/Ohana/src/getstar/src/dvoImagesAtCoords.c	(revision 26286)
+++ trunk/Ohana/src/getstar/src/dvoImagesAtCoords.c	(revision 26288)
@@ -7,4 +7,5 @@
 
 static int readPoints(char *filename, Point **pointsOut);
+static int makePoint(double ra, double dec, Point **pointsOut);
 static int ListImagesAtCoords (Image *dbImages, Point *points, int Npoints);
 
@@ -22,5 +23,9 @@
   
   Point *points;
-  Npoints = readPoints(argv[1], &points);
+  if (coordsFile) {
+      Npoints = readPoints(coordsFile, &points);
+  } else {
+      Npoints = makePoint(cmd_line_ra, cmd_line_dec, &points);
+  }
   if (!Npoints) {
     exit(1);
@@ -100,4 +105,21 @@
 }
 
+static int makePoint(double ra, double dec, Point **pointsOut)
+{
+    Point *pts;
+    ALLOCATE(pts, Point, 1);
+
+    pts[0].id = 1;
+    pts[0].ra = ra;
+    pts[0].dec = dec;
+    pts[0].Nmatches = 0;
+    ALLOCATE(pts[0].matches, int, 20);
+    pts[0].arrayLength = 20;
+
+    *pointsOut = pts;
+
+    return 1;
+}
+
 static int ListImagesAtCoords (Image *dbImages, Point *points, int Npoints) 
 {
@@ -113,5 +135,5 @@
         // output of lookup is filename[class_id.hdr] for astrometry files
         char *left_bracket = rindex(dbImages[N].name, '[');
-        if (left_bracket) {
+        if (!fullNames && left_bracket) {
             copy = strdup(left_bracket + 1);
             name = copy;
