A CHEMICAL engineering graduate turned to growing cannabis to solve his problems with migraine and insomnia, a court heard.

The Phd student downloaded information from the Internet to discover how to grow the plant having tried in vain to get tablets from his doctor to deal with his migraine.

But Gareth Barnes' attempts at self-medication came to an end when his home was raided by the police.

Yesterday, Barnes, 27, of Ruby Street, Middlesbrough, appeared before Teesside Crown Court and admitted cultivating cannabis.

Judge Tony Briggs sentenced Barnes to 12 months imprisonment suspended for two years. He was also ordered to pay £450 costs.

Michael Bosomworth, prosecuting, said police executed a search warrant at Barnes' home in Sandmoor Road, New Marske, in February, and he immediately told them about the plants growing upstairs. There were mature plants and there was a sophisticated lighting and irrigation system.

There was also a cupboard under the stairs where 32 smaller plants were growing which were to be the next batch.

Mr Bosomworth said that if cannabis from the plants had reached the open market it would have been worth about £5,700.

Tim Roberts, defending, said for three days at a time Barnes was unable to get any rest from the migraine and turned to growing cannabis in desperation.

Mr Roberts said: "He assessed the medical risks carefully, but ignored the legal risk and the jeopardy in which he has placed his own liberty and his relationship with his girlfriend."