I'd ride the shoulder as long as it's a shoulder, is more than 3 feet wide, isn't all rumble strip, is reasonably clear of debris, and doesn't have too many crossings. When I'm approaching it becoming parking I'd switch over to the lane when it's clear to move over.
AFAIK there is no law requiring mirrors, lights during the day, or riding on the shoulder in any state. I would think that would have come up in Bicycling and the Law, but I don't recall it being in there.
The cop is probably misinformed (or uninformed and he assumes using "common sense").