Jose Vaca, of Bakersfield, took a plea deal and was sentenced to 10 years in prison.
Vaca was shot by police during a routine traffic stop in December of last year.
Police say after Vaca was pulled over, he got out of his vehicle holding a rifle.
Officers shot Vaca several times and he suffered moderate injuries. BPD said Vaca was shot nine times; Vaca himself said he was hit with 12 bullets, three of which went through him.
He was charged with attempted murder, assault with a semi-automatic firearm on an officer, possession of a firearm by a felon and participating in a street gang.
Those were dropped after pleading no contest to assault with a semi-automatic firearm.
RELATED: Jose Vaca pleaded not guilty in court after being shot by BPD