Index: /issm/trunk-jpl/src/m/plot/googlemaps.m
===================================================================
--- /issm/trunk-jpl/src/m/plot/googlemaps.m	(revision 23778)
+++ /issm/trunk-jpl/src/m/plot/googlemaps.m	(revision 23779)
@@ -105,4 +105,17 @@
 heightplus = height + bottom;
 
+%Read Google Maps key
+if exist('~/.googlemapskey');
+	key=deblank(fileread('~/.googlemapskey'));
+	iskey = true;
+else
+	%To create an API key, visit: https://developers.google.com/maps/documentation/maps-static/get-api-key
+	%Once approved, go to Google Cloud Platform and enable "Maps Static APIs"
+	%You will also need to "enable billing fot this project"
+	%Then get the key and enter it in ~/.googlemapskey
+	warning('It appears that you do not have a Google Maps API key, retrieving google maps photos may fail (this is a new requirement of Google...)');
+	iskey = false;
+end
+
 %Initialize final image
 final = zeros(floor(dy),floor(dx),3);%RGB image
@@ -122,4 +135,7 @@
 			'&sensor=false'...
 			'&scale=' num2str(scale)];
+		if iskey,
+			params = [params,'&key=' key];
+		end
 		url = ['http://maps.google.com/maps/api/staticmap?' params];
 		count = 0;
@@ -130,6 +146,6 @@
 				break;
 			catch me,
+				disp(['Failed, trying again... (' num2str(countmax-count) ' more attempts)']);
 				count = count+1;
-				disp(['Failed, trying again... (' num2str(countmax-count) ' more attempts)']);
 				pause(.3);
 				if count>countmax,
