A ball peen hammer, with its round and flat ends, is primarily used for metalworking tasks, including shaping, forming, and riveting metal, as well as striking punches and chisels.