Tag Archives: Geo

Code the Road: A Postcard from Arches National Park

We stopped at Arches National Park on June 3 on our way to Boulder, Colorado for our Developer Meetup. While there, we hiked into the park with our Street View Trekker backpack hoping to get a peek of just a few of the 2,000 natural stone arches, hundreds of soaring pinnacles, massive fins and giant balanced rocks.

On the hike we learned it has taken over 30 years for dedicated “arch-hunters” to find, document and map the various features of the park. In 1970, official park literature stated that the park contained ‘nearly 90 arches’, which is less than 0.05 percent of what is known today. In 1973 a geography professor conducted the first scientific study of the a park and three decades of concentrated exploration and discovery has put many "new" arches on the map.

It’s fitting, as we celebrate 10 years of Google Maps, that we also remember the history and dedication of those who mapped some of the most beautiful landscapes in the world—without the technology of a Street View Trekker backpack.
We wish we had been with them 30 years ago to use our Street View Image API to integrate the amazing vistas into Google Maps so everyone could experience the 2,000 landmarks.
MOABDRIVE_3.Still002.jpg

Today we’re in Milwaukee visiting with Harley-Davidson and some of their HOG riders. We can’t wait to see you on the road!

Posted by Ashley Smith, Developer Marketing, Google Maps APIs

Code the Road: Running the streets of Paris in Logan, Utah with iFit



What a workout!

After packing up our Code the Road bus at the conclusion of Google I/O, it was time to hit the road. Our first stop was Logan, Utah on Tuesday, June 2, to visit ICON Health and Fitness for the world’s first virtual 5k run on ICON’s line of NordicTrack treadmills powered by iFit and our Google Maps APIs.
ifitr.jpeg

Over 1,000 people turned out watch 40 runners compete in the run, including two runners from the Google Maps APIs team: myself and one of our engineering managers, James McGill.
googy.jpg

The event kicked-off with our lead runner arriving via helicopter(!) with a run she had recorded on her Android Wear watch while running the streets of Paris. Immediately she uploaded her route to all the iFit treadmills and we were off and running. As we ran, imagery from Street View was displayed on each treadmill so every runner was virtually running the streets of Paris together.
IMG_5407.JPG

Even more fascinating, the treadmills increased and decreased their incline as we ran, via data piped in from the Google Maps Elevation API.
DSC00055.jpg

Before, during, and after the run, attendees toured the Code the Road bus to get a close-up look of what developers and customers are building with our API suite and to get the chance to try out some of those innovative experiences for themselves.
IMG_3089.JPG

And then we were off again to Moab, Utah! Wednesday, June 3, we went hiking with Street View cameras at gorgeous Arches National Park and yesterday we hosted a Developer Meetup in Boulder, Colorado. Stay tuned for more updates and we can’t wait to see you on the road!

Posted by Ken Hoetmer, Product Manager, Google Maps APIs

Code the Road: Hitting the Road with the Google Maps Android API



Editor’s note: We will be (literally) coding a mobile app on the road as part of our cross-country road trip, Code the Road. Follow along as we build our app on the road and read more from David McClusky, Solutions Architect at Google.

Welcome to our first post in our Code the Road mobile app development series. If you have not heard, we are celebrating 10 years of the Google Maps API with a road trip across the United States, starting at Google I/O, at the Moscone Center in San Francisco, and ending at Walt Disney World Resort. Along the way, we’ll be making a number of stops and hosting Google Maps API Developer Meetups in Boulder, Chicago and New York.

While on the road, we’re building a mobile application to show how easy it is to get started with the Google Maps and Places APIs on Android. Over the next several weeks, we will be building a road trip app which will help our team stay connected while on the road. We'll be demonstrating how to:
  • Store your location data in the cloud with Firebase
  • Check in along the road using Places API
  • Plan a hike or bike ride using the Directions and Elevation APIs
  • Send notifications to your Android Wear watch
Want to follow along and build your own app? Here are some tips to help you get started:

Setup your environment. If you haven’t already, download and install the latest version of Android Studio. In addition, be sure use the SDK Manager to download the SDKs for your target version of Android, and the latest version of the the Google Play services SDK.

Create a new project. Create a new project in Android Studio and give it a name. We are calling ours “Code the Road.” Select a minimum SDK version to target, and then add a Google Maps Activity.

Create your Google Maps API keys. Before you can run your Google Maps application, you must create a free API key in the Developers Console. Please see the detailed instructions here on creating a key.

