With the rise of Holyroodhouse as a royal palace at the far end of Edinburgh's Royal Mile, the Castle returned to a primarily military function and place of safety for the Scottish royal family. It was in this role that Mary, Queen of Scots, sought the sanctuary of the castle in order to give birth to her son, the future James IV of Scotland (James I of England) in 1566. Following her forced abdication, the commander at the castle, Sir William Kirkcaldy of Grange, remained loyal to her, precipitating a siege by by James VI's regent, James Douglas, 4th Earl of Morton. Known as the Lang (Long) Siege, it lasted from 1571 to 1573. The siege was finally concluded with the assistance of English cannon provided by Elizabeth I. After bombarding the castle for ten days, Morton's guns destroyed both David's and Constable's Towers at the castle's gates. The collapse of David's Tower covered the castle's well, depriving the defenders of drinking water. Kirkcaldy was forced to surrender within days. Following the siege, the outer defenses of the castle were rebuilt, with the Half-Moon Battery replacing David's Tower. The new battery was completed in 1588. In front of the castle, is the Esplanade, built in 1753, which served as a drill field for the castle's defenders. Each August, the Esplanade is home to the world-famous Edinburgh Military Tattoo.


