During any encounter with a US police officer, under what circumstances would the officer have the right to force me to stop recording our encounter with my smart phone, and can he prevent me from retrieving my phone if I don't have it out already when the encounter begins?

I know that it's legal to record my encounter with an officer in the US, I'm just curious about what excuse the officer could use if he wanted to force me to turn off the phone, and what situations he would legally be able to force me to stop recording. 

If I believe the officer may wish to violate my rights, do I have any legal ground to refuse to stop recording? Is there any particular way I can record in order to make it safe for the officer and still effective, so that I cannot be forced to stop recording? 

Perhaps a wearable camera would allow citizens worried about protecting their rights during police encounters to ensure their recording can't be legally stopped by an officer, even if the officer knows of that particular wearable device and doesn't want to be recorded?