Knox continued to preach around the country, but the years were catching up on him and he yearned for rest. Unfortunately, the death of Moray was heartbreaking for Knox and the end of his peace. It was a time of civil war. The Queen's supporters took Edinburgh Castle, so Knox had to leave in May 1571 for St Andrews. Although old and tired he still continued to fight for the Reformation from the pulpit. The latest danger was the introduction of Tulchan bishops. This idea was to appoint bishops who would receive a remuneration, but most of the income from their benefice went to the local lord. The whole idea of bishops was an anathema to Knox, and the draining away of funds from the Church was a disaster. Knox managed to delay this novelty until the year of his death. He did much good with the students at St Andrews, teaching and encouraging them.
Knox returned to Edinburgh in August 1572.
This is from an 1830 map that can be found online at the National Library of Scotland. Knox's house can be seen near the priory, marked '11'.
I am not sure if this building is the original one that John Knox lived in, but the rear view is very old. The building is part of a school.