The scheme, one of only half a dozen in the country, will help tackle the causes of climate change and help Wales meet national renewable energy targets as the electricity generated feeds into the national grid.
It will also help reduce farmyard smells as the 12,000 tonnes of manure - enough to fill the Millennium Stadium pitch to a depth of five metres - will no longer be hanging around, but burnt quickly to generate power.
The project, by DW Thomas and sons, of Great House Farm, Llanmaes, Vale of Glamorgan, involves building a biogas plant at Pancross Farm, Llancarfan, which is in the Nant Llancarfan Special Landscape Area and the Llancarfan Landscape of Outstanding Historic Interest.
The plant will turn manure, slurry and maize silage into biogas for electricity generation. It will generate enough electricity to power a small village through the national grid and keep the plant operating around the clock. Some residents in the area, who have compl1ained about smells from the farm in the past, again expressed concerns about the possible smells and risk of pollution from the development.
Llancarfan Primary School also expressed concerns over possible health risks from fumes or smells, particularly to children.
But project manager Christopher Hanks said the idea for the operation was partly the result of talks with the Environment Agency on tackling the odour problem.
He said: "It will help us to remove smells at the farm, which have been a problem in the past.
"It will reduce the slurry storage period from six to four hours and it will be pumped directly into the feedstock pump, rather than stored in the existing open-air lagoon."
Rob Quick, the Vale council's director of environmental and economic regeneration, said there had been no complaints about the farm for more than 18 months.
He said: "National policy guidance clearly favours small-scale renewable energy enterprises, subject to appropriate environmental controls, and concludes that these may be appropriate on farms."
He said the renewable energy benefits of the scheme outweighed concerns about noise and smells which could be controlled by appropriate conditions.
Mr Hanks said: "It will also help meet UK and Welsh Government renewable energy targets. These operations are 95% efficient, which is far more efficient than wind and solar energy generation.
"It will produce 540kw thermal output, or heat, which will be used to heat the slurry, manure and maize up to optimal heat for gas production, and used by the dryer to process dry matter so that it can be used as cow bedding to the 700 to 800 cows on the farm."
HOW IT WORKS The biogas plant consists of two basic components: a digester (or fermentation tank) and a gas holder.
The digester is a cube-shaped or cylindrical waterproof container with an inlet into which the fermentable mixture is introduced in the form of a liquid slurry. The gas holder is normally an air-proof steel container.
When the digester is partially filled with the slurry, the introduction of slurry is stopped. The anaerobic bacteria present in the slurry decomposes or ferments the biomass.
As a result of anaerobic fermentation, biogas is formed, which starts collecting in the dome of the digester.
The energy is then burnt and turned into electricity.
The gas valve connected to a system of pipelines is opened when a supply of biogas is required.
To obtain a continuous supply of biogas, a functioning plant can be fed continuously with the prepared slurry.
As more and more biogas starts collecting, the pressure exerted by the biogas forces the spent slurry into the outlet chamber.
The spent slurry is manually removed from the overflow tank and used as manure for plants.