Soldiers have been describing the moment an Apache helicopter opened fire on their compound, killing their colleague Chris Roney from Sunderland.
An inquest into the 23 year old's death heard how explosions like small cluster bombs began going off inside their Afghanistan base.
Lance Corporal Christopher Roney of 3rd Battalion The Rifles, died from head injuries he suffered while serving at Patrol Base Almas, in Sangin, Helmand, in December 2009.
As night fell, the base was rocked by a huge Taliban bomb and the platoon based there were fighting off an attack when two US gunships were called in to help.
But they fired on the base, despite the flagpole, machine gun, barbed wire and men in uniform, thinking it was an enemy position.
Rifleman Denver Fedee was inside Almas shooting at the enemy when the helicopter's fire rained down.
He told the inquest in Sunderland Civic Centre: "I saw red splashes of explosion.
"I had never seen it before and I was wondering what was happening.
"When it started a second time you could feel the sandbags bursting."
The sniper was hit in the arm and hand by shrapnel.
"By that time we were scared. [I thought] 'That's when you are going to die'."
Despite the onslaught from above, Rifleman Fedee and others continued to fire on the enemy positions.
Later, despite his injured arm, he helped stretcher some of the seven badly injured men.
Rifleman Alex Swinhoe, who was shooting from a rooftop, lost a leg in the Apache attack.
He told the hearing: "It came out of nowhere. I fell off the roof and onto the floor. I seemed all right. I couldn't feel anything, I just thought something must be wrong."
He was taken to the Ops room for medical attention where Lance Corporal Roney was being treated.
"I looked over and saw Chris lying there," he said. "He looked in a bad way."
The morphine given to Rifleman Swinhoe, then aged 18, made the situation "surreal", he said.
"It didn't look real to me. It was a bad night really," he said.
It was only when he was receiving treatment in Birmingham that he was told that the devastating fire came from a US helicopter.
"Some of the guys on R and R came to see us and told us it was an Apache helicopter," he said.
The Sunderland soldier, who has a prosthetic leg, is no longer with the Rifles and has transferred to a rehabilitation unit.
A statement was read out from Corporal Lee Brownson, who died in an IED explosion a month later.
He was posthumously awarded the Conspicuous Gallantry Cross for his bravery in rescuing two men in the aftermath of the Taliban bomb on Almas.
His statement said he realised Apaches were attacking the base while it was going on as he had heard them before, and that it was a friendly fire incident.
"I was shouting that we had a blue on blue situation," he said.
"I could hear others were shouting the Apaches were firing into the patrol base."
As he made his way to the Ops Room, there were "scenes of chaos", and once there he saw staff were battling with a damaged communications system to get the message through to call off the helicopters.
Corporal Brownson heard shouts of "Man down" and attended to Lance Corporal Roney, who had been manning a corner of the base, known as a sanger.
"When I got inside the first thing I recall is an awful gurgling noise," he said. "He was not moving at all."
Corporal Emma Henderson, the platoon medic, said Lance Corporal Roney was unrecognisable when he was brought in for treatment.
"I talked to Chris throughout everything I did, I knew he could still hear even though he was unresponsive.
"He knew he was not alone and he was receiving the treatment that was required."
She stayed by his side until a specialist helicopter arrived to fly him to Camp Bastion where he died the next day.
Chris' brother, William Roney, told her: "On behalf of myself and the family, thank you very much."
Former Bombardier Philip Faulconbridge served alongside Lance Corporal Roney at Almas and told his family: "From the short time I knew Chris, he was a good lad, always up for a laugh, and it was an honour."