Johnson, who died in the incident, had told hostage negotiators he was angry about recent fatal shootings of black men by police elsewhere in the United States and that he wanted to kill white people, especially police officers.
Dallas Police Chief David Brown said the gunman "expressed anger for Black Lives Matter" and told a hostage negotiator he "wanted to kill police officers."
Police spent hours negotiating with Johnson before he was killed by an explosive strapped to a police robot.
"We're hurting," Brown said. "Our profession is hurting. Dallas officers are hurting. We are heartbroken. There are no words to describe the atrocity that occurred to our city."
Officials said earlier at least two gunmen were involved.
Three other suspects -- two men and one woman -- have been detained by police, Dallas Mayor Mike Rawlings said.
"I can tell you they're being pretty tight-lipped at this point," he said of the trio.
More on ABC News null