A trial got under way Monday in a case that helped prompt the Legislature to change who oversees the machines that are used to measure blood alcohol content in drunken driving cases.

Brian N. Grenier, 52, of East Calais, is facing a felony charge — the third time he has been charged with driving under the influence — in Washington County criminal court in Barre. He could receive a maximum sentence of five years.

The trial started with former Washington County Sheriff’s Deputy Nathan Wolfe testifying that he pulled Grenier over in May 2010 for a broken headlight.

Wolfe said he smelled alcohol coming from Grenier’s vehicle and that Grenier admitted he had been drinking.

Wolfe testified that Grenier told him after he was arrested, “I’m screwed.” Grenier also tried to negotiate his way out of the drunken driving charge and talked about how embarrassing the charge would be to his family.

Grenier was taken to the Washington County Sheriff’s Department in Montpelier, and a breath test was administered using a DataMaster DMT. Grenier recorded a 0.172 percent blood alcohol content, well over the legal limit to drive of 0.08. It is that machine and breath test that are really on trial in this case.

In the process of defending the case, Grenier’s lawyer, David Sleigh, said he discovered that the machines law enforcement around the state had been using to administer breath tests were not being properly maintained and were giving out faulty data that could have been used for wrongful convictions.

The sources for Sleigh’s claims were two women who worked for the Department of Health as state chemists who had submitted complaints to their supervisors that the DataMasters were not being properly maintained, sometimes purposefully. Darcy Richardson, who no longer works for the state, submitted statements for the case saying as much, and Amanda Bolduc, who is still a state chemist, testified Monday about what was happening in the lab.

Because of the revelations about people possibly being wrongfully convicted, the Legislature moved the state’s alcohol testing program in March 2012 from the Department of Health to the Department of Public Safety, where others could scrutinize the information the program collected and the process could be more transparent so as to keep it honest.

In court Monday, Bolduc was introduced as a witness for the state, testifying about how the DataMasters function, about the process of determining blood alcohol content, and how effective the machines are.

On cross examination, Sleigh grilled Bolduc on several topics including when the DataMasters were purchased and what issues the state ran into when first using the machines — such as one releasing a puff of smoke when it was first turned on. Sleigh also asked Bolduc to talk about the opinions she had expressed during the period from February to November 2010, and where she documented her concerns about what one technician was doing — or not doing.

As part of the evidence for the trial, Sleigh submitted an email Bolduc had sent to the lab director in 2010 in which she said the integrity of the program was in jeopardy. Bolduc said lab technician Steve Harnois was engaging in unethical behavior to get the machines to pass their internal testing to make sure the DataMasters were working properly before a breath test was conducted. In the email, Bolduc wrote that because of Harnois’ alleged behavior, she would have a hard time testifying in court as to the reliability of the test results.

In all the talk about the issues the DataMasters in Vermont have had, little was disclosed or discussed about the particular machine used by the Sheriff’s Department in Montpelier in terms of whether it had been tampered with or was malfunctioning. In fact, Bolduc testified that the machine was working properly at the time it was used for Grenier’s breath test.

Harnois was investigated by the Department of Health and cleared of any malfeasance. He no longer works for the state.

Harnois also testified in the trial Monday — Sleigh characterized him as a “hostile witness” — and did not offer much information concerning the investigation of which he was the subject, saying he did not recall many of the answers to Sleigh’s questions.

The trial resumes today with Sleigh expected to call two witnesses to testify in support of the defense.