A Bangladeshi immigrant convicted today of terrorism charges after setting off a pipe bomb in New York City's busiest subway station last December told the trial judge he was angry at U.S. President Donald Trump and didn't carry out the attack for the Islamic State in Iraq and Syria (ISIS).

The verdict against Akayed Ullah, 28, was returned in Manhattan federal court on Tuesday after a trial in which the defence maintained that he intended to kill only himself on Dec. 11, 2017. Nobody died and most of the injuries were not serious.

After the verdict was announced and the jury left the room, Ullah spoke out, telling the judge: "I was angry with Donald Trump because he says he will bomb the Middle East and then he will protect his nation."

I was angry with Donald Trump because he says he will bomb the Middle East and then he will protect his nation. - Akayed Ullah

Judge Richard Sullivan told him: "Right now is not the time for a statement."

Ullah's sentencing was scheduled for April 5, 2019. He faces a mandatory 30-year prison sentence and could be sent to prison for life.

Prosecutors on Tuesday said Ullah wanted to maim or kill commuters as part of a "lone wolf" terrorist attack on behalf of ISIS.

Officials placed Ullah on a stretcher into the back of an ambulance on Eighth Avenue between 42nd Street and 43rd Street, following the explosion last December. (Craig Ruttle/Newsday/Associated Press)

They disputed the defence claim, saying Ullah would not have worn a bomb had he wanted to kill only himself. They also cited social media postings by Ullah as well as comments he made after his arrest to investigators.

The verdict capped a weeklong trial that featured surveillance video of Ullah on the morning when his pipe bomb sputtered, seriously burning him in a subway corridor beneath Times Square and the Port Authority bus terminal where most subway lines converge.

At trial, Ullah was confronted with his post-arrest statements and his social media comments, such as when he taunted Trump on Facebook before the attack. The president later demanded tightened immigration rules.

Authorities said Ullah's radicalization began in 2014 when he started viewing materials online, including a video instructing ISIS supporters to carry out attacks in their homelands.

In closing arguments Monday, Assistant U.S. Attorney George Turner said Ullah told investigators after his arrest that he wanted to avenge U.S. aggression toward ISIS and had chosen a busy weekday morning to attack so he could terrorize as many people as possible.

Police blocked off the street in the Brooklyn borough of New York where officials said where Ullah was living the day of the pipe bombing. (Michael Noble Jr./Associated Press)

The prosecutor said Ullah, who lived in Brooklyn, followed the propaganda of ISIS online and wanted to follow its instructions to carry out a "lone wolf" terror attack on Americans.

"His goal was to injure and kill innocent civilians, to terrorize," Turner said.

The prosecutor said Ullah told an investigator after his arrest: "I did it for the Islamic State."

Amy Gallicchio, Ullah's court-appointed attorney, though said Ullah purposefully chose an isolated corridor to set off his bomb because he only wanted to commit suicide.

It was about martyrdom, not suicide. - Shawn Crowley, assistant U.S. attorney

"This is not a terrorist attack," she argued.

Assistant U.S. Attorney Shawn Crowley disputed the claim.

"It was about martyrdom, not suicide," she said.