An Alameda man who contacted a 13-year-old Santa Rosa girl on a telephone chat line and attempted to meet her at her school settled his case Tuesday with a deal that includes his immediate release and no additional jail time.

Arnold Luz, 46, will be freed after serving 10 months under an agreement in which he pleaded no contest to two counts of child molestation for the August incident, said his lawyer, Deputy Public Defender Kristine Burk.

Luz had been in custody since his arrest on the Cook Middle School campus, where prosecutors said he drove from his hometown to molest the girl.

He was charged with 10 counts of child molestation and faced up to 26 years in prison if convicted at his trial, scheduled for sometime this summer.

But he reached an agreement with prosecutors and Judge Gary Medvigy to avoid further proceedings. He was to be released Tuesday and return Aug. 8 to be sentenced to probation and lifetime sex offender registration, Burk said.

Burk said the outcome is fair because Luz never intended to molest the girl and his only contact with her was by phone.