A man who attempted to rob a southside service station with a broken beer bottle will have a suspended jail sentence hanging over his head for the next two years.

As a child, Samuel Howard saw his girlfriend’s father shot dead before his eyes.

An ACT Supreme Court judge said the lasting trauma had left Howard with post-traumatic stress disorder and depression and triggered a troubled period in his life.

Justice Hilary Penfold sentenced Samuel Howard to 15-months jail, with the full-term of imprisonment suspended.

The 22-year-old was ordered to enter a two-year good behaviour order and provide $500 surety.

Howard had pleaded guilty to the charge of attempted aggravated robbery from an incident in February 2010.

Police arrested Howard after he was identified through CCTV footage.

The attempted robbery was caught on the security cameras at the Mobil Erindale petrol station.

Howard approached the service counter and demanded cash from staff.

He then attempted to climb through the wire security barrier while threatening staff with a broken bottle.

Staff members grabbed his arm and pushed him off the counter.

Howard gave up and left the service station.

In handing down sentence, Justice Penfold said Howard had been drinking and using drugs on the day of the incident.

Justice Penfold took into account Howard’s history of mental illness but noted he had not handed himself in, did not make a complete admission to police and left his guilty plea until late.

But the judge said she saw only disadvantages in sending Howard to jail.