(Note: explicit sexual content)

Lawyers for accused child sex abuser Jerry Sandusky are allowed to enter expert testimony that the former Penn State football coach suffers from histrionic personality disorder, a Pennsylvania judge ruled on Friday.

The ruling by Judge John Cleland in Centre County Court opens the door for the prosecution, in turn, to have Sandusky undergo a psychological examination, raising the prospect that he could be evaluated as a pedophile.

The ex-coach faces 52 counts of abusing 10 boys, known in court documents as Victims 1 to 10. The prosecution wrapped up four days of testimony in the high-profile case on Thursday and defense attorney Joe Amendola expects to start calling witnesses on Monday.

The defense filed a motion on Monday asking that a psychologist be allowed to explain that letters Sandusky wrote to an alleged victim were consistent with histrionic personality disorder and he was not trying to lure them into sex.

People with the disorder are highly emotional attention-seekers who show inappropriate sexually seductive behavior. The prosecution has contended that the letters are part of "grooming behavior" toward victims by a sexual predator.

In his ruling, Cleland granted the defense motion and said Sandusky "shall make himself available to the Commonwealth for the purpose of preparing rebuttal psychological/psychiatric testimony."

The prosecution has entered as evidence letters Sandusky wrote to Victim 4. In one, Sandusky said: "I know that I have made my share of mistakes. There has been love in my heart. My wish is that you care and have love in your heart."

A State College psychologist, Alycia Chambers, said in a 1998 police report obtained by NBC News in March that Sandusky's behavior was that of a pedophile.

Penn State police asked Chambers and a second psychologist, John Seasock, to evaluate Sandusky's actions after an 11-year-old boy said he and Sandusky had showered together.

Seasock concluded there was no evidence of a sexual offense. No charges were filed.

Prosecutors allege Sandusky had physical contact with the boys over a 15-year period that ranged from tickling and a "soap battle" in Pennsylvania State University football showers to oral and anal sex.

Eight of the alleged victims gave often-graphic accounts of alleged abuse this week. Amendola has said they are out for money and underscored inconsistencies in their stories.

The abuse charges shook the university and prompted the firing in November 2011 of university President Graham Spanier and revered head football coach Joe Paterno.

In a separate case, two university officials also face charges of perjury and failure to report suspected abuse.

(Reporting by Ian Simpson; Editing by Anthony Boadle)