Although—in relation to the foreknowledge and decree of God, the first Cause—all things come to pass unchangeably and infallibly; yet, by the same providence, he orders them to occur according to the nature of second causes, either necessarily, freely, or contingently.
God has decreed all things. He knows them beforehand because he has decreed them. God is the first cause of whatsoever comes to pass. His plan cannot be changes and it cannot be altered. Providence is the execution of the decree of God.
Yet, he has ordered things to happen according to the nature of second causes. God uses means to achieve His ends. God decrees all things, but God does not directly “do” all things. He decrees evil but He does not “do” evil; they occur through second causes.
“A "second cause" is simply "a cause caused by something else." This expression is used in theology to distinguish between God as the ultimate cause of everything that comes to pass and the myriad smaller causes we see at work in the world.” (Philip Ryken, “Through the Confession,” reformation21.org)
Some things happen necessarily, according to the laws of nature. Some thing happen freely, like choosing to jump into the deep end of the pool. And some things happen contingently, they happen only if something else happens. I passed my mid-term because I studied all night. (1689commentary.org)
Let me run you though and example that I found on a helpful website. God decrees John Smith’s death. God has chosen to carry out that decree through the Providence of a collision with a tree. What are the second causes? The laws of nature necessarily hold; gravity and blunt force trauma; free agency in that John decided to ride his motorcycle in the storm; and the accident (can we call it an accident?) was contingent, or depending on, the tree rot that caused the tree to fall into the road.
God had ordered all things. And He ordinarily orders them to take place through means, or second causes.
All of this means that God is in complete control of all events, and we are fully responsible for all that we do.