In 1387 Bishop Adhémar Fabry granted the town its great charter, the basis of its communal self-government, which every bishop on his accession was expected to confirm. The last Count of Geneva died in 1394, and the House of Savoy took over their land. In 1416 the counts became dukes, and kept trying to bring the city of Geneva under their control, often by making members of their own family to Bishops of Geneva. The city protected itself by joining the Swiss Federation ("Eidgenossenschaft"), uniting itself in 1426 with Berne and Fribourg.