Randy Travis pleaded guilty to driving while intoxicated Thursday in a case that began last summer when the country music star was found naked after crashing his Pontiac Trans Am.
Travis received two years of probation, a $2,000 fine and a 180-day suspended jail sentence. If he doesn't successfully complete the probation, he will face the jail time.
He was ordered to spend at least 30 days at an alcohol treatment facility, complete 100 hours of community service and have an ignition interlock device on any vehicle he operates while on probation.
Travis, 53, entered the plea in a court in the North Texas city of Sherman. The misdemeanor was punishable by up to one year in jail and a $4,000 fine.
As the singer walked out of the Grayson County Courthouse, he thanked the court and his supporters. He also acknowledged two patrolmen for "obviously taking care of me that night."
"I'm glad it's behind me," he said of the case.
Authorities have said a Trans Am registered to Travis veered off a road Aug. 7 near Tioga, a town about 60 miles north of Dallas where the entertainer lives. The car struck several barricades in a construction zone.
Prosecutors said Travis was found lying in the roadway naked and was belligerent at the scene and while being transported to a hospital. He had a blood alcohol level of 0.21. The legal limit for driving is 0.08.
The country star, whose hits include "Forever and Ever, Amen," walked out of jail the next morning wearing scrubs, no shoes and a baseball cap.
Travis also had faced a charge of retaliation for allegedly threatening officers, but as part of the plea agreement he will no longer face that charge.
Grayson County District Attorney Joe Brown said Travis' punishment is appropriate and "considerably more than is typically received on a DWI case."
"First time DWI defendants are rarely forced into in-patient treatment," Brown said in a news release. "He will be unable to leave the facility for 30 days. His fine and community service requirements are more than double what is usually received, and his probation term is the maximum available, and longer than the usual 18 months. All of that is appropriate in light of his behavior with the officers."
On Thursday, the judge in the case agreed with a defense motion asking that the arrest video and transcript not be released to the public.
Travis' lawyers have previously said the singer has a great deal of respect for law enforcement and has stopped drinking alcohol.
The August accident was among a string of recent run-ins with the law for Travis.
Police in suburban Dallas cited Travis following an Aug. 23 incident in a church parking lot in which he allegedly intervened in an argument involving a woman he knows and her estranged husband. Nobody was hurt.
Larry Friedman, one of his attorneys, said Travis pleaded no contest in that case in January. In an agreement with prosecutors, he got 90 days' deferred adjudication, meaning it will be removed from his record if he does not get involved in another assault in that time period.
Travis also was arrested last February in Denton County, northwest of Dallas, for public intoxication after police spotted a vehicle parked in front of a church and found an open bottle of wine and Travis smelling of alcohol. That case is no longer on file with the county court and appears to have been dismissed.