Researchers at the University of Washington are developing a simple way to assess potential concussions and other brain injuries with just a smartphone.

The team has developed an app called PupilScreen that uses video and a smartphone’s camera flash to record and calculate how the pupils respond to light.

Assessing head trauma due to, for example, sports injuries or a car crash is typically done with either a pupilometer — rarely found outside of hospitals — or a mix of subjective evaluations like balancing, repeating a list of words or visually examining a pupil’s response with a flashlight. But those methods aren’t concrete and leave room for error — a problem considering the long-term effects brain injuries can have.

To create PupilScreen and provide an objective assessment of potential head trauma, the researchers used deep learning tools to train a neural network how to find the pupil of the eye and track how it responds to a flash of light over the course of three seconds.

A smartphone camera records the three second video and the light is provided by the camera’s flash. PupilScreen then takes care of the rest, providing a readout as to whether the pupil response was within normal ranges or is showing signs of brain injury. In a small pilot study, doctors were able to accurately determine if a person had a brain injury by looking at PupilScreen’s readouts.

Currently, the app is only able to assess severe injuries, but follow up work is being done to determine which pupillary response characteristics mark milder or more ambiguous forms of trauma.

The app also currently works with a plastic box that blocks out ambient light and makes sure the smartphone is the appropriate distance from the eyes, but the team is also working on making the app useful without accessories.

“After further testing, we think this device will empower everyone from Little League coaches to NFL doctors to emergency department physicians to rapidly detect and triage head injury,” Lynn McGrath, one of the researchers on the project, said in a statement.

The work is being presented at Ubicomp 2017.