THOMAS Kingo. No? The name might well mean something if you happen to be Danish or Faroese, or if you come from Crail in south-east Fife. Kingo (1634-1703) was an archbishop and poet whose two collections of sacred songs, the Aandelige Siungekoor, are still at the heart of today’s Danish church services. As a wordsmith he was a great one for lurid imagery: his texts are full of technicolour baroque poetry – "the pornography of penitence", as John Butt has so brilliantly described equivalent gore and guts in the texts that Bach chose to set.

Also like Bach, who wrote church music using his own German language, Kingo wanted to create a pure Danish Christian vernacular. He wanted to encourage the religious faith of his countrymen by letting them pray in their own everyday tongue. And to appeal to the widest possible audience, he set his texts to the biggest pop tunes of the day, choosing well-known music from all over Europe, no matter whether it was sacred or secular to start with, or even if it came from rival churches. Rind nu op i Jesu Navn (“Break now forth in Jesus’ name”), for example, is sung to a tune from a racy opera-ballet by Jean-Baptiste Lully, court composer to the Catholic Louis XIV. The modern equivalent would be Justin Welby writing hymns to Beyonce hits.

What most Danes probably don’t know about the man who shaped the sound and language of their national church tradition was that he came from humble craftsman stock in small-town coastal Scotland. The handloom weavers of Crail were a proud guild that thrived for about 300 years from the 15th century onward. The Kingo family had a particularly strong reputation, and they traded from houses on the south side of Marketgate – look closely and you can still see a marriage lintel bearing the name.

In 1586, a certain Thomas Kingo emigrated with his wife Agnes Brown and their young son Hans. “One member went to Denmark and became a tapestry weaver to the King of Denmark,” says the Crail museum, demurely, but it seems that Kingo rose to such repute as a artisan that when King James IV of Scotland visited Helsingoer, he stayed at the weaver’s home. Young Hans didn’t do quite so well as his dad. He studied linen and damask weaving and set up a modest business of his own, but it was his son who would make the family name truly famous. Thomas Kingo, future hymnwriter, was born just before Christmas in 1634.

This is the cross-sea story that has inspired a new piece of music called Chrysillis for this year’s East Neuk Festival. Henning Sommerro is a Norwegian keyboardist and composer who has worked across folk, pop and classical music. Fans of Aly Bain might remember Follow the Moonstone, the fiddler’s 1996 fusion album with the (then) BT Scottish Ensemble, for which Sommerro arranged various traditional tunes from around the North Sea. There’s a similar concept behind Chrysillis. The name comes from one of Kingo’s graceful love songs (Chrysillis du, mit verdens guld : Chrysillis, thou, gold of my world) and the personnel draws together a Scottish-Norwegian miscellany of Mr McFall’s Chamber, fiddler Chris Stout, harpist Catriona McKay, hardanger fiddle player Nils Okland and bass player Mats Eilertsen.

“It’ll be in four parts,” Sommerro tells me, a deadpan voice down the phone from Norway. “The Scottish part will involve tunes from Fife. A reel.” He sings it; it sounds slow and rather mournful. “Then the second part, when Kingo’s family comes to Denmark. Here I use a theme from Denmark – a traditional hymn tune from the 17th century that has a text by Kingo.” Could he sing that one? He hums a simple chorale melody.

“Then the third part. This bit is a bit more personal,” he explains. “You see, when Kingo got his first job as a priest, he fell in love with the Norwegian-born Sille Balchenborg who was wife of the previous priest. Eventually he married her. He must have been very in love because he wrote a lot of love poems for her. I happen to come from the same part of Norway where this woman came from. So in this part of the piece I have used a Norwegian theme mixed with a hymn from my district.”

And the fourth part? “Ah,” he says. ”The finale. You’ll hear all the themes intertwined.” So far, so symbolic. “I hope it’s just music,” Sommerro adds. “I hope it’s not a lecture. It’s not necessary to know the story, but for me it was fun to use the narrative to shape the piece.” He says he admires Kingo’s hymns because “they’re not pious; they have a power; there are wonderful images of the sun and the mountains. He must have had a very good imagination… He wrote about mountains but he never went to Norway and Denmark is very flat. Sille must have told him!”

As for the way he has written for the various musicians involved? He promises to leave “lots of space for them to do their thing – it’s easier for Chris and Catriona than it was for Aly. Back then I wrote in a certain way so that he could play like he always plays. I suppose it was a stricter sense of tradition. With Chris and Catriona, with Nils and Mats… I felt a lot more free.”

In the Footsteps of Thomas Kingo premieres at Anstruther Town Hall on Sunday, part of the East Neuk Festival.