If a traveller - for whatever reason, is arrested on charges (valid or otherwise), what steps should he/she take to ensure their safety, local and home legal aid and security? How can one make sure your family and country knows about the situation? What if you don't understand the language, or what the charges are?
The level of support offered by embassies will vary widely from each foreign embassy / consulate to another. A couple of standard support measures provided though are:
Probably more important than what they do provide is what they don't provide. Embassies do not directly provide legal assistance, immunity, or evacuation just because someone is in trouble with the police. If caught in such a situation, it's necessary to manage expectations on what an embassy can do realistically.
While it isn't always possible to know the local laws of a country, not knowing you did something wrong is rarely ever a valid excuse. Use common sense - and as a rough yardstick don't do anything illegal in your own country - for starters. This is especially problematic if you're travelling in regions police officials are known to be corrupt as they could use legitimate less-known laws or made-up charges to shake you down. Embassies will rarely, if ever, provide assistance in these situations unless something seriously goes wrong.
Another thing that can help you receive assistance quickly is your country's embassy offers any form of registration programme, so that they know your details. Probably not very useful or even necessary for short-term travellers though.
During the Cold War (and probably continuing to this day), Russian spies were taught to say, "Call the the Soviet Consulate," or "Call the Soviet Embassy," when caught. While undergoing training, they were tortured to induce them to say more than that. If they said "more," they flunked the course, were kicked out of the program (and lost their main chance to travel abroad). Instead, they were supposed to go on and on with the one theme like a broken record.
That's a bit melodramatic, but that's the basic idea. A prisoner of war is not supposed to give out more than his name, rank, and serial number. Under the circumstances, you are a "prisoner," and not of war. Just state your citizenship, particularly if American, Chinese, Russian, or that of any other superpower, and call for the "cavalry" (your embassy or consulate). Try not to say anything else, your name, local address, or ever admit that you were at such and such a place at such and such a time. The one exception is a if a "policeman" stops you, and says, "pay a small fine, and I'll let you go."
Your consulate/embassy can't "spring" you from captivity. It can, however, make sure that you have access to (local) legal representation, and are treated "fairly" in accordance with the laws of the country and the facts of the case. It will also set up a line of communication with your family and friends at home.
The arrest, trial, conviction, and recent release of American Amanda Knox in Italy illustrates the importance of following these rules. She almost got herself "put away" for 26 years, making (admittedly coerced) "confessions."
The first goal should always be: Do not get arrested in the first place.
If you travel common sense demands that you know the most important rules to obey. Traveling books and other information sources will inform you what is legal and illegal and what is polite behavior. This gains importance if you are moving in another culture and it even more important if you are visiting a Third World country. In the latter case I think it is necessary to look up how authority figures (police, military) are looking (to avoid falling prey to impostors) and how much power they really have over you (often frighteningly much !)
So you have done nothing (?) and then an $AUTHORITY_FIGURE appears and says:"Hey, you !".
Things you should NEVER EVER do:
The right behavior is, to complete the last action, withdrawal with a plausible reason for denial: You continue with whatever you are doing without visible interruption because you...ahem...did not notice him. You walk away or if you are moving in his direction, look for whatever may be interesting (women/cars/buildings) to break eye contact. It really helps if you are already in a car, driving, and the environment is noisy.
But unfortunately it cannot be avoided mostly: You are surprised, you look at him, he is already in vicinity and he repeats with so much intensity So you cannot try to withdraw.
So the next step is to avoid conflict. Look at him/her and get a first impression. How does he/she look at you ? Wary ? Disrespectful (especially if you are a woman) ? Posturing ? Or greedy/sizing you up (you will recognize this look very fast) ?
Stay always calm and polite. You are like a British butler which cannot be disconcerted. You are addressing with him as "Sir" or "Officer", ideally with his rank if you can discern it (you can also ask for it with interest). Always ask at least for his name (it depends on culture what fits for police/military, in the Western countries it is the surname) and address him with it (The name is the most loved word for everyone).
The strategy now depends on how the $authority behaves and how do you judge the situation. Remember: You as tourist have nothing personal with him/her, so there must be another reason.
But everything was futile now. You are detained.
In that case the first address is your consulate or embassy to inform your country (and the family and friends). They could also provide addresses of lawyers. So insist repeatedly to contact your embassy. If you see a foreign witness during or after the detention, ask him to contact the embassy with your name.
The best defense now is surprisingly easy: SILENCE. Everything you say now can and will be used against you. They will try to get something out of you to justify detention, so I state it clearly: Nothing what they promise, nothing what the very nice policeman (Good cop, bad cop) is assuring you has any merit. You will say something until your consulate/lawyer will turn up, until then they get nothing because you do not understand the exact cause of detention (when in fact you do).