Image copyright NASA

As the first American to orbit the Earth, John Glenn became a national hero.

His achievement restored some pride to the US after first Yuri Gagarin and then Gherman Titov had successfully put Russia ahead in the space race.

Like all of the original astronauts, Glenn had seen service as a military flyer before joining the space programme.

And at the age of 77, after a career in politics he did it all over again, becoming the oldest person ever to travel into orbit.

Flunked engineering

John Herschel Glenn Jr was born in Cambridge, Ohio, in July 1921, the only son of a master plumber and a schoolteacher.

He went to the local high school, which now bears his name, and then to college where he studied engineering.

Image copyright US Marine Corps Image caption He saw action in World War Two and Korea

He failed to complete the course which would have led to a Bachelor of Science degree although his college awarded him one after his earth orbit.

He learned to fly just before America entered the war in 1941, and was commissioned in the Marine Corps in 1943.

He was a pilot in a Marine fighter squadron in the Pacific and again during the Korean War, when he gained a reputation for being able to attract enemy anti-aircraft fire.

I don't know what you could say about a day in which you have seen four beautiful sunsets John Glenn

After one mission he returned to base with more than 200 holes in the fuselage of his F9F Panther fighter.

He was posted to the US Test Pilot School in Maryland and in 1957 became the first pilot to complete a supersonic flight across the continental US.

Two years later he became one of six pilots selected for the fledgling US space programme following a gruelling series of physical and mental tests.

Glenn almost failed to make the final selection. He did not meet the required academic qualifications and was close to 40, the age that would have barred him from being considered.

Malfunction

On 20 February 1962, Glenn boarded the Mercury spacecraft Friendship 7 for a space journey that would last more than four hours and see him complete three orbits of the Earth.

There was concern over his safe return after instruments indicated a malfunction on the capsule but he splashed down safely in the Atlantic just 40 miles from the target area.

Image copyright NASA Image caption Friendship 7 carried him three times around the earth

To look out at this kind of creation out here and not believe in God is to me impossible John Glenn

His first words when he was lifted aboard a US destroyer were: "It's hot in there."

Glenn received a rapturous welcome which included a ticker-tape parade in New York and a personal award from President John F Kennedy.

However, this popularity proved to be a double-edged sword.

He wasn't permitted to return to space the following year, allegedly on Kennedy's orders, so Glenn turned his attentions to a career in politics in his home state of Ohio.

Loner

But he was to find that being an astronaut could be a disadvantage; people didn't seem to see him as a serious politician.

His first attempt to run for office in the Democratic primaries in 1964 failed after he was forced to give up campaigning following a fall.

But he was successful 10 years later when he won the primary and defeated the Republican incumbent to become senator for Ohio.

Image copyright Getty Images Image caption He failed in his attempt to secure the 1984 Democratic presidential nomination

You know, old folks can have dreams, too, as well as young folks, and then work toward them John Glenn

As a politician, John Glenn had integrity and an independent mind.

But he was a dull speaker and a poor organiser. He found it hard to delegate, and was something of a loner.

His attempt to win the Democratic nomination for vice-president failed in 1976 after a lacklustre speech at the party's convention.

And he lost out to Walter Mondale in his attempt to secure the Democratic nomination for president in 1984, a campaign that saw him run up debts of $3m.

He'd also had to fight off the negative image of himself as portrayed in the 1983 film, The Right Stuff, which was an account of the astronaut training programme.

Space comeback

Based on the book by Tom Wolfe, the film portrayed Glenn as an argumentative character and a poor team player

His campaign debts were one reason why Michael Dukakis decided not to have him as a running mate in 1988 - that and the fact that he, like Dukakis himself, lacked charisma.

In October 1998 Glenn, who had stood down from politics, was back in space at the age of 77 as part of the crew of the space shuttle Discovery.

Image copyright AP Image caption Three decades after his pioneering flight he went back into space

During his 218 hours above the Earth, he undertook experiments to examine the effect of space travel on his ageing body and allow comparisons with the data collected on his first flight, 36 years before.

But some commentators questioned the scientific value of this flight, which they felt was a political favour granted by President Clinton.

Once more he returned to a ticker-tape parade and a hero's welcome from a new generation of fans.

John Glenn, the astronaut, never lost his popularity.

He remained the man who had put credibility back into America's space programme and helped pave the way for the 1969 Moon landings.