I am using an Arduino Due to temporarily control a tensile testing frame. The motor is driven by an Advanced Motion Controls 20a14 Analog Servo Drive (http://www.a-m-c.com/download/datasheet/20a14.pdf). From what I gather from the datasheet, the +REF and -REF voltage input with respect to REF ground proportionally controls the current going to the motor. So I wrote some code to use a joystick to control the DACs on the due, buffered them through an op amp, then connected the first DAC to the +REF and the second DAC to the -REF and the REF ground to the Arduino ground.

When nothing is connected, an oscilloscope shows that the voltage reading from +REF to -REF coming out of the op amp ranges from +3.3v to -3.3v, depending on the position of the joystick. However when I connect the buffer to the Servo Drive, the motors randomly speed up and slow down with little regard to my input with the joystick. An oscilloscope reading from +REF to -REF shows the voltage is randomly fluctuating.

Any ideas on how I can rectify this? I can provide code and/or circuit diagrams (if needed) once I get back to my apartment after the holiday weekend.

This might be your opamp picking up the noise from the driver and going crazy because of that. Test what's coming from the DAC. Try out the servo drive alone. Try getting rid of your opamp and connect it to arduino simply through a resistor.

the analog pins arent that stable so by taking some samples and average it we can improve the sensors quality. For my Voltagedivider I used only one pin, First i wanted to measure over a Difference Amp but that involves extra 7805 Voltage regulator. By boosting the signal youll also improve the signals you dont want. So i left the Amp out of my design.

secondly i used 1 for loop for the calculation of a voltage divider and sampled it around 750x. the code is added in the lower section of the screen.you can place it in the top of the Void loop.

I simply powered the board from a LM7805 attached to the same DC power supply the motor controller was attached to. Then I ran the the analog outputs into a quad op amp, which was powred with rail voltages provided by a LM7812 and LM7912. The first two op amps were simply used as buffers, while a third was wired as a summing amplifier with a gain of 3 (so I could use the controller's 10v range).