title: RoadManager for osmdroid error
body: <p>I am following a tutorial here <a href="https://code.google.com/p/osmbonuspack/wiki/Tutorial_1" rel="nofollow noreferrer">https://code.google.com/p/osmbonuspack/wiki/Tutorial_1</a> but I have encountered an error that it doesn't show the correct route correctly. It just shows a straight line from Point A to Point B.</p>
  
  <p>What I want to achieve is to show the correct route from these points. I'm guessing the error is that it doesn't recognize any nodes to go through.</p>
  
  <p>A similar question has been also asked and I am assuming I have the same problem if I haven't explained my question well.</p>
  
  <p>Similar question can be found here: <a href="https://stackoverflow.com/questions/14691901/osmdroid-routing-problems-when-following-a-tutorial">OSMDroid Routing problems when following a tutorial</a></p>
  
  <p>Here is a part of my code using RoadManager</p>
  
  <p>Here is a part of the code.</p>
  
  <pre><code>try {
  
                  //get current longlat
                  gpsLocator.getLocation(); 
                  cur_loc_lat =gpsLocator.getLatitude();
                  cur_loc_long =gpsLocator.getLongitude(); 
  
              } catch (Exception e) {
                  // TODO: handle exception
              }
  
              //--- Create Another Overlay for multi marker
              anotherOverlayItemArray = new ArrayList&lt;OverlayItem&gt;();
              anotherOverlayItemArray.add(new OverlayItem(
                      "UST", "UST", new GeoPoint( testlat, testlong))); 
  
              //--- Create Another Overlay for multi marker 
              anotherOverlayItemArray.add(new OverlayItem(
                      locDefine[0], "UST", new GeoPoint( sel_latitude, sel_longitude))); 
  
  
              ItemizedIconOverlay&lt;OverlayItem&gt; anotherItemizedIconOverlay 
               = new ItemizedIconOverlay&lt;OverlayItem&gt;(
                 TomWalks.this, anotherOverlayItemArray, myOnItemGestureListener);
  
              myOpenMapView.getOverlays().add(anotherItemizedIconOverlay);
              //---
  
              //Add Scale Bar
              ScaleBarOverlay myScaleBarOverlay = new ScaleBarOverlay(TomWalks.this);
              myOpenMapView.getOverlays().add(myScaleBarOverlay);
  
  
             try {
  
  
                 //1 Routing via road manager
                  RoadManager roadManager = new MapQuestRoadManager();
                  roadManager.addRequestOption("routeType=pedestrian"); 
                  /*
                  roadManager.addRequestOption("units=m"); 
                  roadManager.addRequestOption("narrativeType=text"); 
                  roadManager.addRequestOption("shapeFormat=raw"); 
                  roadManager.addRequestOption("direction=0");  
                  */
                  //Then, retrieve the road between your start and end point:
                  ArrayList&lt;GeoPoint&gt; waypoints = new ArrayList&lt;GeoPoint&gt;();
                  waypoints.add(new GeoPoint(testlat, testlong));
                  waypoints.add(new GeoPoint(sel_latitude,sel_longitude)); //end point
  
                  Road road = roadManager.getRoad(waypoints);
  
  
                  // then, build an overlay with the route shape:
                  PathOverlay roadOverlay = RoadManager.buildRoadOverlay(road, myOpenMapView.getContext());
                  roadOverlay.setColor(Color.GREEN);
  
  
                  //Add Route Overlays into map
                  myOpenMapView.getOverlays().add(roadOverlay);
                  myOpenMapView.invalidate();//refesh map
  
  
                  final ArrayList&lt;ExtendedOverlayItem&gt; roadItems = 
                            new ArrayList&lt;ExtendedOverlayItem&gt;();
                  ItemizedOverlayWithBubble&lt;ExtendedOverlayItem&gt; roadNodes = 
                            new ItemizedOverlayWithBubble&lt;ExtendedOverlayItem&gt;(TomWalks.this, roadItems, myOpenMapView);
  
  
  
                  myOpenMapView.getOverlays().add(roadNodes);
                  myOpenMapView.invalidate();//refesh map
  
  
  
                  int nodesize=road.mNodes.size();
                  double length = road.mLength;
  
  
                  Drawable    marker = getResources().getDrawable(R.drawable.marker_node);
  
                  Toast.makeText(TomWalks.this, " Distance : " + length + " Nodes : "+nodesize ,Toast.LENGTH_SHORT).show();
  
                    for (int i=0; i&lt;road.mNodes.size(); i++)
                    {
                            RoadNode node = road.mNodes.get(i);
                            ExtendedOverlayItem nodeMarker = new ExtendedOverlayItem("Step "+i, "", node.mLocation, TomWalks.this);
                            nodeMarker.setMarkerHotspot(OverlayItem.HotspotPlace.CENTER);
                            nodeMarker.setMarker(marker);
                            roadNodes.addItem(nodeMarker);
  
                            nodeMarker.setDescription(node.mInstructions);
                            nodeMarker.setSubDescription(road.getLengthDurationText(node.mLength, node.mDuration));
                            Drawable icon = getResources().getDrawable(R.drawable.marker_node);
                            nodeMarker.setImage(icon);
  
                    }//end for
  
                    myOpenMapView.getOverlays().add(roadNodes);
                    myOpenMapView.invalidate();//refesh map
  
  
              } catch (Exception e) {
                  // TODO: handle exception
  
  
                  Toast.makeText(TomWalks.this,e.getMessage(),Toast.LENGTH_SHORT).show();
  
  
              } 
  
              myMapController.setCenter(new GeoPoint( sel_latitude,  sel_longitude));
  
  
          } catch (Exception e) {
              // TODO: handle exception
          }           
      }
  
  }
  
  }//===================================================================================================
  </code></pre>