added 'speed' variable

also minor comment fixes