Assuming you are driving low voltage steppers, DC motors, solenoids, etc from a microcontroller, the answer comes down to whether you have complete isolation between the microcontroller and the power drivers (opto-isolator, etc). If you do, then you don't want to connect the two grounds. If you do not have isolation between the two, then you usually have a single connection between the digital ground and the power ground, this single connection is normally electrically near the power supply input.
You need to be careful of having any of the digital grounds come from different places on the power ground network. The currents on the power ground can create a ground potential that is well above zero volts creating all sorts of havoc on the digital side (including device destruction).
Power devices can also regenerate mechanical energy back into electrical energy under some circumstances and this can drive the power ground above or below the nominal 0V ground level also creating reset, latch-up, analog noise and device destruction issues.
The issue of ground integrity is a fairly complex one, if you post more information about your application (preferably including at least block schematics and voltage/current parameters for the power side), there are several people here who can provide advise on how to connect things.