In the google_maps_api.xml file, you want to insert your key here:
<string name="google_maps_key" templateMergeStrategy="preserve" translate="false">
YOUR_KEY_HERE
</string>

Now you can run your Google Maps application, either in an emulator or on your device.

Display a marker on the map. For our Code the Road application, we want to start out simple. Let’s put a marker on map showing the kick-off location of our Code the Road road trip, at the Moscone Center in San Francisco. We’ll also change the icon to an image of our Code the Road bus.
To import your own custom marker image into your Android application, you need to copy the image file file into the app / res / drawable folder of your Android project. In this example, we are using this image of our bus, but you can use any image you like.

Finally, we need a bit of code to set up our map and draw our marker. In the MapsActivity.java file, we’ll modify the setUpMap() function as follows:
private void setUpMap() {
  LatLng busLocation = new LatLng(37.783879,-122.401254);

  mMap.moveCamera(CameraUpdateFactory.newLatLngZoom(busLocation, 12));
  mMap.addMarker(new MarkerOptions()
           .position(busLocation)
           .title("Code the Road Bus")
           .icon(BitmapDescriptorFactory.fromResource(R.drawable.bus)));
}
You may also need to add the following import statements at the top of MapsActivity.java:
import com.google.android.gms.maps.CameraUpdateFactory;
import com.google.android.gms.maps.model.BitmapDescriptorFactory;
Click the Run button to run in an emulator or an attached Android device. You now have a fully working Android application with Google Maps!
screenshot2.png

Our application does not do too much right now, so be sure to read our follow-on posts where we’ll be adding a lot more capability to our app, such as finding nearby places, storing our road trip location history to the cloud, and integrating with wearable devices. Stay tuned for more!

Code the Road: I/O Recap


Hello from Logan, Utah where we are setting up for our event with iFit today! After 18 hours on the road, we’re off to a great start on our Code the Road journey. Thousands of people were able to tour our 1959 GM bus at the corner of 4th and Howard in San Francisco last week. We hosted developers attending I/O, tourists visiting San Francisco, children walking home from school, and even a few Android Robots.
IMG_2852.JPG

Our postcard station was a great hit with both local and international visitors. Over 1000 postcards were dropped in the mail, some traveling only a few blocks and some traveling all the way to our friends in Japan!
IMG_2866.JPG
We were also really happy to host our Google Developer Experts for a breakfast at the bus on the last day of I/O. What a crew.

I/O Launches
Lastly, not only did we launch our Code the Road tour at I/O but we also launched two great new products.

Google Maps API for Android Wear brings the rich data of Google Maps to wearables, helping developers build apps that find the nearest coffee shop, get the fastest route home from work, track runs, and more.

Places API for iOS enables iOS apps to access Google’s database of 100 million places worldwide.

We can’t wait to see everyone on the road. If you haven’t already, please register for our developer events in Boulder, Chicago, and New York.

Posted by James McGill, Engineering Manager, Google Maps APIs

iFit builds immersive fitness experiences with Google Maps APIs



Editor’s note: Today’s guest blogger is Chase Brammer, Head of Product Development for iFit, a division of ICON Health and Fitness. ICON owns some of the best known brands in fitness, including NordicTrack, Proform, FreeMotion Fitness and Gold’s Gym. Read how iFit uses Google Maps APIs to build fitness equipment with Google Maps built-in. ICON is one of many customers sharing their story as part of our cross-country road trip, Code the Road.

Google Maps has been key in creating a great customer experiences for us, so we’re looking forward to welcoming the bus to Utah and participating in Code the Road. We’ll be providing a bike and treadmill to travel with the tour which demo how we are using Maps in our fitness equipment. We’ll also be hosting an event at our headquarters on June 2—one of the largest 5Ks to take place on treadmills—powered by iFit and Google Maps.

It’s tough for people to stick to their workout routines — but if you make it fun, social, and immersive they’re more likely to keep at it. To do that, we’ve built Google Maps into our line of fitness equipment, including treadmills and gym bikes. You can virtually run the Boston Marathon, bike the Tour de France, or just see whether you can beat your best friend in a short sprint.
NTL24013_tall_cat_xxl.png

When you’re on a treadmill or bike you can bring up Google Maps on an attached Android tablet and pick a route. You’ll see your progress on the map as you run or bike, and as the elevation of the route changes — for example if you’re heading up the Boston Marathon’s Heartbreak Hill — the angle of the treadmill or bike changes to match the real-life incline. You can also see markers representing other people who have run the route to see how your time compared to theirs.

