Help Needed for Circuit

Can somebody modify this code from the circuit to be compatible with this electronic speed controller provided below?
Link to ESC:
Link to circuit code (click code and download the file to modify): How to wire PS2 Joystick two axis module, Submersible Pool Water Pump, Submersible Pool Water Pump to Arduino Mega