Servo and Arduino Uno direction based on a gps provided variable

I'm in over my head. I have been tasked to find code that will make a standard servo from radioshack move based on an inputted variable.

I've googled for code extensively and found many links to Zoomkat's code but I can't get it to work. His code says it may not work if I am using the power supplied by my arduino but that's my only option right now. It responds to the sweep code in the examples so it must work. Ultimately another team member is going to code in the variable to respond to a gps signal but until then I want to be able to control it from the serial monitor and be able to increase it by degrees.

Any help is appreciated I am very much a noob at microcontrollers.

His code says it may not work if I am using the power supplied by my arduino but that's my only option right now.

Is this your option or is it imposed by someone else? It isn't a good option.

Don't have a nine volt battery and a voltage divider set up tonight, but I will troubleshoot that if that's really what's wrong

You should never power a servo from the Arduino. Doing so can damage the Arduino or cause reset problems. Use a separate supply instead (4 AA batteries will work) and connect the grounds together.

Is your code setup to also send the servo commands to the serial monitor to verify the desired servo commands are being generated and sent?

First off I'd like to personally thank zoomkat. I've been following your code suggestions through out this ordeal. My team kept insisting that because I could perform sweep with power from Arduino, I could perform zoomkat's code through Arduino despite my insistence to use a separate supply. I scotch taped 4 aa's in series ran positive to servo negative to negative as well as negative to ground in Arduino. Worked after first compile and now I'm a god damned hero.