Police found a cache of weapons including a 950,000-volt stun gun in the car of a man who said he was on his way to kill David Cameron, a court has heard.

Irfaq Naz, 34, also had hammers, kitchen knives, a machete, an unsheathed Samurai sword and masking tape in his Vauxhall Astra when he was stopped in July after going the wrong way down a north London street.

Officers later searched his home in Middlesbrough and found the Downing Street postcode and the names of other prominent political figures.

The taxi driver was detained under the Mental Health Act, and last month admitted possessing a prohibited weapon, three counts of possessing an offensive weapon, seven counts of having a bladed article and dangerous driving.

Judge Simon Bourne-Arton, the recorder of Middlesbrough, imposed a hospital order with a restriction order meaning Naz can only be released with the permission of the home secretary.

Teesside crown court heard how he drove from Middlesbrough to London in the early hours of 16 July and by 4am had reached Kentish Town.

He drove his blue Vauxhall Astra the wrong way down Camden High Street, a one-way street, for three-quarters of a mile, causing oncoming traffic to take evasive action.

Police were called and tried to stop his car, but he carried on until he got caught in a jam at the junction with Euston Road.

Concerned he might attempt to drive on, officers smashed their way into his car and detained him.

"It was then that the defendant stated that he was on his way to kill the prime minister, David Cameron," Nick Dry, prosecuting, said.

"He was found to have a knuckleduster in his shirt pocket and an 18-inch hunting knife in the waistband of his trousers."

Police were concerned about his behaviour and found he had previously spent a month at Roseberry Park hospital, Middlesbrough, as a mental health patient.

Dry added: "A search of his vehicle revealed other weapons. "In the driver's door panel were three eight-inch kitchen knives. "Between the driver's seat and door was a samurai sword, its sheath found nearby in the passenger footwell.

"From the rear seat officers recovered a claw hammer, a lump hammer and an axe which were in a plastic bag that also contained masking tape.

"In the boot they found a machete and a stun gun, shaped as a knuckleduster.

"That device, a Blast Knuckles 950,000-volt stun gun, was found to be in working order and a prohibited weapon."

Naz, of Finsbury Street, Middlesbrough, also had four mobile phones and £1,200 in cash in the car.

Dr Pratish Thakkar, a consultant psychiatrist, diagnosed paranoid schizophrenia and said he posed a significant risk to others having acted on his delusions.

Naz, whose brother was in the public gallery, sat in the dock flanked by four mental health workers. He will return to Roseberry Park hospital.

Peter Wishlade, defending, said: "It is a tragedy, to put it bluntly, that this has happened to this family.

"Mr Naz, when he is taking his medication, is perfectly calm, rational, articulate and easy to talk to, but unfortunately when not, he is inclined to delusions and regrettably he has endeavoured to carry them out."

The judge felt his delusions, which included a desire to kill a world leader, posed a serious risk to the public.

Naz also believed the mayor of Middlesbrough, Ray Mallon, and others in the community, were going to kill him.

The judge disqualified him from driving for three years and ordered the weapons be destroyed.

Outside court, Steven Orange, the district crown prosecutor Durham Tees, said: "In the weeks before this incident Naz failed to take his medication which as a result has led to him having delusions.

"At the time of this incident he was therefore suffering from a major mental illness and his behaviour was undoubtedly influenced by the delusions he was having.

"His disorder will need psychological treatment in order to ensure compliance with medication and reduce the risk of him acting upon his delusions in the future."

Orange added: "It should be recognised that the sentence in this case is more about securing appropriate treatment for a man with significant mental health issues than punishment."