Is that trace from a time when it misbehaved? How sure are you that it's not contact bounce on the switch? Where is the driver input ground tied back to? Is the driver opto-isolated and are you sure the PIC is driving it hard enough?