Ian Joy, a 47-year-old crane driver, had left distressing messages on Facebook before he raced through Hartlepool.
He outran police for 22 minutes in his BMW X5 - including on the wrong side of a dual carriageway – and only stopped because he ran out of petrol, Teesside Crown Court was told.
The court heard Joy had been driven mad by head pains after suffering illness five years ago.
Buit doctors now hope that surgery in July could end his ordeal, said Stephen Constantine, defending.
He said that on July 18 last year Joy had driven to the Eston Hills, outside Middlesbrough, with the intention of killing himself but he could not go through with it.
He had drunk 10 cans of Stella and panicked when the police spotted him heading north on the A19 at 2.20am before failing a breath test when arrested.
Mr Constantine said Joy expressed remorse and added: ”There were an extraordinary set of background events to this which I hope could persuade you to take an extraordinary course and suspend any custodial sentence”
Judge Deborah Sherwin said: ”Fortunately it was the early hours and there were very little other vehicles around.”
Joy, of Catcote Road, Hartlepool, was given a 16-month jail sentence, which was suspended for 24 months, with 20 days of rehabilitation activities and 120 hours unpaid work and was also disqualified from driving for two years.
He pleaded guilty to dangerous driving and driving with excess alcohol.