A lawyer once phrased it as "you can beat the rap, but you can't beat the ride". The time to fight an arrest is in court after, not screaming or fighting on the street. If you are unlawfully detained, file a grievance or lawsuit or whatever after the fact.
Obviously being poor hurts the ability to hire a lawyer to defend against charges and/ or go after an officer that has overstepped his bounds, but there are plenty of oversight committees and organizations.