you need to include the motor to figure this out - since it goes in the middle of the plug and the foot control.
Basically you make a circle. One line from the Plug is going to go to the motor. one line to the controller. the other line from the controler goes to the motor. And in some cases, you'll have another set from the plug to the light -so it gets power seperate from the foot control.
Normally in a case like this - one of those pins isn't going to have a live connection inside the machine - while the other two go to the motor.
So one from the pedal goes to one from the motor - one from the plug goes to one from the motor - and the other two (one from pedal, one from plug) go together at the pin that does not have a run to the motor.
If you think that is fun - try wiring in a 4 way light circuit - three switches and a light fixture.