MIAMI BEACH, Fla. – A 54-year-old man was arrested Saturday after he spent weeks on social media harassing officers who worked on the investigation that led to his September 2016 arrest.

The posts came after a judge told Ricky Weinberger not to have any contact -- directly or indirectly -- with any Miami Beach police officer. That ban included social media, text messages, email and other forms of communication.

Weinberger visited the Miami Beach section of the website LEO Affairs on Jan. 25 and posted a thread titled "Any good 13 on AJP," which translates to, any good information on the detective who worked on the case that led to his arrest.

Then on Jan. 31, Weinberger posted, "AJ don't be a (expletive) and lie like a (expletive) go to jail (expletive) (sic)," according to a police report.

Other posts by Weinberger, according to the report, include statements in which he calls the detective names and wanting to perform a sex act on him.

In one post, dated Feb. 9, he wrote, in part, "no more Levine no more AJ," according to the report.

The person named Levine referred to in the message is presumably Miami Beach Mayor Philip Levine.

Other threads started by Weinberger included one titled, "Missed you today AJ," and another titled, "Melanie Melanie," referring to another Miami Beach police officer involved in his arrest.

Miami Beach police on Saturday searched Weinberger's North Beach home, where they found 16 guns and 4,587 rounds of ammunition, Miami Beach police spokesman Ernesto Rodriguez said.

While being taken into custody, Weinberger said, "Don't rip the jacket or I'll f------ kill you" to the arresting officer.

Weinberger was arrested on charges that include threatening a law enforcement officer.

He appeared before a judge Monday.

"You are violating my rights. You are violating my rights," Weinberger said in court.

Judge Mindy Glazer replied to his comments.

"These are just allegations, but they are serious allegations," she said. "I'm looking at an arsenal of weapons on this photograph."

Weinberger shook his head and refused to answer questions in court.

Meanwhile, neighbors at the Lombardy Inn where Weinberger had been staying the past couple of months were startled by the arrest.

One neighbor said he couldn't believe there were so many weapons inside Weinberger's apartment.

A friend said Weinberger would often talk about his relationship with police.

"He would brag about that and be, like, 'Yeah, the cops are after me,'" Philippe Berranen said. "(He'd make) things up like he's a big shot, but I knew he was crazy like that. I told the guy if the cops are after you, the beach is no joke, man. If you are in trouble, leave town."

Weinberger's attorney appeared in court Tuesday on behalf of his client, and claimed that Weinberger's first and second amendment rights were being violated.

The judge, however, found probable cause for the charges and told him that Weinberger would remain in jail without bond.