A 19-year-old man who was killed in a gun battle with D.C. police in Northeast Washington on Tuesday night had run from officers conducting a sweep for weapons, law enforcement officials familiar with the investigation said Wednesday.

Darius Jamal Murphy shot at the officers, wounding one, who then returned fire, police said. Murphy, who lived in Southeast Washington, was shot outside his grandmother’s house in the Trinidad neighborhood, a few blocks from Gallaudet University.

The grandmother, Mary Murphy, 77, said she was upstairs when she heard gunshots that she at first thought were fireworks. She said she went outside and saw her grandson lying between two cars on the other side of the 1300 block of Queen Street NE. Murphy was pronounced dead at an area hospital.

“I just heard the guns,” said Murphy, who raised her grandson.

Murphy said that her grandson most recently lived with his girlfriend and that he returned to Trinidad to hang out with friends. Murphy said that she hadn’t seen him in weeks but that she believes he was trying to reach her house when he was shot. She said Murphy had attended Spingarn Senior High School, now closed, on nearby Benning Road.

D.C. police have not released many details of the shooting, which occurred shortly after 9 p.m. The wounded officer, who has not been identified, was released from the hospital early Wednesday. Police said they recovered a gun but would not say how many times either the officer or Murphy was shot or where on the body either was wounded.

Two police officials said officers were in the area Monday night to intervene in a separate incident between two men in the 1600 block of Levis Street NE. One of the men was shot by the other and the victim refused to cooperate, indicating that he would retaliate on his own.

The two officials said patrol officers approached Murphy and a group of men near Levis Street on Tuesday night as part of an effort to keep the neighborhood calm. Officers didn’t recognize Murphy, the officials said, and patted him down but found no weapons. A few hours later, police officials said, members of the gun-recovery unit approached the same corner. This time, Murphy ran, officials said, and the officers chased him to Queen Street.

In March, Murphy pleaded guilty to misdemeanor cocaine possession and was sentenced to nine months in jail. But records show that the judge put off imposing the sentence to give Murphy a chance. He was put on eight months’ probation, with the understanding that if he stayed out of trouble, the conviction might be vacated.

But Murphy was arrested again in August and charged with assaulting a police officer and possession of cocaine. Police said he was in the 1000 block of 16th Street NE, five blocks from his grandmother’s home, when officers confronted him. Murphy complained about being harassed, according to court documents, and police said they saw him holding two brown pieces of paper under his cellphone.

Police said he threw the paper on the ground and swung at an officer. The court documents say police found cocaine in the brown paper. A hearing in D.C Superior Court was scheduled for Dec. 13 on the new drug charge, and a hearing was scheduled for January on the probation issue from the earlier case.

Mary Murphy, who said she has lived in Trinidad all her life, confirmed that her grandson had been in trouble with police, but she knew few details. She said relatives are angry and feel that the shooting was unjustified, but she said she didn’t see the incident.

“I don’t know how many times my grandson was shot,” Mary Murphy said. “It was quite a few bullets.”

Get updates on your area delivered via email