Prosecutors say a taxi driver who claimed to be en route to kill the U.K. prime minister had a cache of weapons — including a machete, sword, stun gun and masking tape — when he was stopped by police.

Irfaq Naz was detained in July after driving the wrong way down a London street. A search of his car turned up weapons, and prosecutors say the 34-year-old told officers he was on his way to kill Prime Minister David Cameron.

Naz — who has been diagnosed as a paranoid schizophrenic — has admitted to weapons offenses.

At Teesside Crown Court in northeastern England, Judge Simon Bourne-Arton on Friday imposed a hospital order with a restriction meaning that Naz can only be released with government permission.