William Hassey Jr. wants a judicial order blocking enforcement of a local ordinance that bars playing music that can be heard 30 feet away.
Hassey claims that ordinance violates his First Amendment rights.
The violinist testified on Monday in U.S. District Court in Baltimore that he was made aware of the ordinance last summer when a police officer told him to quiet down or face up to 90 days in jail and a $500 fine.
Ocean City Mayor Richard Meehan testified that the noise ordinance is a constitutional limit on the growth of amplified sound on the Ocean City boardwalk.
The judge will hear closing arguments in the case next week.