i see the servo speed is diff as usuall ?
its for the init start for roli.
is it servo(d12,$speed) or servo(d12,4)
You can load the roli project and view the init script. Here is the init script as of today (2016/04/14):
# This is the initialization script for your Roli robot
# This script is called from the Connection Control when a connection
# is made to the Roli EZ-B
# Set the max and min positions of some servos so
# they cannot move past their limitations
# Left Gripper
# Right Gripper
# Move the servos into the calibration position
# All servos will be set to 90 degrees
ControlCommand("Auto Position", AutoPositionFrameJump, "Calibrate")
# Pause for a brief period of time to ensure the servos have been initialized
# We want the arm and neck servos to move smoothly
# To do this, we will set the speed of each servo
# The speed is how quickly a servo will move between positions
# We set a variable for the speed, and then use that variable for
# every speed command.
# This is an effecient way to reuse a value numerous times
$speed = 1
# This sets the speed for the HBridge Motor Controller
# The speed is a number between 0 and 255
# Setting this speed will initialize the PWM on the motor controller
# Even though we set the speed, we will also enable the PWM
# on the speed pins that connect to the HBridge Motor Controller
# The number is 100, which means 100%
# This sets up variables for use within the mobile interface
# as a toggle for using the sliders for movement and to keep
# of the direction currently moving
yes i now that.i want to let go the servo slower a start up.
so do i need to set the speed to 4 instead or $speed ?
i want the arms and head/neck go slower
think i have it
$speed is a variable, it holds values. Change the value that is assigned to $speed
$speed = 4
The description of $speed is right there in the code. The code has a big chunk that explains $speed is a variable. Read the descriptions in the code, it will help make sense.
okay dj thanks
1 is fast and 4 is slower