the info is from the person that sold me the board....
ONBOARD RELAY CONTROL FOR TB6560 BOARDS
The Toshiba board relay is addressed through pin #9 on the connection cable for the 3 axis
board, and pin 2 for the 4 axis board.
3 axis board setup
In Mach3, output signals are configured through the main configuration menu, under the "Ports
and Pins" utility. Open the Ports and Pins utility, and you will see a page with multiple tabs; click
on the "Output Signals" tab. Enable "Output #1" (green check mark) and make sure the port
number is correct (usually "1"). Under the column labeled "Pin Number" type in "9", and
also make sure the corresponding "Active Low" column contains a red "X". That's it for Mach3
Now, within a G-code program, the Toshiba relay can be controlled using two M-function
commands, "M3" to switch the relay on and "M5" to switch it off. It's very important for safety
reasons that any program using M3 to turn this relay on ALSO has an M5 command (before the
end of the Gcode program) to turn it off - otherwise whatever is being controlled (via relay) may
remain ON after the program ends.
Substitute pin 2 for pin 9 for the 4 axis board.
The relay on board may be rated higher than it actually can handle. Because motors draw near
three times their rated amps on startup, this on board relay can be destroyed or damaged with
repeated high amp starts,
an you can use this file http://www.cnczone.com/forums/1036152-post2.html (Wire an E-stop button to a TB6560 driver board?)