Michelle Carter (seated right) is on trial for allegedly encouraging her boyfriend to commit suicide.

TAUNTON, Massachusetts (CNN) — More than a month after Conrad Roy III ended his young life in July 2014 by inhaling carbon monoxide in his pickup truck, Samantha Boardman said she got a disturbing text message.

It was from a friend, Michelle Carter, 17, who had been Roy’s girlfriend.

And it said, in part: “He got out of the car because it was working and he got scared and I f—–g told him to get back in.”

What was apparently working was Roy’s attempt to take his life by inhaling the deadly gas in his black Ford F-150, according to testimony on the second day of Carter’s trial on involuntary manslaughter charges.

Boardman, who knew Carter from high school, also testified Wednesday that her then-classmate had sent an ominous text message the day before Roy’s body was found slumped in his truck with a portable gasoline engine in the back seat.

“Is there any way a portable generator can kill you somehow?” the message said. “Because he said he was getting that and some other tools at the store.”

Prosecutors argue that these and other texts are overwhelming evidence that while Carter, now 20, played the role of a loving and distraught girlfriend, she had secretly urged Roy to kill himself.

‘I have like no friends’

On Wednesday, Boardman and other classmates testified about exchanging texts with Carter about the defendant’s struggles with an apparent eating disorder, about her loneliness and feelings of worthlessness over not having friends, and about her “cutting” herself at times.

One classmate, Olivia “Livy” Mosolgo, testified that Carter sought to get the attention of girls who had stopped talking to her and lamented not having friends.

In one text, Mosolgo told the court, Carter asked her to stop complimenting her as “pretty” and “wonderful” because she wasn’t invited to parties.

“Livy, I have like no friends,” one text said.

“No one hangs out with me,” said another. “I’m alone all the time.”

Assistant District Attorney Maryclare Flynn said this week that when Roy had second thoughts that fateful night, Carter told him to get back in the truck and listened on the phone while he cried out in pain and took his last breaths.

“She mocked him when he chose to delay his death,” Flynn said in her opening statement before Bristol County Juvenile Court Judge Lawrence Moniz, who will decide the case. “She put him in the car that night.”

A large part of the prosecution’s case is based on a series of text messages from Carter that popped up on Roy’s phone on the final day of his life. One after another, prosecutors said, the messages appear to show her pressuring him to kill himself:

“You need to do it, Conrad.”

“You can’t think about it, you just have to do it.”

“Are you going to do it today?”

Suicide, not homicide, defense says

Carter’s attorney, Joseph Cataldo, has painted a starkly different version of events, describing Roy as deeply depressed over the divorce of his parents and a victim of physical and emotional abuse who was on a “path to take his own life for years.”

“This is a suicide case,” he said, “not a homicide.”

Cataldo noted the young’s man extensive online searches about suicide methods, Carter’s attempts to get him to seek help and her own bouts with mental issues.

“It was his choice,” Cataldo told the judge in his opening statement.

“She didn’t cause his death.”

A groundbreaking case?

Legal experts are watching the trial closely because it could set a legal precedent on whether it is a crime to tell someone to commit suicide.

Carter is being tried as a youthful offender because she was a minor when her alleged crime took place. She waived her right to a jury trial, meaning her case will be decided by Judge Moniz, who will render a verdict after testimony is over.

Roy’s death

Roy’s body was found July 13, 2014, in a Kmart parking lot in Fairhaven, nearly 40 miles from his home.

He was wearing a blue T-shirt, shorts and sunglasses, a since-retired Fairhaven police officer testified Tuesday as Roy’s relatives wept softly in the courtroom.

A cell phone was found in the waistband of his shorts. A gasoline engine was in the back seat. It was no longer running.

The day before, authorities say, Carter had urged him to go through with his plan to commit suicide.

“You’re ready and prepared. All you have to do is turn the generator on and you will be free and happy,” she wrote, according to a document disseminated by the Bristol County District Attorney’s Office.

“No more pushing it off,” she allegedly wrote. “No more waiting.”

‘He seemed fine’

Conrad was a troubled youth who had tried to kill himself in 2012 by overdosing on Tylenol, his mother testified.

But after he began taking medication and went to counseling, he seemed much better, Lynn Roy said. He graduated from high school in 2014 and was making plans for the future, she said.

Her son never talked about Carter and she rarely saw them together, she said.

On the day he died, she went to the beach with Conrad and his sisters, Roy testified. He was laughing and joking about other people on the beach.

“He seemed fine,” she said, although under cross-examination she added that her son later seemed “preoccupied.”

Roy said she exchanged some messages with Carter after her son’s death but the teen never mentioned that she had been in touch with Conrad on the day he died.

‘You fall asleep and die’

In the months following Roy’s death, Carter posted tributes to him on Facebook, calling him her “angel.” She also organized a charity softball tournament and raised $2,300 money for mental health awareness in his honor.

But Carter insisted on holding the event in another town miles from Roy’s friends and family, said Tom Gammell, who described himself as Roy’s best friend.

When he questioned her on the location of the tournament, she became upset and “wanted to make clear that she was getting credit” for organizing the event, Gammell testified Tuesday.

He said he had never heard Michelle Carter’s name before Roy’s death.

As police investigated the death, they found hundreds of text messages between Carter and Roy. In one, Carter allegedly counseled Roy on exactly how to commit suicide using carbon monoxide.

“If you emit 3200 ppm of (carbon monoxide) for five or ten minutes you will die within a half hour,” she reportedly wrote. “You lose consciousness with no pain. You fall asleep and die.”

Carter was indicted in February 2015. Her trial was delayed earlier this year at the request of the defense. Youthful offenders are tried in juvenile court, but the proceedings are public.