Brian German Mendoza was accused of striking Officer Mandee Duyanen on the back of the head with a snare drum on May 1 near Fourth and Hill streets downtown. The attack, which was caught on tape, left a dent in the officer's helmet. Duyanen suffered a concussion.
Mendoza was facing a nine-year prison sentence, but the prosecution dropped some charges as part of a plea agreement.
The judge suspended a three-year prison term and gave Mendoza credit for 122 days in jail.
Mendoza has prior convictions that include a misdemeanor assault on a peace officer to which he pleaded guilty in January.
City News Service contributed to this report.