The head of the IT department at a Suffolk school who used the school’s credit card to purchase thousands of pounds of computer equipment has walked free from court after a judge decided not to send him straight to prison.

Gerald Baalham, 41, who worked at Culford School in Bury St Edmunds, obtained £32,000 of computer equipment over a period of 18 months and sold some of it on eBay, Ipswich Crown Court heard.

Baalham, of York Road, Bury St Edmunds, admitted two offences of dishonestly abusing his position to obtain computer equipment between August 2012 and December 2013.

He also admitted being in breach of a 26-week prison sentence, suspended for two years, which was imposed in March last year for a £56,000 benefit fraud.

Sentencing Baalham to a two-year prison sentence suspended for two years, Judge David Goodin accused him of “spitting in the face” of his employers at Culford School who had chosen to keep him on after he was given the suspended sentence for benefit fraud last year.

Judge Goodin said Baalham had not used the money he obtained from selling the computer equipment to fund an extravagant lifestyle and accepted he had become trapped in a “vicious cycle” of dishonesty which he had found hard to break.

“It’s plain that you were in my judgement ill. You were under stress and you were dealing with a great deal more than your particular personality was able to deal with,” the judge said.

In addition to the suspended jail sentence, Baalham was ordered to attend a Thinking Skills programme and was given a 13-week curfew between the hours of 8pm-6am. He was also ordered to pay £20,000 compensation and a £100 victim surcharge.

Judge Goodin said that if he breached his second suspended sentence he could expect to go to prison.

Robert Sadd, prosecuting, said Baalham was head of the IT department at Culford School and was not a teacher.

In addition to purchasing computer equipment, which he sold on eBay, he had also purchased £1,000 worth of computer equipment for himself at the school’s expense.

Mr Sadd said the benefit fraud for which Baalham had been given a suspended prison sentence last year related to his failure to notify the authorities of a change in his circumstances while claiming Disability Living Allowance.

He said that when Baalham was questioned by police about the computer equipment fraud he had expressed surprise at the amount involved.

Claire Furlong, for Baalham, said her client had been employed as a technician at Culford School and had been “out of his depth” when he was promoted to head of department.

She described the fraud as unsophisticated and said he had committed the offences after getting into debt.

She said Baalham had suffered a mental breakdown and had contemplated suicide.