One thing you have going for you is that the burden of proving that you violated the law is on the police officer who wrote the ticket. How difficult or easy that will be, depends on the circumstances of the violation. For instance, if you were not wearing a helmet at all, your options may be limited.
Most traffic tickets come down to your word against the word of the police officer, so if the officer says you did not have a helmet covering your head, it would be difficult for you to refute it. Things are quite different if you are ticketed for using a helmet that was not DOT approved. You may have a shot at proving that you were wearing an approved helmet simply by bringing the helmet and its certification to court with you.
Rules and procedures to follow after receiving a ticket for violating a no-helmet law differ from one state to another, but they usually involve the following steps: