A refiner for grinding and homogenizing materials containing particles, including chocolate, compound, cacao, paints and inks, includes a set of rollers mounted in a frame, and a motor for driving at least one of the rollers and a sensor for measuring at least one parameter indicative of the particle size distribution in the material.