I used the power supply on my Arduino Mega 2560 R3 at 5 volts, and grounded it the same way. My Arduino Mega 2560 R3 is also hooked up to my desktop P.C., and I have a hobbyists workbench for doing minor projects with electronics. I am intimidated by large groups as I suffer from a mental illness, but working here and there with my Arduino and C programming has really helped a lot! Everything to be a great coder and electronics aficionado is on the internet.
Hey Tate2326, The first thing I notice on your diagram was, you are using the Arduino 5V power out right. I would suggest that you use a dedicated power supply for the servo as the servo may require a lot of current.
I was coding before I even realized I was doing so!
Image courtesy of SparkFun ElectronicsUse a servo for precise position control (unlike a DC motor). Color scheme vary, but generally the red/orange wire is 5V, the black/brown wire is ground, and the white/yellow wire is the control signal. Servos can consume a lot of power, so consider connecting the 5V wire to a separately regulated 5V supply instead of the Arduino’s 5V power. Unless modified, servos generally have a 180 degree rotation range.Buy a servo motor from, or. Cobalt blue color code.