The seven men on trial have denied the charges against them
The case of seven Muslim men who protested at a soldiers' parade should not have come to court, one of their lawyers told Luton magistrates' court.
The men chanted slogans as the 2nd Battalion Royal Anglian Regiment marched through Luton last March.
The men have denied using threatening, abusive or insulting words and behaviour likely to cause harassment, alarm and distress.
Lawyer Neil Mercer said the men would not have expected to be prosecuted.
Those accused are Jalal Ahmed, 21; Yousaf Bashir, 29; Ibrahim Anderson, 32; Jubair Ahmed, 19; Ziaur Rahman, 32; Shajjadar Choudhury, 31, and Munim Abdul, 29.
'Police allowed protest'
They allegedly told the soldiers to "burn in hell" and branded them rapists, murderers and baby killers.
Mr Mercer, who is defending Rahman and Abdul, told the court the group were making a peaceful political protest which the police allowed to go ahead on the day.
They had flagged up to the police in advance their intention to protest, set out in advance what they wanted to say and complied with police throughout, he said.
"Citizens are entitled to expect that once they have done this they will not be prosecuted," he said.
"If you go to the police and give them full disclosure beforehand and comply throughout, how can it then be right that you are prosecuted?"
He described their shouts of "go to hell" to the troops as an "eschatological statement of fact as they see it".
He said: "They believe that what these soldiers have done will mean they will go to hell.
"From their theological viewpoint it is an unequivocal statement of fact."
Britain has a "long tradition of peaceful protest", he said, warning District Judge Carolyn Mellanby that if she found these men guilty she would be "closing down dramatically the right to protest in this country".
Another lawyer suggested police had wanted to "get a conviction at all cost".
The trial continues.