1

I recently purchased four continuous rotation servo motors (FS90R). Using an Arduino Uno, Pycharm and pyfirmata, I wanted to test the various speed caps of the servo. I used this piece of code:

from pyfirmata import Arduino

board = Arduino('/dev/cu.usbmodem14201')

pin = board.get_pin('d:8:s')
pin.write(10)

which works; however, after uploading

from pyfirmata import Arduino

board = Arduino('/dev/cu.usbmodem14201')

pin = board.get_pin('d:8:s')
pin.write(0)

The servo would stop for a little bit, and then continue spinning as if nothing happened. I tried putting a while True: loop, but it did not work. I would like to know how to completely stop the servo for an indefinite amount of time. All answers are appreciated.

Jeffrey Lan
  • 90
  • 13
  • The continuous servos are usually stoped around 90° (middle) and 0 is full speed anticlockwise, 180 full speed clockwise rotation. – KIIV Nov 05 '20 at 07:51
  • And if you meant "The servo stops for few seconds start of the script", that will be Arduino auto-reset when script connects to usb-seral and the arduino gets into the bootloader for few seconds – KIIV Nov 05 '20 at 08:00
  • @KIIV Alright, thank you. – Jeffrey Lan Nov 05 '20 at 19:02

0 Answers0