Can a book I am writing which tells about my crimes get me into trouble?
Anything you write in a book is a confession. If you include any crimes you have not already been charged with and tried for, you could be charged with the new crime(s) to which you effectively confessed in your book.
An important concept in American criminal law is what is known as "double jeopardy." This means that if you have already been tried for an offense and either acquitted (found "innocent") or convicted, you cannot be tried for it again. So, say you were tried for murder, but there was not enough evidence and you were acquitted. From a criminal law perspective, you could safely write about the murder and even confess to it but could not be charged and tried again for it. The authorities only get one chance at you, even if more evidence (such as a confession) appears later.
But that ONLY applies to specific crimes you were tried for, where the trial went to completion (e.g., it was not a mistrial or a voluntary dismissal by the prosecutor) and the court either acquitted or convicted you. Any other crimes--even other crimes occurring at the same time as the one(s) you were already tried for--are fair game. The authorities can charge and try you for those.
And worse: anything you write in your book about your crimes is a confession. As the saying goes, it can and will be used against you. So if you confess in your book to any crimes you were not already tried for, you can be tried for those new crimes and you will almost certainly (because of the confession) be convicted.
You could very easily disclose new or additional crimes. For example. Let’s say that you were tried for murder and acquitted. Let's suppose that murder was the only charge in that trial. If in your book, you wrote about how you used a gun to commit the murder, how you took the victim's wallet to make it look like a mugging gone bad, and how you lied to the police officers investigating the matter, you just confessed to possession of a weapon, theft, and perjury, and could be charged with all three.
Also, there is another legal system besides the criminal justice system: the civil court system, where lawsuits for monetary compensation are brought. Double jeopardy does not apply to the civil system, and because the civil system is separate from the criminal system, it is not bound by the outcome in the criminal justice system (just like the criminal justice system is not bound by the outcome of any lawsuit in the civil system). If you reveal information about your crimes in your book, your victims (or their families) can use that information to sue you--possibly for a great deal of money.
In summary: writing about your crimes can be a very risky proposition.