The photographers rights topic has lately become a hot issue worldwide. Bob Atkins sheds some light on the U.S side of things:
"In general when dealing with the police, the best advice to minimize your problems is to be polite and cooperative (at least up to a point). If you're loud, argumentative, combative and refuse to assist in any way, you may be in the right, but you'll likely be arrested for something and have to spend a time and
money defending yourself in court. Unless you are driving, you do not have to provide any ID information to the police."
Link