SAN JOSE — Elizabeth Holmes, the charismatic and infamous Theranos founder, unexpectedly took the stand to defend herself at her fraud trial on Friday, a move that allowed the jury to hear from her directly for the first time.

Earlier in the day, the prosecution rested its case in the 11th week of trial, after calling nearly 30 witnesses.

Holmes’s attorney Kevin Downey took her through her background as an entrepreneur, including her first patent application and her decision to drop out of Stanford in 2004. Holmes seemed relaxed and smiled regularly on the stand while talking about the early days of Theranos.

“I met with everyone I could who worked in pharma or knew someone who worked in pharma to try to understand what they did and what they might be interested in,” she said. As a young tech founder, Holmes became known for her signature black turtleneck, deep voice and blonde bun. On the stand Friday, her voice seemed not quite as deep as in her many media appearances as Theranos CEO. She wore a dark blazer and white shirt with her hair down.

It was the first time the jurors heard directly from Holmes, though they have previously listened to recordings of a 2013 meeting Holmes held with investors and seen TV clips of her talking about the company.

It had been uncertain if Holmes would testify on her own behalf. It could be a risky move, outside lawyers say, but might be worth it to help the defense support its case. The government must show that Holmes had the intent to defraud, but defense lawyers have argued that she made mistakes but acted in good faith.

Holmes is on trial for 11 counts of wire fraud and conspiracy to commit wire fraud for allegedly misleading investors and patients over the capability of her company’s blood-testing technology. She has pleaded not guilty.

The judge dismissed a 12th charge against Holmes on Friday, at the government’s request, because the court earlier ruled that the patient could not testify.

Theranos, a start-up Holmes founded in 2003 while she was a student at Stanford, endeavored to develop a portable machine that could run hundreds of tests from a few drops of blood pulled from a patient’s fingertip. It had a star-studded list of investors and board directors, including media mogul Rupert Murdoch and former secretary of state Henry Kissinger. It grew to hundreds of employees and became a media darling.

But in 2015, the Wall Street Journal published an in-depth investigation revealing significant issues with Theranos’s technology and workplace. The piece reported that the company was relying on outside technology to conduct tests, and results with their own technology were erratic. Theranos collapsed three years later, amid leadership upheaval and investigations from regulators.

On the witness stand, Holmes said she worked in the early years of the company to make connections in the pharmaceutical industry, and everyone she could to get the company off the ground. She said she was spending nearly all her time at Stanford working on a possible company idea, so she decided to leave school.

During her first hour of testimony, Holmes spoke of a technology demonstration that Theranos employees gave to pharma company Novartis in its early years. Holmes wrote an email to the team after, congratulating them on a successful demo.

“We nailed this one. You all did an incredible job in making this happen - this is the theranos way,” she wrote.

An interview about the demo told in the bestselling book about Theranos, “Bad Blood: Secrets and Lies in a Silicon Valley Startup,” tells a different story. Reporter John Carreyrou wrote in the book that the Theranos device malfunctioned the night before the demo and employees had sent over a fake result from the California office during the live test.

Holmes is expected to continue testifying Monday.

Holmes’s case has been closely watched in Silicon Valley and across the country, spurring on multiple podcasts, an HBO documentary and a best-selling book.

The first witness the defense called on Friday was a paralegal at the law firm representing Holmes. Trent Middleton provided summaries of various Theranos records, including patents the company had obtained and the number of tests the company offered.

The defense’s second witness, Fabrizio Bonanni, served on Theranos’s board after media investigations started and served as a a director from May 2016 until September 2018. Bonanni, a former executive vice president at biotech company Amgen, said he learned details about the Theranos device in 2016 in meetings with the company and was impressed.

Holmes originally asked him to become the company’s chief operating officer, but Bonanni declined, saying he was “too old for that.”

Instead he joined the board and during his time there, he advised Holmes and the company on improving quality control and compliance.

The lengthy Holmes trial was scheduled to last 13 weeks, but the judge notified jurors Friday that it could probably stretch longer.

Judge Edward J. Davila told jurors Friday morning that the trial probably would not end by Dec. 6, the date jurors had been told previously. The judge also told the lawyers before the jury was brought in that he had the sense that none of the parties wanted the trial to extend to the Christmas holiday week, which could cause scheduling or other issues with jurors.

Holmes’s defense team has conducted lengthy cross examinations of many of the prosecution’s witnesses, often stretching their questioning even longer than the government’s direct examination. Prosecutor Jeff Schenk pointed out to the judge that the defense had so far spent more hours questioning witnesses than the government.

The government spent weeks calling former employees, investors and patients to the stand. Former employees laid out significant issues they had while working at Theranos, including concerns over quality control and inaccurate test results. Investors expressed disappointment, and said they would have reconsidered their interest in Theranos had they known of the company’s reliance on third-party machines and inconsistent results from its own machines.

“It would have tempered my enthusiasm significantly,” former defense secretary Jim Mattis said on the stand in September, in response to a prosecutor’s questions about the use of third-party devices. Mattis served on the company’s board from summer 2013 to fall 2016.