Flashing your lights to warn of speed trap is LEGAL FREE SPEECH!

A few years back I had a new '07 truck and at night had an oncoming car flash his brights at me. I didn't have my brights on but hit the brights for just a second to show him my dims were on. Well it was a MI state trooper. He did a quick U turn and lit me up. After the license and insurance check was over he asked me if I knew why he pulled me over. I said I had no idea and he asked me if I was trying to blind him. Of course I said no I just was showing you that I didn't have my brights on. He told me "flashing" brights is against the law. I said why did you do it to me? He handed me my stuff back and told me to think twice before I do it again. I'm an old guy and for as long as I can remember people always flashed their brights to let the other driver know they were being offensive.