The 18 Brumaire coup established a new Consulate government in France with three consuls - Sieyes, Ducos, and Napoleon, who became the first consul. A new constitution in 1799 granted Napoleon dictatorial powers. Napoleon established peace, a centralized administration, religious freedom, and the Napoleonic Code. He later crowned himself emperor in 1804 but his military campaigns after 1807 led to his defeat and exile in 1814.