Behaviors Driven Robotics (#178)

* adding avoid crash behavior

* more implementation

* add another simple behavior

* fixed synched motors

* bump common packages
This commit is contained in:
Peli de Halleux
2018-01-04 12:55:30 -08:00
committed by GitHub
parent 69f8453947
commit 7da811246c
10 changed files with 93 additions and 15 deletions

View File

@ -343,7 +343,7 @@ namespace motors {
* Gets motor angle.
* @param motor the port which connects to the motor
*/
//% blockId=motorTachoCount block="%motor|angle"
//% blockId=motorAngle block="%motor|angle"
//% weight=70
//% group="Sensors"
angle(): number {
@ -445,7 +445,7 @@ namespace motors {
private __setSpeed(speed: number) {
syncMotors(this._port, {
speed: speed,
turnRatio: 0,
turnRatio: 100, // same speed
useBrake: !!this._brake
})
}