a coffee grinder is used to grind whole coffee beans before brewing.