There were four people on board the police helicopter at the time
A father-of-three has narrowly escaped an immediate jail sentence for shining a laser pen at a police helicopter for 10 minutes as it hunted a suspect.
Adrian Blake's prank was branded as "horrendously dangerous" by a judge at Cardiff Crown Court who said it could have had "catastrophic consequences."
The pilot took evasive action to avoid being blinded as the green light bounced around the cockpit.
Blake, 31, Bridgend, was given a 26 week suspended prison sentence.
He was also ordered to carry out 300 hours unpaid work and will be tagged to obey a curfew between 2000 and 0600 GMT for three months.
The court heard he was playing with the green laser at his home at Bryncethin as it became dark in September last year while the South Wales Police helicopter hovered at 1,500ft with four people on board.
Blake admitted endangering the safety of an aircraft.
Prosecutor Julian Greenwood said: "The crew felt they were being deliberately targeted."
On-board cameras focused on Blake and officers on the ground arrested him in his back garden where he was still holding the pen.
He told police he was trying to see how far the beam reached.
Recorder of Cardiff Judge Nicholas Cooke QC said: "This was an act of incomprehensible selfishness.
"You placed the lives of four people in that helicopter at risk and, as this was an urban area, also risked the lives of people on the ground."
Blake wept in the dock as the judge told him his family saved him from immediate jail.
The judge added: "Your wife has written to me asking me not to damage her family life.
"You have three children all doing well at school. You're the breadwinner and their futures would be blighted by me imprisoning you.
"But for the rest of your life you need to know you could have left children just like your own fatherless."
Speaking after the case, South Wales Police air support unit Inspector Gary Smart said: "Shining a laser at an aircraft is extremely dangerous and puts lives at risk.
"We take this extremely seriously and will continue to take action to prosecute anyone carrying out this offence."