Understand that in most situations, the police officer who issued the traffic ticket is the only witness and in a courtroom setting it may be your word against his as there generally is no tangible evidence to produce and challenge in court regarding a traffic ticket.
To contest the ticket, plead not guilty on or before the date that is on the ticket. The judge will set a trial date and the officer will be notified.
If you interested in pleading the ticket to a lesser offense or having the violation amended to have a lesser affect on your driving record, contact the prosecutor as soon as possible to request cooperation in clearing up the matter that will be more beneficial to you.
Do not wait until the day of your trial to attempt to make a deal with prosecutor. On the trial date, everyone is ready to proceed. Also do not ask the judge for a plea bargain. A judge does not make deals. He only approves or disapproves of any pleas worked out beforehand.
If a plea bargain is not made with the prosecutor, proceed with the not guilty plea and go with the trial.
The police officer will testify first and will state the who, what, why, where, when and how. You are not allowed to interrupt while the prosecutor is questioning the officer. Listen very carefully to the officer's testimony and note any discrepancies that you remember differently.
Control your emotions and body language while the officer is speaking. You will get a chance to challenge his statements. When it's your turn to ask questions do so in a polite and professional manner.
While questioning the officer, make sure you are asking questions and not engaging the officer in an argument while he is on the stand.
Challenge the officer's memory. Your objective is to have the officer contradict himself in his sworn testimony. Since most likely the trial is between you and the officer, his inability to remember certain things or contradict himself may tip the judge' s opinion in your favor.
When the officer is dismissed from the stand, you will have an opportunity to testify. Clearly and confidently explain your side of things. While testifying, stick to the facts. Don't offer opinions or make subjective statements. Remain professional and don't try to sway the judge by making statements that cannot be substantiated such as the "officer is liar".
Know that since you are testifying, the prosecutor will have the opportunity to cross examine you and ask you questions.
When both you and the officer are done testifying, take the opportunity to make a closing argument to the judge and raise doubts as to whether or not you did something wrong. Respectfully tell the judge why you are not guilty of the traffic ticket. Point out any inconsistencies that the officer made and any relevant facts the judge should consider.
When you are finished the judge will issue a verdict. Hopefully, you have presented doubt and the judge must consider that.