The insanity defense applies to a criminal suspect who isn't responsible for their criminal actions because of their mental illness. When you invoke the insanity defense, you are basically saying that you are too mentally ill to distinguish between right and wrong (or legal and illegal). There are several variations of the insanity defense; here are two classic examples:
This defense applies if you were insane when you were committing the criminal act, but you are now sane. Proving that a sane person was insane at one point in time isn't easy. You need to prove a temporary mental disorder that might not even have left some symptoms. In most cases, a psychiatrist needs to perform a postmortem of the symptoms you exhibited at the time of the incident to determine whether they resembled those of an insane person or not. Identifying what might have caused the temporary insanity may also help with the diagnosis. This is why temporary insanity isn't a common variation of the insanity defense. If you succeed with the defense, you will be acquitted and you will not need to go to a treatment facility if it is confirmed that you are no longer insane.
Automatism isn't insanity in the strict sense of the word, but it also relies on the mental state of the defendant as well as their intention. By using the defense of automatism, you are telling the court that your mind wasn't in control of your body at the time of the incident and that you performed the alleged act automatically.
For example, when you sleepwalk into a neighbor's house and they accuse you of trespassing, you can succeed with the defense of automatism if you can prove that you were really sleepwalking at the time. This defense succeeds because the law isn't meant to punish people for doing things beyond their control (involuntarily). As such, you can only succeed with the defense if you did not voluntary initiate the cause of your automatism. For example, you can't claim automatism after taking mind-bending drugs that send you into a crazed and violent state and attacking people randomly.
The insanity defense is complicated and costly; you will need an expert witness to convince the court of your claims. However, it can get you acquitted of all your charges if you succeed. This is one approach you should only try only if your lawyer is convinced of its viability. For more information, contact a local attorney.