Police raided a cannabis farm just as the crop was being harvested, Lincoln Crown Court was told.
Officers arrived at the premises in the village of North Kyme where they searched outbuildings.
Edna Leonard, prosecuting, said that a caravan had been converted to grow cannabis with lighting and ventilation fans installed.
Miss Leonard told the court “There were three growing areas. One was a nursery.
“There was also dried cannabis which had been cropped and was in bags.”
Adam Marshall, who owned the property, was arrested and went on to tell officers that he had been growing cannabis to help with his depression and fibromyalgia.
Marshall’s son Harrison and another man, Julian Swain, had been assisting him to harvest the crop.
Miss Leonard added: “Adam Marshall said he started with six plants but the yield was far more than expected. He accepted that the vast majority of the extra cannabis would have been sold on.”
While searching the premises police also found an old unlicensed shotgun which had been given to Marshall to repair.
Adam Marshall, 54, of Ferry Lane, North Kyme, admitted production of cannabis, possession of cannabis with intent to supply, illegally abstracting electricity and possession of a shotgun without a certificate.
He was given a 12 month jail sentence suspended for 12 months.
Harrison Marshall, 24, also of Ferry Lane, North Kyme, admitted production of cannabis and possession of a shotgun without a certificate.
He was fined £1,000.
Julian Swain, 53, of Bath Gardens, Boston, admitted production of cannabis. He was fined £1,000.
Michael Cranmer-Brown, in mitigation, said that neither of the Marshalls had any previous convictions and Swain had been out of trouble for many years.
He told the court: “Adam Marshall was plainly the principal offender. He accepts he asked his son and his friend to harvest his first crop.
“The plants that came to fruition were cultivated by him and the other plants were still relatively immature.
“It was all to do with relieving pain from fibromyalgia. The medication he had been given did not work.”