I'm not big on playing the "race card" many people who opposed him did lean on this to some extent. Trump's continual "birther" remarks, even when more sensible people abandoned this blatantly racist attack was a large appeal to many of Trump's yokel supporters. They are not all yokels, but many do follow this line.
Mitch McConnell announced the day of the election that they'd make him a one term president. This was not necessarily based on race but the continual "jokes" about Obama were clearly racially motivate, "We have an African Lion at the zoo and a lying African in the White House." This is one of hundreds that flooded this country.
Also, many people just did not like his politics re Cuba, Iran, Syria and these were legitimate Non racial reasons.
Obama did not divide us. It has been a progressing dynamic since it began years ago by Newt Gingrich.