NeatoCode Techniques
ThroughTheWalls: Open Source Glass AR App Wins Ericsson Prize

The new ThroughTheWalls native app for Google Glass brings AR apps on Glass into reality and won the Ericsson and Veracode prizes at the AT&T public safety hackathon this weekend in Palo Alto. Here’s how to put a real AR app together from all the samples and discoveries that surfaced recently! Video demo:

To pull this off, ThroughTheWalls tracks your location and the direction your Google Glass and head are facing - then populates the wearable heads up display with easy to follow instructions and vital data calculated from that. So if you are looking for shelter during an emergency like a flood or forest fire, the screen looks like this:

image

Once you turn to face the shelter, you can see exactly what angle it is from you on the screen with an indicator:

image

image

The example shelter data used was published by the San Diego County Emergency Site. In a world where many emergency response teams are still using 70 year old radio technology, San Diego Country have a mobile app and even sent someone to the hackathon to help out!

As the shelter locations are retrieved by the app via the Internet, they will be up to date even after installation. In future versions they could be cached to work even without internet. Using a live web service like this is great progress for a public safety system, however. We were told things like license plate checkers often run off data in the trunk of a police cruiser and miss new changes like a robbery car being added.

Swiping left or right on the glass changes to guiding to a different shelter if any. Swiping down gets you back to the menu of destinations including: California Highway Patrol incidents, large cities and monuments, and CCTV cameras. Tapping while viewing a CCTV camera will actually show the image taken from that camera immediately. Stuck not moving in traffic? A few quick taps let you look 2 miles down the road and see what is happening:

image

image

image

Tapping other items, like CHP incidents, shows the details of the incident:

image

image

The source and APK are available on GitHub. You can install the app if you have turned on debug mode via the “adb install ThroughTheWalls.apk”  command. I recommend launching the app from launchy, an app launcher that replaces the default settings in Google Glass:

image

When writing your own AR apps, you can get sensors data by registering for updates like this:

mSensorManager.registerListener(this, mOrientation, SensorManager.SENSOR_DELAY_NORMAL);
final List providers = mLocationManager.getAllProviders();
for (String provider : providers) {
final Location lastKnownLocation = mLocationManager.getLastKnownLocation(provider);
mDisplay.setLocation(lastKnownLocation);
final boolean enabled = mLocationManager.isProviderEnabled(provider);
mLocationManager.requestLocationUpdates(provider, 0, 0, this);
}

Calculating bearing and distance to a location looks like this:

final Location currentLocation = new Location("ThroughGlass");
currentLocation.setLatitude(currentLat);
currentLocation.setLongitude(currentLon);
float bearingToAsEastOfNorthDegrees = currentLocation.bearingTo(targetLocation);
float delta = normalize(bearingToAsEastOfNorthDegrees - azimuth);
final String deltaString = 0 == delta ? "" :
delta > 0 ? (" right " + roundTenths(delta))
: (" left " + roundTenths(Math.abs(delta)));
text.setText(roundTenths(azimuth) + "° " + deltaString+ "°");

Drawing to the display based on the bearing looks like this:

final int width = getWidth();
final int height = getHeight();
final int indicatorWidth = mIndicator.getIntrinsicWidth();
final int indicatorHeight = mIndicator.getIntrinsicHeight();

final int offsetCenterX = (int) (width * mOffsetPercent);
final int indicatorLeft = offsetCenterX - (indicatorWidth/2);
final int indicatorTop = (height / 2) - (indicatorHeight/2);

mIndicator.setBounds(indicatorLeft, indicatorTop, indicatorLeft + indicatorWidth, indicatorTop + indicatorHeight);
mIndicator.draw(canvas);

Many thanks to Ericsson and Veracode for the prizes we won at the hackathon. Hopefully this helps kick start Google Glass AR development! Google recently announced an upcoming Glass Development Kit that will allow native apps like this, which is exciting news. Participating in the first ever public safety hackathon was also a thrill and there are many problems there that haven’t had modern technology applied to them.

Telemed from patient’s eyes!

rgrosssz:

Excellent short video of patient’s perspective with telemedicine. Just like #iipodteletrauma http://t.co/dHWCz1HZ or #GlassMed ( in the near future, hopefully)( See #GoogleGlass and future uses in medicine. Interview with Dr. Rafael Grossmann by @blogbrevity > http://t.co/0JL5enT10N ) Because ~80% doctors office visits don’t require physical contact. Makes sense!
Virtual Dr’s visit spares patient expense,travel time http://t.co/wd4AOT8G9c via @thewindsorstar

Nice link to write up by an MD of uses for Google Glass in the links:

While doing rounds

  • Using “face-recognition” to display a patient’s current medical data and history.
  • Having lab results, pathology reports or radiologic images displayed right in front of his eyes.
  • Swiftly ordering new tests or procedures.
  • Calling in a consultant for a video chat.
  • Giving an update to a family member, if requested by the patient or through a Power of Attorney.

While in the OR

  • Consulting an expert, or checking any data for a better, safer surgery.
  • Taking a picture of a lesion or tumor, and having a pathologist or colleague give a timely opinion.
  • Updating relatives in the waiting room.
  • Streaming live video or photos during surgery via a secure network.

While consulting

  • Connecting to a request for expertise, without time or geographic barriers.

