Replacing potentiometer with Arduino-control

Bilbocious:
...I've figured out which cable is V+(red), Vout(yellow) and ground(black), that was fairly obvious...

Seems obvious, but it isn´t

Yellow sends +5v to potenciometer
Black sends back 0-5V to controller
Red is the negative

word