Index: trunk/src/tmcsim/utilities/BuildHighwayFile.java
===================================================================
--- trunk/src/tmcsim/utilities/BuildHighwayFile.java	(revision 272)
+++ trunk/src/tmcsim/utilities/BuildHighwayFile.java	(revision 274)
@@ -1,7 +1,2 @@
-/*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
 package tmcsim.utilities;
 
@@ -30,5 +25,5 @@
  *      3. LDS file that has the fep line number for each LDS.
  * Output: 1. The highway map file that lists VDS info and the lanes it governs.
- *      2. A slightly reformatted loop file.
+ *      2. A slightly reformatted loop file.  (Not sure what this is for.)
  * @author jdalbey, jtorres
  */
@@ -157,8 +152,9 @@
                 else
                 {
-                    if (shortLoc.equals("ML") && !missingVDS.contains(vdsID))
+                    boolean desiredType = shortLoc.equals("ML") || shortLoc.equals("OS");
+                    if (desiredType && !missingVDS.contains(vdsID))
                     {
                         System.out.println("createLaneLookup(): vdsID: "+vdsID+
-                                " of type ML not found. "+ String.format("%3s %s %5s",fwy,dir,postmile));
+                                " of type "+shortLoc+" not found. "+ String.format("%3s %s %5s",fwy,dir,postmile));
                         missingVDS.add(vdsID);
                     }
Index: trunk/src/tmcsim/utilities/VehicleDetectionStation.java
===================================================================
--- trunk/src/tmcsim/utilities/VehicleDetectionStation.java	(revision 272)
+++ trunk/src/tmcsim/utilities/VehicleDetectionStation.java	(revision 274)
@@ -8,5 +8,6 @@
 
 /**
- * Represent a single VDS.
+ * Represent a single VDS, "a logical grouping of detectors" at a particular 
+ * location in one direction.
  * @author jdalbey
  */
@@ -33,5 +34,6 @@
         lineScanner.next(); // skip City
         String raw_pm = lineScanner.next().trim();
-        if (raw_pm.startsWith("R"))
+        // remove any postmile prefix, if it exists.
+        if (Character.isAlphabetic(raw_pm.charAt(0)))
         {
             raw_pm = raw_pm.substring(1);
Index: trunk/src/tmcsim/application.properties
===================================================================
--- trunk/src/tmcsim/application.properties	(revision 269)
+++ trunk/src/tmcsim/application.properties	(revision 274)
@@ -1,5 +1,5 @@
-#Thu, 21 Feb 2019 15:22:00 -0800
+#Mon, 25 Feb 2019 17:13:55 -0800
 
-Application.revision=268
+Application.revision=273
 
-Application.buildnumber=95
+Application.buildnumber=97
Index: trunk/src/atmsdriver/model/Station.java
===================================================================
--- trunk/src/atmsdriver/model/Station.java	(revision 237)
+++ trunk/src/atmsdriver/model/Station.java	(revision 274)
@@ -208,5 +208,5 @@
     {
         /* For now just use the color of the first lane. 
-         * TODO: Average the color in all the lanes for the given direction */
+         * TODO: Average the color in ALL the lanes for the given direction */
 
         String laneDir = "";
@@ -219,10 +219,10 @@
             laneDir = "OS";
         }
-        // Examine all the lanes in a given direction
+        // Search lanes to find specified direction
         for (LoopDetector loop : loops)
         {
             if (loop.loopLocation.substring(0,2).equals(laneDir))
             {
-                // Return color according to loop volume
+                // Return color according to loop volume of first matching lane
                 if (loop.vol == 1)
                 {
Index: trunk/src/atmsdriver/model/Highways.java
===================================================================
--- trunk/src/atmsdriver/model/Highways.java	(revision 266)
+++ trunk/src/atmsdriver/model/Highways.java	(revision 274)
@@ -63,6 +63,6 @@
         // load FEP Lines
         lines = loadLines(highwaysMapFileName);
-        // configure and load highways
-        this.highways = configureHighways();
+        // build highways data structure
+        this.highways = buildHighways();
 
         // write to FEP host and port number
@@ -71,7 +71,7 @@
     }
 
-    private ArrayList<Highway> configureHighways()
-    {
-        System.out.println("Loading highways...");
+    private ArrayList<Highway> buildHighways()
+    {
+        System.out.println("Building highways...");
         // The list of highways to return
         ArrayList<Highway> highways = new ArrayList<Highway>();
@@ -89,5 +89,4 @@
             {
                 Integer hwyNum = station.routeNumber;
-                
                 // if the map does not contain an entry for the highway, create
                 // a new entry (key/value pair) for the highway and instantiate
@@ -116,5 +115,6 @@
             ArrayList<Station> hwyStations = highwayMap.get(hwyKey);
             Collections.sort(hwyStations);
-            System.out.println("Loaded highway " + hwyKey + "...");
+            System.out.println("Loaded highway " + hwyKey + " with " +
+                    hwyStations.size() + " stations.");
             highways.add(new Highway(hwyKey,
                     hwyStations));
@@ -159,5 +159,8 @@
             startPost = postmile;
             endPost = postmile + range;
-
+            //TODO: Catch NPE exception for situation when the events file 
+            //   specifies a highway that doesn't exist in the network.
+            //   Also the case where a desired postmile to color isn't in
+            //   the network.
             // iterate through the stations, if within the specified highway
             // stretch, update the station by direction and apply dot color
@@ -222,5 +225,5 @@
     
     /**
-     * Loads a single FEP Line from the highways map file.
+     * Load all the stations for a single FEP Line from the highways map file.
      * 
      * @param sc scanner at the current FEPLine line
@@ -348,7 +351,7 @@
             // Print the number of bytes the highways data message contains
             System.out.println("Highways sending " + this.toCondensedFormat(false).toCharArray().length + 1 + "bytes to FEPSIM.");
-            
+            String outMsg = this.toCondensedFormat(false);
             // Write the highways data over the socket
-            out.println(this.toCondensedFormat(false));
+            out.println(outMsg);
             
             // close the socket
@@ -371,5 +374,5 @@
      *  and does include the string location names. If MetaDataOnly is false,
      *  dynamic loop values are included, and unnecessary information like string
-     *  location values are included.
+     *  location values are not included.
      * 
      *  The FEPSimulator takes in the toCondensedFormat() output, with a MetaDataOnly
@@ -526,4 +529,6 @@
     public String toJson()
     {
+        // TODO: move loading this file to init method so it doesn't get 
+        // called every time.
         PostmileCoords pmList = new PostmileCoords();
         FileInputStream fis = null;
@@ -545,6 +550,6 @@
         for (Highway hwy: highways)
         {
-            // For json output we don't care about listing all the stations
-            // in order by direction because we are just outputting points not lines.
+            // Consider each route direction
+            for (DIRECTION dir: DIRECTION.values())
             {
                 // Examine every station on this highway and direction
Index: trunk/src/atmsdriver/model/PostmileCoords.java
===================================================================
--- trunk/src/atmsdriver/model/PostmileCoords.java	(revision 269)
+++ trunk/src/atmsdriver/model/PostmileCoords.java	(revision 274)
@@ -119,4 +119,10 @@
         public boolean nameEquals(String target)
         {
+            // remove .0 for comparing strings
+            if (target.endsWith(".0"))
+            {
+                String truncTarget = target.substring(0,target.length()-2);
+                return this.name.equals(truncTarget);
+            }
             return this.name.equals(target);
         }
