Paul Couse, 50, let off a volley of shots from a firing pistol after travelling to where she was buried in a taxi.
Couse, of Coatbridge, Lanarkshire, had gone to the town’s Coltswood Cemetery in April last year just days after his mother Isabella Forrester, 67, had passed away.
Couse had shown the alarmed cab driver the self-loading 8mm imitation weapon before using it several times in the graveyard.
Armed police were called and Couse told them they couldn’t arrest him because he was following traveller tradition.
But he was held on various charges including firearms offences which he later admitted at Airdrie Sheriff Court.
Couse has now been ordered to carry out 120 hours of unpaid work and be kept under supervision for 18 months.
The court heard Couse told arresting officers: “I’ve not done anything wrong. I’m a ‘gyppo’ and it’s a tradition. I just shot three rounds over my ma’s grave and you can’t charge me with anything.”
Prosecutor Agnes Meek said he fired five shots in tribute to his late mother.
He also admitted scaring the cab driver by firing the gun.
Eddie Kelly, defending, said Couse had struggled to cope after his mother’s death but understood he faced serious charges.
He added: “He summoned a taxi and it occurred to him that he would want to visit his mum’s grave.
“He asked the driver to wait for him and when he came out he asked the driver to take him to the graveyard.
“He had not revealed what his intentions were but the imitation firearm was within a bag.
“It fell out the bag and he showed the driver the gun. He accepts he did that but it must have been extremely frightening for the driver because there is no way of knowing if it was real or what his intentions were.
“He didn’t make any threatening gestures and got out the taxi, paid the fare and walked off towards the graveyard.
“In the graveyard he was alone and at a suitable point in time he produced the pistol and fired shots into the air above his mother’s grave.
“He did that in tribute to his mother and that has been his position from the outset.
“His mother came from travelling people stock and this was tradition and that was why he did it.
“He was not attempting to scare anyone. He was firing shots into air above his mother’s grave and shell cases were later found nearby.”
He added: “In the cold light of day he can’t understand why he would have done such a thing.
“It was supposed to be a private moment but it didn’t turn out like that.
“Had he been sober and grief not played a part that wouldn’t have happened.”
Sheriff Petra Collins said: “You were right to recognise that this is an extremely serious matter and had it not been for the unusual particular set of circumstances of your offending then I would have been sending you to jail.
“But I am persuaded that is not a just outcome in your case.
“If you breach this order I will have little alternative to send you to custody.”