The Confederacy used slaves for manual labor in military excursions. Trenches, supplies, hauling. It was free, raw manpower that put the Union at a disadvantage. In fact, Lincoln commented on this quite a bit and it's one of the reasons he cites during the formation of the Emanicaption Proclamation.
The Emanciapation Proclamation didn't free ALL slaves -- just the ones in the rebel states. And it made clear that military aged males were welcome and encouraged to join the Union forces. At first, these Union black troops did not get equal pay as the whites. This was remedied.
Frederick Douglas (a former slave who learned to read and write and became a BRILLIANT orator/writer) played a big role at this juncture. Lincoln wanted to ship the free slaves to Central America (there was a lot of debate on whether or not freed slaves were U.S. citizens).
Douglas made it clear to Lincoln that the slaves were born here and it was just as much their country as anybody else's. Douglas convinced the black troops to join the Union army and said to the effect "get that uniform, put on that U.S. pin, and go fight and nobody can tell you that you can't be a citizen."
Douglas, I believe, was absolutely instrumental in changing Lincoln's mind. Lincoln considered Douglas a friend and even held council with him at the White House while leaving white governers waiting! (Douglas couldn't believe this!)
A very interesting time in all of history.