Great question! Tom Robinson is depicted in the novel as a well-meaning and polite black man whose kindness gets him into trouble when Mayella Ewell declares that he raped her. This only happens because he was trying to be kind as he recognised that way that she was left to look after the home without any support and gave her what help he could. When he is questioned, he makes the mistake of saying that he felt sorry for her, which antagonises the white men in the jury because a black man should not feel sorry for a white girl. The hypocrisy of the jury is shown by their decision to convict him as guilty of the crime of rape, which carries the death sentence, even though it is obvious he is innocent. Unfortunately, because he does not believe in the ability of "justice" to save him on appeal, Tom Robinson tries to escape and is shot dead.
Boo Radley is an interesting character because he leaves his mark on the novel even though he only appears at the very end. Legends and myths about Boo Radley abound, such as the way he wanders around at night and eats cats and other animals. He, like Tom Robinson, is something of a social outcast, but not because of his skin colour. He has spent a long time not going out of his house at all, as when he was a teenager a prank he carried out caused his father (now deceased) to put him under house arrest. Boo clearly dominates the imaginations of the children in the novel as they play games around his stories and dare each other to go up to the house. Boo is described as being in many ways similar to Tom Robinson. In spite of his treatment at the hands of his father, he is shown to be a loving and gentle individual who delights in acts of kindness, characterised by what he leaves for Scout and Jem in the hole of the tree. He plays a key role in rescuing the children at the end from Bob Ewell's attempted murder. What is interesting to note is that the fear that the children have of Boo Radley, which of course is based on complete ignorance rather than the facts, mirrors the prejudice of the town against Tom Robinson. Interestingly this connection is emphasised by the use of mockingbird imagery for both men.
So, when we think about these two characters, it is clear that although the central difference is their skin colour, there are many similarities concerning their position as outsiders or outcasts within their own society and the way that they are treated by their society.