We use Google Maps Android API to display the route and to show markers along the way. The Elevation API grabs the exact elevation of the route so we can change the incline of the treadmill or bike to match the route’s, while Street View displays what the route actually looks like. There are plenty of reasons we chose Google Maps APIs, but one of the most important was the way it lets us combine Street View with the Elevation API like this to create a truly immersive experience for our users.
iFit 2.png

One of the more interesting challenges we faced was how to place markers to show people their progress — including their position compared to another person — on a static map image.
iFit 1.png

So far our users have created 13.5 million customized workouts on our equipment using Google Maps. They’ve run or biked 76.5 million miles and burned more than 6.5 billion calories. We’ve heard stories of people who could barely walk but kept exercising because of their interactions with Maps, and are now running road races. We’ve seen our customers get more active, reach their goals and explore the world while doing it.

Tour the Code the Road bus


Our road trip has just begun and we already have a lot to share about our Code the Road bus. The bus is a mobile showcase of some of our most innovative customers, applications and websites that harness the power of Maps and location. If you’re in San Francisco, stop by Moscone Center where can experience first-hand what we’ll be featuring on the road. The bus is across from Moscone West at the corner of 4th Street and Howard Street—we’re outside the venue, so you don’t need an I/O registration get on the bus, so come down to visit!

SUGARBEAR, the name given to the bus by its original owners, is a 1959 PD-4104 General Motors Coach, rebuilt from the ground up in 1978. It measures approximately 35’ long by 8’ wide with a Detroit diesel engine outfitted for bio-diesel.

Here’s what we have on the bus:

Visitors are able to test-out the Android Auto navigation system first-hand and while on the road we will be utilizing Android Auto to keep us headed in the right direction.

Our Android Wearables demo wall includes a giant model watch on our Android robot arm, removable android watches for trying on, and an overview of the wearables features.

We highlight six of our location innovator customers and their interactive applications powered by Google Maps APIs. Visitors can demo applications from iFit, PicsArt, Harley-Davidson, Hilton Hotels, The Weather Channel and Walt Disney World Resort.

Toward the back of the bus, the Street View Treks demo, complete with a Trekker backpack with Street View camera, gives visitors a hiker’s view of the trails through an 80” monitor with Street View Treks imagery. And, even Street View racoon is along for the ride.

Outside of the bus we have a Proform bike and treadmill provided by ICON with the iFit app, powered by Google Maps. Visitors can run on the treadmill in Street View to experience a virtual run through town or trail.

We hope to see you on the road to experience the bus first-hand. Visit the Code the Road website to see our up-coming stops and dates.

Posted by Ashley Smith, Developer Marketing, Google Maps APIs

The world on your wrist: Google Maps API on Android Wear


Android Wear is great for quick glanceable information that lets you stay present and be connected. For example, wouldn’t it be great if Android Wear could show you a map of your run or allow you to pick a place on the map for you and your friend to meet? Now developers can support these use cases directly with location detection and the Google Maps API on Android Wear.

You can already use the paired phone to detect location, or use on-device location detection for wearables that have an onboard GPS. Now, with Google Play Services 7.3, developers can use Google Maps API directly on Android Wear. You can now offer your users a wearable-tailored Google Maps experience.

Getting Started - Showing a Map
If you are familiar with the Maps API on Android, you will feel right at home with the Maps API for Android Wear. Your Maps API key for your mobile app will work for your Wear app as well, provided your apps share the same package name. To display a map, you can follow the easy steps in our training guide or explore our sample. There are endless possibilities for maps on wearables, including finding the nearest coffee shop, getting the fastest route home from work, tracking your run, and more.

One new thing you will need to think about with Maps on Wear is the way that users exit your application. On Android Wear, users can usually exit an application if they swipe from left to right. If you don’t need to include an interactive map, this swipe-to-dismiss approach should work for your app too. However, if you want to allow the user to pan the map in any direction, the maps component will automatically disable the swipe-to-dismiss gesture and your application will need to handle how users will exit the application. The recommended approach is to implement the standard long-press-to-dismiss gesture. Using the Android Wear support library, this is quite simple.

To implement long-press-to-dismiss:
1. Add a the DismissOverlayView from the Wearable UI Support Library to the layout and initialise it in the onCreate method of the activity

<android.support.wearable.view.DismissOverlayView
     android:id="@+id/dismiss_overlay"
     android:layout_height="match_parent"
     android:layout_width="match_parent"/>

private DismissOverlayView mDismissOverlay;

