As the Civil War ground on and on, Republicans established the right of black men to serve in the U.S. army and began to envision them as a means to counterbalancing and punishing disloyal Southerners in the Confederate States. Those who supported the rebellion could be disenfranchised, and small numbers of loyal whites and "freedmen" (newly endowed with rights as citizens) could control those states for the Republican Party.
You might note that a lengthy struggle took place to apply the XIII, XIV and XV ammendments to the states. As late as the mid-twentieth century, a variety of states contested appliation of the "Bill of Rights" to internal state issues, and (if I'm not mistaken) the same is true of the Reconsruction ammendments. In other words, segregation or exclusion of people based on race - African, Asian or otherwise -- was allowed under state laws throughout the United States.