Back to Milan.
Milan was now governed by Charles d' Ambrose in the name of his master Louis XII of France. Charles requested Leonardo's presence in the city, and by May 1506 he was once again working in Milan.
The nobleman Gian Giacomo Trivulzio set Leonardo the task of creating a monumental tomb to be located in the church of San Nazaro. Da Vinci was once again working on a large-scale commission that drew comparisons to his doomed equestrian statue for Francesco Sforza some years earlier. This period saw a marked increase in Leonardo's botanical studies once again highlighting the diverse nature of his intellect.
Like the Sfofza statue the Trivulzio monument was never completed, mainly due to fears of war against the French occupancy of Milan. In 1512 the French were finally driven out of Milan by an alliance between the Pope, Spain and Venice led by Massimliano Sforza, the son of Ludovico. So Da Vinci had worked for the Sforza family during his first period in Milan, fled when the French invaded, then changed his allegiance and worked for the occupying French. This did not endear him to the returning Sforza family and Leonardo, once again, decided to leave Milan.
Rome and France.
By September of 1513 Leonardo Da Vinci was in Rome. He was valued as an engineer rather than a painter, and was given the task of draining the Pontine Marshes around the city. Most of the commissions for paintings had been given to Michelangelo and Raphael, artists who seemed to be preferred by the Pope.
However, Leonardo was given a special dispensation allowing him to dissect bodies and continue his anatomical studies. The papacy had banned dissections, but it was believed that Leonardo was searching for the seat of the soul, seen as a worthy project by the church.
Unfortunately rumours were being spread that Leonardo was a sorcerer, these rumours led to the Pope banning all further dissections.
In 1516 King Francis 1st of France, offered Da Vinci a pension and a small chateau at Cloux on the Loire river. Leonardo was given the title of Foremost Painter and Engineer and Architect to the King of France and Technician to the State of France. He was a celebrity, admired and visited by the young King in his studio.
The artists health began to fail and he dictated his last will and testament on 23rd April 1519, Leonardo da Vinci died on May 2nd of the same year aged sixty-seven.