@Override
public void onCreate(Bundle savedState) {
  ...
  mDismissOverlay =
    (DismissOverlayView) findViewById(R.id.dismiss_overlay);
  // Introduce this gesture to the user if necessary
  mDismissOverlay.setIntroText
    (R.string.basic_wear_long_press_intro);
  mDismissOverlay.showIntroIfNecessary();
  ...
}

2. Implement GoogleMap.OnMapLongClickListener for your activity and override the method. This will display the dismiss overlay with an option to exit your app:
@Override
public void onMapLongClick(LatLng latLng) {
  mDismissOverlay.show();
}
3. Assign the activity as the listener in onMapReady:
@Override
public void onMapReady(GoogleMap googleMap) {
  ...
  mMap.setOnMapLongClickListener(this);
  ...
}
Connecting People
In addition to displaying a map, another possible use for Maps on Android Wear is to pan a map to a specific location so that, for example, your friends can meet you at that specific location. In this case, you should add a marker and use GoogleMap.OnCameraChangeListener.
To add a marker to a map and listen into position changes:
1. Add an image in the center of the screen on top of the map. This indicates the selected location within the MapFragment element:
<ImageView
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:layout_gravity="center"
    android:src="@drawable/android_marker"/>
2. Implement GoogleMap.OnCameraChangeListener interface and override the following method:
@Override
public void onCameraChange(CameraPosition cameraPosition) {
  // Access the center of the camera through: 
  // cameraPosition.target.latitude and 
  // cameraPosition.target.longitude
}
3. Attach the listener to the Maps fragment:
@Override
public void onMapReady(GoogleMap googleMap) {
  ...
  mMap.setOnCameraChangeListener(this);
  ...
}
Living in the Real World
Android Wear is designed for users to stay connected while on the move. With the Google Maps API on Android Wear, developers can use the power of Google Maps to connect their users to what’s around them. Let’s keep our users moving... in the real world.

Posted by Hoi Lam, Developer Advocate at Google

Oh, The Places You’ll Go! Announcing the Google Places API for iOS

In March we launched the Places API for Android and opened up a public beta program for iOS. Today, we’re very excited to announce that the Google Places API for iOS is available to all developers!


Why Places?
When’s the last time someone asked you to meet them at -33.921053, 151.257996? Never? Exactly. People think of where they are in context: what shop they’re at or what park they’re in. The Places API enables your apps to speak your users’ language, based on Google’s database of 100 million places worldwide.


Who’s Using Places?
Excited to see the Google Places API for iOS in action?

"Google has incredibly high up time and the highest quality of data available. Because of Google, our users can rely on Places API when requesting a ride with nearly zero down time."   -- Lyft
Lyft will be coming out soon with a new version of their iOS app that uses Google Maps and Places APIs to know where you want to be picked up and dropped off.

Lyft is a welcoming, affordable ride within minutes. Simply request and go. Lyft launched in San Francisco in June 2012 and is now in more than 65 cities across the U.S.
                          


"Google Places API integrates smoothly into the PicsArt app, providing our users with all the benefits of quick and precise image geo-tagging experience."   -- PicsArt
In the next version of PicsArt, you’ll be able to simply use the place picker and the chosen location will be added to your post!

PicsArt is a full-featured photo editor app and the largest community of creatives and images, now reaching 65 million monthly active users.  

                               


Cross Platform
With this launch, all the great features of the Google Places API for Android are now also available on iOS:

  • Add a place picker: a drop-in UI widget that allows your users to specify a place (see the Picsart screenshot above)
  • Get the place where the device is currently located
  • Show detailed place information, including the place’s name, address, phone number, website, and more
  • Use autocomplete to save your users time and frustration typing out place names, by automatically completing them as they type (see the Lyft screenshot above)
  • Make your app stand out by adding new places that are relevant to your users and seeing the places appear in Google's Places database
  • Improve the map around you by reporting the presence of a device at a particular place.
Get Started
The Places API for iOS is available as part of the Google Maps SDK for iOS, now installable with Cocoapods! Have a go with


> pod try GoogleMaps


and play around with the “Maps SDK Demos” sample app. Then check out the developer documentation to add Places API to your iOS app.


Finally, a big thank you goes out to all the developers who helped battle-harden and test Places API for iOS during its beta run!

Posted by Jen Harrington, Product Manager, Google Maps APIs

Google Maps APIs hit the road with ‘Code the Road’


