SOMERVILLE – A former Franklin Township police officer was sentenced to five years’ probation and ordered to attend Drug Court on charges of possessing heroin and driving while intoxicated while on duty in April.

Matthew D. Ellery, 29, of Middlesex Borough, was sentenced Friday by Superior Court Judge Kathy Qasim as part of a plea agreement reached in July with the Somerset County Prosecutor's Office.

Ellery, who forfeited his job as a police officer, also had his driver's license revoked for seven months.

EARLIER:Franklin police officer pleads guilty to on-duty DWI, heroin

If Ellery completes the Drug Court program, his record will be expunged. If he does not complete the program, he faces a potential prison sentence of three to five years.

State records show Ellery earned $45,542 as a police officer and enrolled in the Police and Firemen's Retirement System in September 2016. He was hired by the police department on Aug. 22, 2016, according to the prosecutor's office.

Ellery’s guilty plea and sentence stem from an on-duty incident about 1:08 a.m. April 7 in which Franklin Township Police Department communications tried to reach him by radio but he failed to respond.

Another Franklin Township Police officer was dispatched to Ellery's location and found his patrol car parked in the driveway of a Bennetts Lane business. The officer approached Ellery's patrol car and found him unresponsive in the driver's seat.

READ:Somerset County Prosecutor's Office takes over Franklin Police Department

The responding officer, who also is an EMT, determined that Ellery was experiencing an opiate overdose because he was cyanotic, had no carotid pulse, and was not breathing.

The officer removed Ellery from the vehicle and administered two doses of Naloxone to revive him. After receiving the two doses of Naloxone and before the officer could commence CPR, Ellery regained consciousness.

He was then transported to Robert Wood Johnson University Hospital in New Brunswick by EMS personnel.

Staff Writer Mike Deak: 908-243-6607; mdeak@mycentraljersey.com