After achieving peace in Saxony in 780, Charlemagne returned in 782 and enforced a new code of law, the opposition to which began the middle phase of the Saxon Wars. After a hard fought struggle with Widukind, a Saxon leader, Charlemagne won in 785.
The conclusion of peace in Saxony in 780 paved the way for Charlemagne's return in 782, during which he introduced a new code of laws that sparked resistance and thus initiated the middle stage of the Saxon Wars. His ultimate victory over Widukind in 785 brought an end to the conflict.