Atticus Finch makes Bob Ewell sign his name to prove in court that Ewell is left-handed. As Tom's own left hand has been useless ever since a farm accident a few years earlier, this proves that Mayella's aggressor is someone left-handed (such as her own father). For the bruises inflicted on her have been done by someone who had use of both his hands and who was in proximity at the time of the incident.
Atticus catches Ewell off guard, who does not see into what the lawyer is driving at until it is too late.
Atticus asks Bob Ewell to write out his name because it will prove to the court that Tom is innocent of the crime. The crime was shown to have been committed by a person who was left handed. Bob Ewell wrote his name with his left hand. While no charges were brought against Bob Ewell, he was humiliated in front of the town and in front of the court.
Ewell is publicly humiliated and shamed in front of the court because Atticus Finch has outsmarted him and has had him prove a black man's innocence with his own hand.
He asks Bob to write out his name in order to prove he is left handed. The crime was committed by a left handed person, and that is impossible for Tom Robinson to do. Even though all evidences prove towards Bob Ewell that he in fact is the one who committed this crime, because he is white, no charges were brought against him. However, in this situation he became humiliated in front of the whole town.