I am not sure if I am understanding exactly what you are wanting but heres what I think.
You are running code and the M3 is in the code and you wish for the code to wait until the signal from your board says its ready and then you want the code to proceed, is that correct?
If yes then I think altering the M3 macro would be the easiest way, ie the macro wouldnt finish until it sees the input, once it sees the input the macro would end which would allow the code to continue.
Hood