You don't need to buy Mach3. I found it easier to configure EMC2 to work with my mill that also had a mystery controller.
I'd pull out the controller board and see how well labeled it is. My mystery controller turned out not to be a mystery once I found all of the silkscreened stuff on it. I easily found the manufacturer and the board was labeled with the controller pinout.
You want to see which pins are used to drive which motors. In general you'll probably find that the digital out pins (2-9) are used to drive something like:
2 - Xdir
3 - Xstep
4 - Ydir
5 - Ystep
It looks like you have 4 wire unipolar motors.