One of the most famous musicians of the Middle Ages was not medieval. King David was remembered in medieval culture not only for his defeat of Goliath, but also for his musicianship. He was often depicted playing his harp in medieval art. Many of the psalms, which were meant to be sung, are attributed to David. David's career begins in the first book of Samuel with that prophet anointing him without the knowledge or consent of the reigning king, Saul. This poses a problem, however. David might be God's anointed king, but he has no army and no access to the court. Saul, who has lost God's favor, still has the infrastructure of kingship at his command. David is able to enter Saul's court because of his musicianship:
But the Spirit of the Lord departed from Saul, and an evil spirit from the Lord troubled him. And Saul's servants said unto him, Behold now, an evil spirit from God troubleth thee. Let our lord now command thy servants, which are before thee, to seek out a man, who is a cunning player on a harp: and it shall come to pass, when the evil spirit from God is upon thee, that he shall play with his hand and thou shalt be well.
1 Samuel 16:14-16
This is the first example of a common thread throughout ancient and medieval writings: music has power over evil spirits. The king's servants are convinced that when Saul's demon tormentors hear well-played music, Saul will be well and the demons will be banished. It is a practical cure to a real problem. There is no suggestion that hearing music will simply make Saul "feel better" and thus contribute to his general well being. The music is intended to confront the evil spirits directly. One of the servants suggests a possible musician: "Behold, I have seen a son of Jesse the Bethlehemite, that is cunning in playing, and a mighty valiant man, and a man of war, and prudent in matters, and a comely person, and the Lord is with him" (1 Samuel 16:18). David first enters the court of Saul because he is a musician who may bring relief from the torment of the evil spirits. David's music fulfills Saul's hopes: "And it came to pass, when the evil spirit from God was upon Saul, that David took a harp, and played with his hand: so Saul was refreshed, and was well, and the evil spirit departed from him" (1 Samuel 16:23). The music of David's harp has three effects upon Saul. The King is refreshed, showing the ability of music to change and effect the mood of the listener. Saul is relieved of his suffering, which exhibits music's healing power. Finally, the evil spirit is permanently exorcised from Saul. Music was also the medium that brought David, one of the most important figures of the Old Testament, to a position where he could gain the authority that God had ordained for him. Not through skill at arms, but through skill at music, David gained access to the court of the king.