Mike Lynn is cautiously excited. A 49-year-old family man who lives in the Bay Area, Lynn has been an emergency-room doctor at Highland Hospital for most of two decades. His company, Hound Labs Inc., has just developed the technology to produce a breathalyzer that can detect marijuana, but its future is uncertain.

Lynn, who has some experience investing in biotech companies, is also a reserve deputy sheriff for Alameda County. Together these experiences led him to wonder if technology might play a role in preventing accidents caused by drivers under the influence of marijuana. No puritan, Lynn also wants to make sure law-abiding weed smokers won’t get in trouble for the wrong reason.

“It doesn't make any sense at all to arrest somebody that smoked last night and is no longer impaired, on the road,” Lynn told me. Current tests used by law-enforcement agencies detect THC through blood, saliva, and urine, but THC can stay in the body for days, weeks, or even a month, so it’s extremely difficult to tell if someone is high based on the THC found in those tests. States like Washington and Montana limit THC levels to five nanograms per milliliter of blood, which many argue does not represent someone who is still impaired by their marijuana use. Pennsylvania has it limited to only one nanogram.

“Typically, if you have five nanograms in a regular smoker, you probably won't see any behavioral effects,” said Carl Hart, a professor of psychology and psychiatry at Columbia University. “Whereas, with five nanograms in someone who’s never smoked, you might see a lot of effects.”

With breath, Lynn explains, the THC signal only sticks around for a few hours. Some studies have found that THC stays on a person’s breath for as long as four hours. The company doesn’t yet know if the breathalyzer can detect if someone ate a marijuana product recently.

The path to creating a breath test has not been simple or easy. Lynn said THC is found in quantities “somewhere between a million and a billion times less concentrated” than alcohol in breath. To create a test that could isolate THC in breath and measure it accurately, Lynn enlisted the help of a team of scientists led by Dan Fletcher, a professor at the University of California, Berkeley who specializes in bioengineering. They looked at everything from large devices used to detect small quantities of substances to scanners that look for residues found in explosives to try and find a solution. Eventually, they figured out how to filter breath through the right chemicals to create a reaction so a device can tag and count THC molecules.

Lynn wouldn’t discuss the actual chemistry, saying that it was “proprietary.” He said the process has been successfully tested in the lab, and that his company will start trials at the University of California, San Francisco, and San Francisco General Hospital early next year. They will also be testing versions of the breathalyzer with law enforcement around that time, and they hope to have the product ready for deployment by the end of 2016. Initial law-enforcement tests will be carried out in Oakland and Berkeley.

Hart expressed skepticism about the idea behind the technique, calling it a “dumb idea.” “The chemistry of alcohol is such that there is essentially no blood-brain barrier for alcohol … so what is in your lungs or blood is the same amount, typically, as what’s in your brain,” he said. “With marijuana or any other drug, we can’t do that. We have no idea what's in the brain based on some measure in your mouth or in your lungs.” He said the THC doesn't transport itself along the blood-brain barrier like alcohol, so what’s in the breath probably doesn't represent what’s in the brain.

Many outside of Hound Labs are concerned people who may have smoked recently, for medical purposes or otherwise, might get labeled as intoxicated when they aren’t. “If you were to take somebody that is a heavy cannabis user, they’re certainly going to have a much higher test result than someone who occasionally uses it … How do you quantify that?” said Jason Thomas, a former Denver detention officer and Marshal’s Deputy. Tolerance will also be difficult to assess.

Spike Helmick, a former highway-patrol commander who has been commissioned by three governors to help develop California’s DUI standards, told me California officers have been wanting a way to test if someone is driving high for at least 15 years. He said he believes we can get to a point where we establish a proper level of THC that represents a state of intoxication.

A federal study done by the National Highway Traffic Safety Administration this year found driving high from marijuana is significantly safer than driving drunk, but both are worse than driving sober. Hound Labs also intends to create a version of the product that can be used by civilians for self-assessing their THC levels. Lynn said many people don't know how potent the marijuana they're buying or sharing is; they will want to know if they're at a safe level.

“The reality is that over 100 million people in this country have legal access to marijuana, so let’s acknowledge that,” Lynn said. Whether his product will make things any better for them remains to be seen.