Berndt, 62, was accused of blindfolding students, covering their mouths with tape and placing items in front of their faces, including live cockroaches and a spoonful of his semen.
As part of his plea agreement, Berndt will also be required to register as a sex offender for life.
"A school ought to be one of the safest places in America. This plea spares these young victims the anguish of testifying at a trial and sends an unmistakable message to those who would dare take advantage of our children that justice will prevail," said District Attorney Jackie Lacey in a statement.
The investigation into Berndt began in late 2010 after a film processing company contacted authorities about photos of children in a classroom with their eyes blindfolded and their mouths covered with duct tape. The alleged abuses involved 23 children between 2005 and 2010.
Parents of the victims had a chance to speak during the court hearing, telling the judge that Berndt ruined their lives.
"He's an animal, a perverse animal," one mother said through a translator. "I want justice to be done. You robbed my daughters of their innocence and of their childhood."
Defense attorney Manny Medrano said his client was remorseful for his actions.
"He taught for over 30 years, your honor," Medrano said. "He was a dedicated educator. He was well-respected by his teaching peers at that school. He was loved by many of (his) students and the parents of those kids, your honor. And indeed, since his date of arrest ... he's received a multitude of letters, supportive letters, from former students and the parents of those kids."
Medrano said while Berndt admitted to the lewd acts, he never touched his students inappropriately or sexually.
City News Service contributed to this report.