While not giving any specific advice as to whether you have a case, I will say this – Traffic Control Devices (section 3111) is what we work stuff down to. No points, no effect on insurance, $25 fine (plus court costs).
It may not matter that your speedo never got above 40 – the relevant number here is 30 MPH.
Also? Your driving history is legally irrelevant. The fact that you haven't had a traffic violation before does not prove you didn't have one this time.
This officer cut you a break in my estimation.
You said the magic words when you said you were below 40 the whole time. Over 30 is the violation. Saying that in court could get you a conviction for speeding, in spite of the original charge.
Keep in mind, the officer is paid to lie. He can tell you anything he wants about what will happen, and you will likely have no recourse if something other than what he said occurs.
I had a friend who thought it would be okay to plead guilty to a No Point Speeding Charge, (under 10 miles over the speed limit), thinking it wouldn't have any impact on his driving record. However, the court processed the conviction, and his insurance company checked his driving record when he had an accident about a year later. They cancelled his policy for having two items on his insurance plate. It cost him quite a bit for the high risk insurance.
The insurance industry, as I have had it explained to me, assesses one point for any moving violation and one point for any accident. If you get two points, you get to buy high risk insurance. I always tell people, don't let the first one go on your record if you can avoid it. An accident down the road is unfixable, and it will be too late to do something about a previous traffic conviction at that time.
I would suggest you give serious consideration hiring an attorney to make this go away for a small fee, and whatever fine you pay. That is a different kind of insurance policy, against your insurance company.
This is a general description of legal practices, and is not intended to be relied upon as legal counsel. There is no attorney-client relationship established by the answering of this question, and no expectation of representation in offering this general information.