Schools have alarm systems for a reason. You can get the exact same effect without sacrificing educational quality. You can set up dedicated active shooter pull alarms if you wish. And every classroom has a phone in it. You can have a system where a teacher enters a code on the phone, and an active shooter alarm throughout the building.
I just see a lot of backwards logic here. You're starting with your conclusion of "let students keep their phones," and then trying to find a reason to justify that.