The origins of the ringing of the bells during the consecration date back to the time when the Mass was said in Latin and many of the words said by the celebrant were spoken in a low voice. Rood screens also became popular in the Middle Ages and many laity attending Mass had an obstructed view. The use of the bells was practical, it called people’s attention to the fact that the consecration was taking place.
Many of the practical reasons for the ringing of the bells no longer exist, however they are still a part of our liturgical tradition and still call wandering minds back to the altar. The reason that some parishes maintain the tradition and others don’t is that the ringing of the bells is optional (GIRM #150).