Lewis Vaughan, from Leith, watched as the special Virgin service chugged into the station this morning, with the legend #LforLewis painted on its side.
The 32-year-old was diagnosed with testicular cancer, secondary lung cancer and a number of brain tumours last April, before being told a few weeks ago that he only has a short time left.
But his painful ordeal has sparked a global social media campaign after he started posting selfies online wearing different hats, in a bid to put a tongue-in-cheek spin on his hair loss.
One picture, of Lewis making an “L” shape with his finger and thumb, quickly caught on with friends and family who started posting their own photos making the L shape.
The #LforLewis hashtag has now been shared thousands of times on Twitter and a Facebook page has so far attracted more than 2000 members.
In just four weeks it has raised more than £3000 for Marie Curie and helped Lewis buy an electric wheelchair to assist his mobility.
Today, he was visibly moved as his dedicated train arrived at Waverley at 11.17am to the sound of bagpipes, before departing for London King’s Cross.
Friends revealed he had suffered a seizure that morning, but had been determined to attend the unveiling regardless.
Speaking to the News, Lewis, who previously worked as a customer information assistant for Virgin Trains East Coast, said he had found the public reaction to his campaign “overwhelming”.
He said the fundraising drive had helped him cope with his terminal illness and cancer treatments, adding: “The generous nature of the human race has been overwhelming, and the generosity of those on Facebook has been a really powerful thing.”
He said: “If anything, I feel a little bit guilty that there are other people suffering that are not getting the same kind of attention as myself.”
To mark this morning’s occasion, Lewis wore a baseball cap that was originally worn by actor Russell Crowe during the filming of Robin Hood, before being sold to a friend who was an extra in the film.
He described having a train dedicated to him as a “surreal” experience, joking: “My ego has been more than appeased.”
Friend and colleague Adrian Bayne, from Prestonpans, said Lewis’s campaign had now raised £4700 in total, with more than 700 people sending in their own selfies - including big names such as Susan Boyle and retired footballer Gary McAllister.
The train driver said: “Lewis has united a workforce in his courageous fight with cancer. He has been a good friend and it’s been an honour to help him with the Marie Curie fundraising.
“None of this could have been done without the tremendous support from the railway family and the members of the public who have backed the #LforLewis campaign.”
Dad Jim, 69, who was at the unveiling with Lewis’s step-mum Maybeth, said: “I want to pay tribute to my son Lewis and the way he’s battled this disease so bravely and with such humour.
“I also want to thank his colleagues at Virgin Trains for all the work they’ve done. Lewis has been through a tough time since last April and he’s handled it well.
“The response to the campaign has been overwhelming and Lewis has been overwhelmed by the whole thing. It started as a modest fundraising exercise but it’s snowballed and attracted national and even international attention.”
Passengers from across the country are now being encouraged to donate £1 to Marie Curie and post a picture of the train as it passes through their station.
The service will operate on Virgin Trains’ east coast route for a further month in a bid to raise as much money as possible.