This was after the Lord had defeated Sihon and Og. Sihon was king of the Amorite people and lived in Heshbon. Og was king of Bashan and lived in Ashteroth and Edrei.
So Moses wrote down these teachings and gave them to the priests and all the elders of Israel. (The priests are the sons of Levi, who carry the Ark of the Agreement with the Lord.)
he said to them: “Pay careful attention to all the words I have said to you today, and command your children to obey carefully everything in these teachings.
They were in the valley near Beth Peor, east of the Jordan River, in the land of Sihon. Sihon king of the Amorites ruled in Heshbon and was defeated by Moses and the Israelites as they came out of Egypt.