So the Lord was angered by the people sinning against Him and told Moses that He desired to destroy them and make a nation from him. Moses reminded that Lord of His promise to Abraham, Isaac, and Jacob. Moses descended the mountain and with anger he throw down the stone tablets breaking them. Then with the help of the Levites 3000 were killed in the camp.
Moses went up on the mountain to give himself to God as surety for the people. The Lord said, "I will be gracious to whom I will be gracious, and will show compassion on whom I will show compassion." ((33.19). Moses was not acceptable as surety, but this is a for telling of the One who is, Jesus Christ.
Moses asks to see the Lord and He told Him that He would proclaim His name and that Moses could see His back, for no one sees His face and lives. "Then the Lord passed by in front of him and proclaimed, “The Lord, the Lord God, compassionate and gracious, slow to anger, and abounding in lovingkindness and truth; who keeps lovingkindness for thousands, who forgives iniquity, transgression and sin; yet He will by no means leave the guilty unpunished, visiting the iniquity of fathers on the children and on the grandchildren to the third and fourth generations.”(34.6-7). This brings up the greatest question in all of scripture. How can God forgive the sins of unrighteous men and yet not leave the guilty unpunished? The only answer is the cross of Jesus Christ.
So Moses writes the covenant, the Ten commandments on two stone tablets. He tells the people to give gifts for making all the things that the Lord God had instructed Moses to build.
New American Standard Bible. (1995). The Lockman Foundation.