Do writers always know what their characters will do next?
I can't answer for other writers but for me the answer is, "not always".
In my blog post, "Breakfast", I wrote about a turning point. Chief Sean Dermott, the protagonist in 'Camouflage', was developed to a point where I could 'listen' to how he would act. When this happened, it was possible for the story to take a slightly different direction.
In another book I am working on I knew how the book would end but I hadn't decided which character would make one particularly important move. It took writing three quarters of the story before I could make the final decision.
It's incredibly fun when the characters I'm creating--can still surprise me.