The royal title held by his father and grandfather however passed to Count Henry VII of Luxembourg, who was elected by six of seven votes, contrived by the mighty Archchancellor Peter of Aspelt, elector and prince-archbishop of Mainz, a fierce opponent of late King Albert.Both tried for the support by the Imperial States; Frederick was enfeebled by the fact that he had been crowned at the wrong place and moreover struggled with the rebellious Swiss Confederacy in the Swabian home territories of the Habsburgs, suffering a crushing defeat at the 1315 Battle of Morgarten.He nevertheless was able to hold his ground against the Wittelsbach rival and after several years of bloody war, victory finally seemed to be within Frederick's grasp, as he was strongly supported by the forces of his younger brother Leopold I.Since the Pope and the prince-electors strongly objected to this agreement, another treaty was signed at Ulm on 7 January 1326, according to which Frederick would govern Germany as king, while Louis would be crowned emperor by the "people of Rome" under Sciarra Colonna in 1328.Frederick's gracious return to captivity inspired Friedrich Schiller to write his poem Deutsche Treue ("German Loyalty") and Uhland to his tragedy Ludwig der Bayer ("Louis the Bavarian").