It’s been ten years since we launched Google Maps APIs to developers, and since then, developers have been creating amazing apps and online experiences. To celebrate how maps and location are an integral piece of app development, we’re hitting the road—literally, on a cross-country trip called Code the Road.

Code the Road is a road trip across the U.S. to highlight what developers have made possible with the Google Maps APIs. We’re driving our customized 1959 GM tour bus on a 14 stop journey across the U.S. where along the way we’ll meet with developers, bikers, athletes, and even Elmo. And for our final celebration, where better than the place where dreams come true? We’re going to Disney World to share the magic of coding!

Code the Road starts at Google I/O in San Francisco on May 28, where attendees can experience first-hand what we’ll be featuring on the road. The bus will be a permanent fixture during Google I/O across from Moscone West at the corner of 4th Street and Howard Street. Note that because we’re outside the venue, you don’t need an I/O ticket get on the bus, so come down to visit!

From there we’ll be heading across the country—stopping in Utah, Colorado, Wisconsin, Illinois, New York, Virginia, Georgia and Florida. Along the way we’ll be featuring some of the amazing applications developers have created using Google Maps APIs including apps from iFit, Harley-Davidson, Lyft, Hilton Hotels, The Weather Channel and Walt Disney World.
Code_the_Road_route.png
We will also be hosting three developer meetups in Boulder on June 4, Chicago on June 9 and New York on June 18. The meetups will highlight how developers can use the Google Maps APIs in their apps and websites and include sessions with Google Engineers and customers. We’re expecting these meet-ups to fill-up quickly, so reserve a seat at a location near you.

Here’s where and when you can come visit us:

Date
City
Location
May 28 & 29
San Francisco
Google I/O at the corner of 4th and Howard
June 2
Logan, UT
A visit with iFit ICON Health and Fitness with a 5K treadmill Run
June 3
Moab, UT
Arches National Park
June 4
Boulder, CO
Boulder Developer Meetup
June 8
Milwaukee, WI
Police escorted H.O.G. ride from Harley-Davidson headquarters to the Harley-Davidson Museum
June 9
Chicago, IL
Chicago Developer Meetup
June 10
Chicago, IL
A visit with Lyft
June 12
Chicago, IL
A visit with the Chicago Department of Transportation at North Avenue Beach
June 17
New York, NY
A visit with Sesame Street
June 18
New York, NY
NYC Developer Meetup
June 22
McLean, VA
A visit with Hilton Worldwide
June 23 & 24
Atlanta, GA
A visit with The Weather Channel and 48-hour Hackathon
June 26
Orlando, FL
Walt Disney World Resort

Follow us on our journey via the Code the Road website to provide additional details about the dates and locations of our stops as well as charting our progress as we head across the country. We will also be sharing on-the-road updates, videos and photos on the site throughout the trip.

We hope to see you on the road!

Posted by Ashley Smith, Developer Marketing, Google Maps APIs

Golf Channel’s GolfNow app helps golfers find their course using Google Maps APIs



Editor’s note: Today’s guest blogger is Robert Maretsky, Director of Mobile for GolfNowGolf Channel. Read how the GolfNow app uses Google Maps APIs to help golfers find the right course and improve their scores.

It can be easier for golfers to get a hole in one than to find the right golf course. That’s what led us to create the GolfNow app (available for Android), which helps golfers find and make reservations at courses, and improve their games by showing satellite views of courses as they play. The app is a spinoff of our GolfNow website. The app shows golfers their exact location on the course and the distance between their location and the cup by collecting routing information from a third party and overlaying it on top of Google Maps Satellite view.
We chose the Google Maps APIs because of the comprehensive coverage, timely updates and easy integration with our Android app. We use Google Maps to provide course details so that golfers can find the course that’s right for them. When on the course, to help golfers decide how to best play their next shot, we use the APIs to display satellite images from Google Maps and use a phone’s GPS to show golfers where they are on the course.
The Places API has been particularly useful for helping people search for golf courses based on location. If you know you’re going to have free time when visiting (for example) Universal Studios in Orlando, you can type 'Universal Studios' in the search bar and discover nearby courses. Results display course information, including reviews and star ratings from GolfAdvisor.com. We use custom layouts in our infowindows to style and display the data from the Places API.
GolfNow website is the largest provider of tee times in the world, with more than 13 million rounds and counting. Now, thanks to apps powered by Google Maps APIs, we’re making it even easier for golfers to get the most out of their favorite sport — helping them find and book tee times, playing golf with accurate GPS information, and reviewing how they did after the round is complete.