Adam Cottrell had pleaded guilty to assault and criminal damage at an earlier hearing at East Hertfordshire Magistrates' Court.
Cottrell, who was arrested in May following an incident at the home he shared with Cassidy, appeared at the same court yesterday for sentencing.
He was also placed on a 12-month community order with 12 months' supervision.
Deputy District Judge Anita Borwick said: "You pleaded guilty at the first opportunity, and I give you credit for that. However, this was in a domestic violence setting, and that is an aggravating feature.
"Your behaviour towards Miss Cassidy was both humiliating and disturbing, and these incidents were fuelled by alcohol."
The court also issued a restraining order which bans 31-year-old Cottrell from contacting Cassidy, who played Sonia Jackson in the BBC One soap.
Cottrell has been ordered to pay £350 compensation for damage caused to Cassidy's home, £100 compensation to the actress and costs of £85.
The former couple are parents to 8-month-old daughter Eliza Beatrice.