Other entries for #ifihadglass cited

  • Diagnosing patients via visual apps.
  • Immediate access to drug information and possible interactions.
  • Noting conversations with patients for future reference.
Hey wanted to know if you were interested in partnering up on a google glass app?
Anonymous

Sure, what app would you like to write? Are you a coder, graphics person, or business person?

First Facial Recognition Hack for Google Glass

Google’s new wearable computer, Google Glass, is bringing unheard of capabilities into new situations. A popular question that comes up on shows like TWiT.TV is about what’s going to happen once facial recognition technology reaches Glass. Well here’s the first hack for that!

My team wrote an app at a medical hackathon called MedRef for Glass. The app lets you find and create patient folders by voice, add photo and voice notes, view previous notes, and also find patient folders by facial recognition! Very exciting.

Some people I talked to said hospitals are full of very busy people, often with their hands full, working with a lot of information - so Google Glass making it wearable is especially looked forward to there!

Here is a video demo of the app:

The card it adds for finding/setting the patient being worked with by voice looks like this:

The contacts it adds for adding photo notes to the patient being worked with, or searching by facial recognition look like this:

Retrieved notes are a stack of everything added for that person:

Facial recognition results look like this:

The app is open source on GitHub. Facial recognition uses the Betaface  web service. Uploading a new face to it looks like this:

final Mirror glass = MirrorClient.getMirror(credential);
List<Attachment> attachments = replyItem.getAttachments();
InputStream is = downloadAttachment(glass, attachments.get(0), credential);
Image trainingImage = new Image(is);
final ArrayList<Face> faces = trainingImage.getFaces();
final Face face = null != faces && faces.size() > 0 ? faces.get(0) : null;
Subject s = Dao.INSTANCE.addFace(notification.getUserToken(), face.getUID());

Checking a face against others looks like this:

Person probe = new Person();
probe.addUID(face.getUID());
List<Subject> subjects = Dao.INSTANCE.listSubjects(notification.getUserToken());
for (Subject s : subjects) {
float confidence = probe.compareWithUIDsForConfidence(s.getFaces());
s.setMatch(confidence);
}
Collections.sort(subjects);
boolean sentResult = false;
for (Subject s : subjects) {
SearchResultsCard.insert(request, credential, s);
sentResult = true;
}

Thanks for reading! In the future, on more powerful hardware and APIs, facial recognition could even be written to run all the time! What do you think the killer app is for facial recognition on Glass?

thepete:

“Ultimate Android customs by Teru Fujita for sale Sunday at 4pm EST! TenaciousToys dot com” caption and photo by tenacioustoys http://bit.ly/138xtXo reblogged from instagram.

Awesome!

thepete:

“Ultimate Android customs by Teru Fujita for sale Sunday at 4pm EST! TenaciousToys dot com” caption and photo by tenacioustoys http://bit.ly/138xtXo reblogged from instagram.

Awesome!

Outside Glass

One thing about wearing Google Glass - you sure get a lot of pictures of yourself! The above were all taken by people trying on the Google Glass I got last week. I’ve demo’ed it at Google HQ on the first walk around after my fitting, at a meetup at Google, at a hackathon at Yammer, at home, at business lunches, at a lightning talk meetup, etc.. The first thing I usually show to someone is how to take pictures by voice, and this is the result. Now I have several dozen pictures of myself, not to mention the movies from people trying out the record a video command, ha.


How to get massive traction / usage to your product

oguzserdar:

Awesome preso on traction. Graphic with clear steps especially useful:

gilt-tech:

Over the last three months, we overhauled the front end (jsp, html, handlebars, less/css, javascript, zepto) for Gilt’s mobile web experience (http://m.gilt.com). The redesign was inspired by learnings acquired from our iPhone App and the design is meant to replicate a lot of those features.

Nice blow by blow on improving the appearance of a shopping app. Great for developers working on polishing their apps.

It sucks that you can't get full access to the API's within the glass software. I can't wait to see what developers will have to play with in just a few iterations of glass. What do you think?

Other companies might step in as well with knock off hardware and access to real app stores, removing the biggest limitation. I could do a lot more with that. I guess it would have to be someone big enough they have their own patents, though, so Google’s in this area couldn’t just take them down.

Shopping with Voice on Google Glass - Live Demo!

Google’s new wearable computer, Google Glass, is shipping to testers and journalists who are trying all manner of things with it. The Verge recently drove around in a car using one! How will shopping look on this new device? I wrote a basic shopping app to find out!

The app is called VoiceBuyer for Amazon. If you have a Google Glass you can install off the web site and follow along! It allows you to submit a voice request for what you want to buy while wearing the Google Glass:

image

image

image

image

Results are sent back to the Glass so you can swipe through a few options and add one to your cart right then and there!

image

image

Here’s a video demo:

Testing out the app has been pretty fun! You actually can buy whey protein while standing in front of your kitchen cabinets, buy an HDMI cable while plugging in a new game console at your TV and realizing you need a second one, etc.. No more forgetting what I need to buy or rushing to write down a shopping list somewhere. 

If you are in a store and think a retailer is ripping you off on price, well you are just a couple quick taps on your wearable from checking! In the future, bar code reading and one tap check out may even be possible.

What do you think about the future of shopping? Let me know below! Thanks for reading.