From 0fbaa33c4a7d1758fe4e4b6e72c114a5747b9867 Mon Sep 17 00:00:00 2001 From: Antoni Luong Pham Date: Fri, 21 Aug 2020 18:50:54 -0700 Subject: [PATCH 01/13] add SPIK3R README --- robots/SPIK3R/README.md | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 robots/SPIK3R/README.md diff --git a/robots/SPIK3R/README.md b/robots/SPIK3R/README.md new file mode 100644 index 0000000..f44178e --- /dev/null +++ b/robots/SPIK3R/README.md @@ -0,0 +1,10 @@ +# SPIK3R + +> This six-legged creature doesn’t just look like a scorpion, it also acts like one. It turns sharply, snaps with it’s crushing claw, and it’s lightning tail is ready to fire at anyone or anything that gets in its way. + +Control SPIK3R with as follows: + +- Make SPIK3R move straight forward by pressing the IR Remote Control's two Up buttons at the same time +- Make SPIK3R turn right by pressing the IR Remote Control's Right Up button +- Make SPIK3R sting by pressing the IR Remote Control's Beacon button +- Make SPIKER pinch by pressing the Touch Sensor (please do connect one to enable this) From 5bdbd889157e57395cc05e6f30c4e87592319b96 Mon Sep 17 00:00:00 2001 From: Antoni Luong Pham Date: Fri, 21 Aug 2020 18:52:07 -0700 Subject: [PATCH 02/13] update SPIK3R README --- robots/SPIK3R/README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/robots/SPIK3R/README.md b/robots/SPIK3R/README.md index f44178e..e505f41 100644 --- a/robots/SPIK3R/README.md +++ b/robots/SPIK3R/README.md @@ -8,3 +8,5 @@ Control SPIK3R with as follows: - Make SPIK3R turn right by pressing the IR Remote Control's Right Up button - Make SPIK3R sting by pressing the IR Remote Control's Beacon button - Make SPIKER pinch by pressing the Touch Sensor (please do connect one to enable this) + +The build instructions may be found at the official LEGO MINDSTROMS site [here](https://www.lego.com/cdn/cs/set/assets/blt7dca5180ea66ea5e/31313_SPIK3R_2016.pdf). From 472851cf3abb2e51fce91574626a0b2202359192 Mon Sep 17 00:00:00 2001 From: Vinh Luong Date: Fri, 21 Aug 2020 20:35:08 -0700 Subject: [PATCH 03/13] fix SPIK3R README --- robots/SPIK3R/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/robots/SPIK3R/README.md b/robots/SPIK3R/README.md index e505f41..a71134e 100644 --- a/robots/SPIK3R/README.md +++ b/robots/SPIK3R/README.md @@ -2,7 +2,7 @@ > This six-legged creature doesn’t just look like a scorpion, it also acts like one. It turns sharply, snaps with it’s crushing claw, and it’s lightning tail is ready to fire at anyone or anything that gets in its way. -Control SPIK3R with as follows: +Control SPIK3R as follows: - Make SPIK3R move straight forward by pressing the IR Remote Control's two Up buttons at the same time - Make SPIK3R turn right by pressing the IR Remote Control's Right Up button From d96abe1e6afdb460fefad2d96befef2613d691d3 Mon Sep 17 00:00:00 2001 From: Antoni Luong Pham Date: Fri, 21 Aug 2020 20:53:01 -0700 Subject: [PATCH 04/13] update SPIK3R README --- robots/SPIK3R/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/robots/SPIK3R/README.md b/robots/SPIK3R/README.md index a71134e..9cacf38 100644 --- a/robots/SPIK3R/README.md +++ b/robots/SPIK3R/README.md @@ -7,6 +7,6 @@ Control SPIK3R as follows: - Make SPIK3R move straight forward by pressing the IR Remote Control's two Up buttons at the same time - Make SPIK3R turn right by pressing the IR Remote Control's Right Up button - Make SPIK3R sting by pressing the IR Remote Control's Beacon button -- Make SPIKER pinch by pressing the Touch Sensor (please do connect one to enable this) +- Make SPIKER snap its claw by pressing the Touch Sensor (please do connect one to enable this) The build instructions may be found at the official LEGO MINDSTROMS site [here](https://www.lego.com/cdn/cs/set/assets/blt7dca5180ea66ea5e/31313_SPIK3R_2016.pdf). From 56a908d1de752f182a331bf84ec02d883df547c7 Mon Sep 17 00:00:00 2001 From: Antoni Luong Pham Date: Fri, 21 Aug 2020 20:56:43 -0700 Subject: [PATCH 05/13] add Spik3r program --- robots/SPIK3R/spik3r.py | 102 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 102 insertions(+) create mode 100644 robots/SPIK3R/spik3r.py diff --git a/robots/SPIK3R/spik3r.py b/robots/SPIK3R/spik3r.py new file mode 100644 index 0000000..f1aa299 --- /dev/null +++ b/robots/SPIK3R/spik3r.py @@ -0,0 +1,102 @@ +#!/usr/bin/env micropython + + +from ev3dev2.motor import LargeMotor, MediumMotor, OUTPUT_A, OUTPUT_B, OUTPUT_D +from ev3dev2.sensor import INPUT_1, INPUT_4 +from ev3dev2.sensor.lego import TouchSensor, InfraredSensor +from ev3dev2.sound import Sound + + +class Spik3r: + def __init__( + self, + claw_motor_port: str = OUTPUT_A, + move_motor_port: str = OUTPUT_B, + sting_motor_port: str = OUTPUT_D, + touch_sensor_port: str = INPUT_1, + ir_sensor_port: str = INPUT_4, ir_beacon_channel: int = 1): + self.claw_motor = MediumMotor(address=claw_motor_port) + self.move_motor = LargeMotor(address=move_motor_port) + self.sting_motor = LargeMotor(address=sting_motor_port) + + self.ir_sensor = InfraredSensor(address=ir_sensor_port) + self.ir_beacon_channel = ir_beacon_channel + + self.touch_sensor = TouchSensor(address=touch_sensor_port) + + self.speaker = Sound() + + + def snap_claw_if_touched(self): + if self.touch_sensor.is_pressed: + self.claw_motor.on_for_seconds( + speed=50, + seconds=1, + brake=True, + block=True) + + self.claw_motor.on_for_seconds( + speed=-50, + seconds=0.3, + brake=True, + block=True) + + + def move_by_ir_beacon(self): + if self.ir_sensor.top_left(channel=self.ir_beacon_channel) and \ + self.ir_sensor.top_right(channel=self.ir_beacon_channel): + self.move_motor.on( + speed=100, + block=False, + brake=False) + + elif self.ir_sensor.top_right(channel=self.ir_beacon_channel): + self.move_motor.on( + speed=-100, + brake=False, + block=False) + + else: + self.move_motor.off(brake=False) + + + def sting_by_ir_beacon(self): + if self.ir_sensor.beacon(channel=self.ir_beacon_channel): + self.sting_motor.on_for_degrees( + speed=-75, + degrees=220, + brake=True, + block=False) + + self.speaker.play_file( + wav_file='/home/robot/sound/Blip 3.wav', + volume=100, + play_type=Sound.PLAY_WAIT_FOR_COMPLETE) + + self.sting_motor.on_for_seconds( + speed=-100, + seconds=1, + brake=True, + block=True) + + self.sting_motor.on_for_seconds( + speed=40, + seconds=1, + brake=True, + block=True) + + while self.ir_sensor.beacon(channel=self.ir_beacon_channel): + pass + + + def main(self): + while True: + self.snap_claw_if_touched() + self.move_by_ir_beacon() + self.sting_by_ir_beacon() + + +if __name__ == '__main__': + SPIK3R = Spik3r() + + SPIK3R.main() From 20dd20d8cc3023666adef0e6216946f753652a1c Mon Sep 17 00:00:00 2001 From: Vinh Luong Date: Sun, 23 Aug 2020 10:34:21 -0700 Subject: [PATCH 06/13] add SPIK3R sound file --- robots/SPIK3R/Blip 3.wav | Bin 0 -> 13292 bytes robots/SPIK3R/spik3r.py | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) create mode 100644 robots/SPIK3R/Blip 3.wav diff --git a/robots/SPIK3R/Blip 3.wav b/robots/SPIK3R/Blip 3.wav new file mode 100644 index 0000000000000000000000000000000000000000..2678a34e697ca856b9963a7753a45d5c2a1d81a8 GIT binary patch literal 13292 zcmZv?1ymeK7dG57K8!FpgWKTl79qq4v5nit-F@S3n`GnJWQhxAfM}U%GI}cLoc}f);>`p z&zIyC1?EY!s?8~lmLD85Vk-UAw3htA#G2x(a5+EI$sqPlaInFY;`4V`{8$P6W0mN* zWL#_bE{m0(zMn@mv<=2JWMLx^5fAQDYlSfyNmYdYHjJv<@{VwHO z3k&=CQ7JJ7mgl-oJ*Y~hNM&YH+b!Ykv4mAw|KQ_GuSN+&O;6b>LUJdF?50XOo?Ux( zwP(MvyX~{Ug_9zjep4DG$3FSk9%)!(v)Yd}+0->r_acq{kkqt=-EULjy=?MnkK-B;!6a0f$ zFb)*HNEn+x6?|wt!I?VVA^az+woH;>`@IN@vTAhH#jK2aVOUqQ_s+MB`N%!Kfy44K z0i%`1+NP8D&V5*=vbM~&+Y}uV<83~>14+zHvy!=+|6x}f;S)=5=&)(9 ztuA!Q1clA=!AVceUoiWg7)xz3f~XU79m?dy%b2J4I@5UjYzzE1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|bNEHb^P;d*kv+uJ-l&5G#wC&3jf?nD#w;5Wg51H@(%_ zp$$$>`q+vfkz?jx2^$z#@a(tePkUqCS4`$kz>GBI*FT)h`%7N#m>#7LY~z`BhZS7< zvAZkH^lea1XrGf<8kF-U_j$93zTB@mc!qN@9#lLwr>}J{M;0}I%u}{Q#i!KO1v1Xz z2^G^0Sw&TPJwK66Av0o*Pw=;v4jlS%`sW=P$Kr_H4f|?~W$Gg>1>H;gjZu|phW#H_ z%juW<>+0ogwW?a9r}l_t7*n8ZtP{8HM&DW8cJVSFREg_4D>LMO*m=2;9iP$jDsSW- z5Q1iZgpgFFVkx19K?4}ME>1~0(iIL=vRxe^xfL$ zm>s79X^{E>98{-hXXUX5@#Fe+`csr@`A?iM8ai>}FGQd4&-``zr(zXc$+@keBI(Q- z2!@|A*rnVkT}?|j_6N6iJl8gvKY=@y$6+P37Q}S|=@-&Es%)stozzLPJ;(}<6a5e& z1}OS!`8CZwXeCc!_(ZY``%Hs14Z1vd4;-!7K?yTns(FR_8W^fo$_MBUnk5ZYl#tc5 z4*4O>k7)odC)&{8kar-N{1eIqVbC9CBB^*f<_Iq*w}V%yrf9r+Jm^4i0nG97`Z#?q zNV4yD?`3y@?z8)AYMU?yRMZ-K89=XIK)|LFsfL-gIG{|^j8`l Date: Mon, 31 Aug 2020 20:11:33 -0700 Subject: [PATCH 07/13] remove blank spaces warned by linters in Spik3r program --- robots/SPIK3R/spik3r.py | 5 ----- 1 file changed, 5 deletions(-) diff --git a/robots/SPIK3R/spik3r.py b/robots/SPIK3R/spik3r.py index c2d2027..d8ab5b7 100644 --- a/robots/SPIK3R/spik3r.py +++ b/robots/SPIK3R/spik3r.py @@ -25,7 +25,6 @@ def __init__( self.touch_sensor = TouchSensor(address=touch_sensor_port) self.speaker = Sound() - def snap_claw_if_touched(self): if self.touch_sensor.is_pressed: @@ -41,7 +40,6 @@ def snap_claw_if_touched(self): brake=True, block=True) - def move_by_ir_beacon(self): if self.ir_sensor.top_left(channel=self.ir_beacon_channel) and \ self.ir_sensor.top_right(channel=self.ir_beacon_channel): @@ -59,7 +57,6 @@ def move_by_ir_beacon(self): else: self.move_motor.off(brake=False) - def sting_by_ir_beacon(self): if self.ir_sensor.beacon(channel=self.ir_beacon_channel): self.sting_motor.on_for_degrees( @@ -88,7 +85,6 @@ def sting_by_ir_beacon(self): while self.ir_sensor.beacon(channel=self.ir_beacon_channel): pass - def main(self): while True: self.snap_claw_if_touched() @@ -98,5 +94,4 @@ def main(self): if __name__ == '__main__': SPIK3R = Spik3r() - SPIK3R.main() From b2f4bb5a44474446c7495e7f80cd5e639eb8da2a Mon Sep 17 00:00:00 2001 From: Antoni Luong Pham Date: Sat, 17 Oct 2020 13:47:49 -0700 Subject: [PATCH 08/13] fix minor typo to SPIK3R README --- robots/SPIK3R/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/robots/SPIK3R/README.md b/robots/SPIK3R/README.md index 9cacf38..6393e9b 100644 --- a/robots/SPIK3R/README.md +++ b/robots/SPIK3R/README.md @@ -7,6 +7,6 @@ Control SPIK3R as follows: - Make SPIK3R move straight forward by pressing the IR Remote Control's two Up buttons at the same time - Make SPIK3R turn right by pressing the IR Remote Control's Right Up button - Make SPIK3R sting by pressing the IR Remote Control's Beacon button -- Make SPIKER snap its claw by pressing the Touch Sensor (please do connect one to enable this) +- Make SPIK3R snap its claw by pressing the Touch Sensor (please do connect one to enable this) The build instructions may be found at the official LEGO MINDSTROMS site [here](https://www.lego.com/cdn/cs/set/assets/blt7dca5180ea66ea5e/31313_SPIK3R_2016.pdf). From 2601e7fc9abb3b5659815167be4963f7e0640ece Mon Sep 17 00:00:00 2001 From: Antoni Luong Pham Date: Sat, 17 Oct 2020 13:58:42 -0700 Subject: [PATCH 09/13] add Dinor3x program --- robots/DINOR3X/README.md | 24 ++++ robots/DINOR3X/T-rex roar.wav | Bin 0 -> 31724 bytes robots/DINOR3X/dinor3x.py | 247 ++++++++++++++++++++++++++++++++++ 3 files changed, 271 insertions(+) create mode 100644 robots/DINOR3X/README.md create mode 100644 robots/DINOR3X/T-rex roar.wav create mode 100644 robots/DINOR3X/dinor3x.py diff --git a/robots/DINOR3X/README.md b/robots/DINOR3X/README.md new file mode 100644 index 0000000..6237870 --- /dev/null +++ b/robots/DINOR3X/README.md @@ -0,0 +1,24 @@ +# DINOR3X + +> Designed by Lasse Stenbæk Lauesen +> +> This charming robotic triceratops dinosaur is capable of walking and turning on all fours. + +The build instructions may be found at the official LEGO MINDSTROMS site [here](https://www.lego.com/cdn/cs/set/assets/bltad10c02978864265/DINOR3X.pdf). + +Please add a Color Sensor to Dinor3x's back or tail. Control DINOR3X as follows: + +- Make DINOR3X roar by pressing the IR Remote Control's Beacon button + +- Make DINOR3X walk or turn according to instructions from the IR Beacon + - 2 top/up buttons together: walk forward + - 2 bottom/down buttons together: walk backward + - Top Left / Red Up: turn left on the spot + - Top Right / Blue Up: turn right on the spot + - Bottom Left / Red Down: stop + - Bottom Right / Blue Down: calibrate to make the legs straight + +- Make DINOR3X change its speed when detecting some colors + - Red: walk fast + - Green: walk normally + - White: walk slowly diff --git a/robots/DINOR3X/T-rex roar.wav b/robots/DINOR3X/T-rex roar.wav new file mode 100644 index 0000000000000000000000000000000000000000..5a0346a74945e199d1f1e995e016cda424b534a3 GIT binary patch literal 31724 zcmZU)1y~eo*gih7ov^UM(%mH>C;}p(h>9549mnqOu48w%9uosmM8!Y>>F%y&dzbB) znIC?BUg!M3|8VWj%=SO5#>ZJ76Ezy<_R4EmoBh7FhvY#0UuW(+s*fd|^b|7rPU0S@&1IWuDfz5+tSL+}CzkMM86W#CF|G!H8i|~ur zZ|grg{u=cs>i?@BG~o4DFEl{rPvpOj{^+`DTz)I_D?k6W{TJaE zi~s8QE9&39e`10M&VRN3+J39{Xa8>;zb*dc3H)EyzkU8+m40XUH_{)qfA4>DMgJ#; ze>wdd_b&#&&X9qenFjX1{rt(rZ>@f3>0f<*Rnu?2|N8oc@^9NO)L&K z%&!XhrRE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>h{^VuR8*05;J~?LCWvGwJ-S79rDihb0icr98-DmQjsqNWeTYwL%|Xx!@Ifc3 z8FR_E;)vb?KzCAKFl2OPJl-NQ<9W)VTg^-H)5Xq4jK?fm@ zDX1lIIUa@t?0i&DYGN0{;v7%T=1DyBEAjGfWaUTWJaW_@Bpa&m2ja{Bzy;Je!rL7~ QeAtCl56Q%SX|Ox>e^F8t`~Uy| literal 0 HcmV?d00001 diff --git a/robots/DINOR3X/dinor3x.py b/robots/DINOR3X/dinor3x.py new file mode 100644 index 0000000..c27dfdf --- /dev/null +++ b/robots/DINOR3X/dinor3x.py @@ -0,0 +1,247 @@ +#!/usr/bin/env micropython + + +from ev3dev2.motor import ( + LargeMotor, MediumMotor, MoveTank, MoveSteering, + OUTPUT_A, OUTPUT_B, OUTPUT_C +) +from ev3dev2.sensor import INPUT_1, INPUT_3, INPUT_4 +from ev3dev2.sensor.lego import TouchSensor, ColorSensor, InfraredSensor +from ev3dev2.sound import Sound + + +class Dinor3x: + FAST_WALK_SPEED = 80 + NORMAL_WALK_SPEED = 40 + SLOW_WALK_SPEED = 20 + + def __init__( + self, + jaw_motor_port: str = OUTPUT_A, + left_motor_port: str = OUTPUT_B, right_motor_port: str = OUTPUT_C, + touch_sensor_port: str = INPUT_1, color_sensor_port: str = INPUT_3, + ir_sensor_port: str = INPUT_4, ir_beacon_channel: int = 1): + self.jaw_motor = MediumMotor(address=jaw_motor_port) + + self.left_motor = LargeMotor(address=left_motor_port) + self.right_motor = LargeMotor(address=right_motor_port) + self.tank_driver = MoveTank(left_motor_port=left_motor_port, + right_motor_port=right_motor_port, + motor_class=LargeMotor) + self.steer_driver = MoveSteering(left_motor_port=left_motor_port, + right_motor_port=right_motor_port, + motor_class=LargeMotor) + + self.touch_sensor = TouchSensor(address=touch_sensor_port) + self.color_sensor = ColorSensor(address=color_sensor_port) + + self.ir_sensor = InfraredSensor(address=ir_sensor_port) + self.ir_beacon_channel = ir_beacon_channel + + self.speaker = Sound() + + self.roaring = False + self.walk_speed = self.NORMAL_WALK_SPEED + + def roar_by_ir_beacon(self): + """ + Dinor3x roars when the Beacon button is pressed + """ + if self.ir_sensor.beacon(channel=self.ir_beacon_channel): + self.roaring = True + self.open_mouth() + self.roar() + + elif self.roaring: + self.roaring = False + self.close_mouth() + + def change_speed_by_color(self): + """ + Dinor3x changes its speed when detecting some colors + - Red: walk fast + - Green: walk normally + - White: walk slowly + """ + if self.color_sensor.color == ColorSensor.COLOR_RED: + self.speaker.speak( + text='RUN!', + volume=100, + play_type=Sound.PLAY_WAIT_FOR_COMPLETE) + self.walk_speed = self.FAST_WALK_SPEED + self.walk(speed=self.walk_speed) + + elif self.color_sensor.color == ColorSensor.COLOR_GREEN: + self.speaker.speak( + text='Normal', + volume=100, + play_type=Sound.PLAY_WAIT_FOR_COMPLETE) + self.walk_speed = self.NORMAL_WALK_SPEED + self.walk(speed=self.walk_speed) + + elif self.color_sensor.color == ColorSensor.COLOR_WHITE: + self.speaker.speak( + text='slow...', + volume=100, + play_type=Sound.PLAY_WAIT_FOR_COMPLETE) + self.walk_speed = self.SLOW_WALK_SPEED + self.walk(speed=self.walk_speed) + + def walk_by_ir_beacon(self): + """ + Dinor3x walks or turns according to instructions from the IR Beacon + - 2 top/up buttons together: walk forward + - 2 bottom/down buttons together: walk backward + - Top Left / Red Up: turn left on the spot + - Top Right / Blue Up: turn right on the spot + - Bottom Left / Red Down: stop + - Bottom Right / Blue Down: calibrate to make the legs straight + """ + + # forward + if self.ir_sensor.top_left(channel=self.ir_beacon_channel) and \ + self.ir_sensor.top_right: + self.walk(speed=self.walk_speed) + + # backward + elif self.ir_sensor.bottom_left(channel=self.ir_beacon_channel) and \ + self.ir_sensor.bottom_right(channel=self.ir_beacon_channel): + self.walk(speed=-self.walk_speed) + + # turn left on the spot + elif self.ir_sensor.top_left(channel=self.ir_beacon_channel): + self.turn(speed=self.walk_speed) + + # turn right on the spot + elif self.ir_sensor.top_right(channel=self.ir_beacon_channel): + self.turn(speed=-self.walk_speed) + + # stop + elif self.ir_sensor.bottom_left(channel=self.ir_beacon_channel): + self.tank_driver.off(brake=True) + + # calibrate legs + elif self.ir_sensor.bottom_right(channel=self.ir_beacon_channel): + self.calibrate_legs() + + def calibrate_legs(self): + self.tank_driver.on( + left_speed=10, + right_speed=20) + + self.touch_sensor.wait_for_released() + + self.tank_driver.off(brake=True) + + self.left_motor.on(speed=40) + + self.touch_sensor.wait_for_pressed() + + self.left_motor.off(brake=True) + + self.left_motor.on_for_rotations( + rotations=-0.2, + speed=50, + brake=True, + block=True) + + self.right_motor.on(speed=40) + + self.touch_sensor.wait_for_pressed() + + self.right_motor.off(brake=True) + + self.right_motor.on_for_rotations( + rotations=-0.2, + speed=50, + brake=True, + block=True) + + self.left_motor.reset() + self.right_motor.reset() + + def walk(self, speed: float = 100): + self.calibrate_legs() + + self.steer_driver.on( + steering=0, + speed=-speed) + + def turn(self, speed: float = 100): + self.calibrate_legs() + + if speed >= 0: + self.left_motor.on_for_degrees( + degrees=180, + speed=speed, + brake=True, + block=True) + + else: + self.right_motor.on_for_degrees( + degrees=180, + speed=-speed, + brake=True, + block=True) + + self.tank_driver.on( + left_speed=speed, + right_speed=-speed) + + def close_mouth(self): + self.jaw_motor.on_for_seconds( + speed=-20, + seconds=1, + brake=False, + block=False) + + def open_mouth(self): + self.jaw_motor.on_for_seconds( + speed=20, + seconds=1, + block=False, + brake=False) + + def roar(self): + self.speaker.play_file( + wav_file='T-rex roar.wav', + volume=100, + play_type=Sound.PLAY_NO_WAIT_FOR_COMPLETE) + + self.jaw_motor.on_for_degrees( + speed=40, + degrees=-60, + block=True, + brake=True) + + for i in range(12): + self.jaw_motor.on_for_seconds( + speed=-40, + seconds=0.05, + block=True, + brake=True) + + self.jaw_motor.on_for_seconds( + speed=40, + seconds=0.05, + block=True, + brake=True) + + self.jaw_motor.on_for_seconds( + speed=20, + seconds=0.5, + brake=False, + block=True) + + def main(self): + self.close_mouth() + + while True: + self.roar_by_ir_beacon() + self.change_speed_by_color() + self.walk_by_ir_beacon() + + +if __name__ == '__main__': + DINOR3X = Dinor3x() + DINOR3X.main() From 75bd6b98f225d2b6748a851d38adfe71c6c39672 Mon Sep 17 00:00:00 2001 From: Antoni Luong Pham Date: Sat, 17 Oct 2020 14:23:50 -0700 Subject: [PATCH 10/13] minor change to Dinor3x.change_speed_by_color() --- robots/DINOR3X/dinor3x.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/robots/DINOR3X/dinor3x.py b/robots/DINOR3X/dinor3x.py index c27dfdf..c959621 100644 --- a/robots/DINOR3X/dinor3x.py +++ b/robots/DINOR3X/dinor3x.py @@ -67,7 +67,7 @@ def change_speed_by_color(self): self.speaker.speak( text='RUN!', volume=100, - play_type=Sound.PLAY_WAIT_FOR_COMPLETE) + play_type=Sound.PLAY_NO_WAIT_FOR_COMPLETE) self.walk_speed = self.FAST_WALK_SPEED self.walk(speed=self.walk_speed) @@ -75,7 +75,7 @@ def change_speed_by_color(self): self.speaker.speak( text='Normal', volume=100, - play_type=Sound.PLAY_WAIT_FOR_COMPLETE) + play_type=Sound.PLAY_NO_WAIT_FOR_COMPLETE) self.walk_speed = self.NORMAL_WALK_SPEED self.walk(speed=self.walk_speed) @@ -83,7 +83,7 @@ def change_speed_by_color(self): self.speaker.speak( text='slow...', volume=100, - play_type=Sound.PLAY_WAIT_FOR_COMPLETE) + play_type=Sound.PLAY_NO_WAIT_FOR_COMPLETE) self.walk_speed = self.SLOW_WALK_SPEED self.walk(speed=self.walk_speed) From 5925e4af8996a58205d36945c0d73f50f681b32d Mon Sep 17 00:00:00 2001 From: Antoni Luong Pham Date: Sat, 17 Oct 2020 15:04:22 -0700 Subject: [PATCH 11/13] update .GitIgnore to ignore VSCode files --- .gitignore | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitignore b/.gitignore index 15c993e..1cf2ae4 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,6 @@ __pycache__ *.pyc *.swp + +# Visual Studio Code files +.vscode/ From ee09995e6888b28caf5f643c57c25b4dfa343e84 Mon Sep 17 00:00:00 2001 From: Antoni Luong Pham Date: Thu, 26 Nov 2020 12:54:38 -0800 Subject: [PATCH 12/13] add Bobb3e program --- robots/BOBB3E/Backing alert.wav | Bin 0 -> 34604 bytes robots/BOBB3E/README.md | 23 ++++ robots/BOBB3E/bobb3e.py | 207 ++++++++++++++++++++++++++++++++ 3 files changed, 230 insertions(+) create mode 100644 robots/BOBB3E/Backing alert.wav create mode 100644 robots/BOBB3E/README.md create mode 100644 robots/BOBB3E/bobb3e.py diff --git a/robots/BOBB3E/Backing alert.wav b/robots/BOBB3E/Backing alert.wav new file mode 100644 index 0000000000000000000000000000000000000000..5bbed135b679d71fcc0624cd5845fbe786edd465 GIT binary patch literal 34604 zcmaHU1zc2H_x21OQUU^sC}M%4sFWgt2m+FV0us^<6NGV%YX>z9-Q9wOAR?Afu_v!1oqK4;cB%r(+JdUW$`9M1HxiH4J>&qiJx z4u@a%(!eT@+(@0MI<(Y zVhpl~R>K@X5@3AM#}Md&QN-|%_?QcZX^jc?d2`lk?ir5t3volw28ZS?dF+MX@s!Qp?yc_rITI_Ox=CDE zeJ-xu@5|~jjWrv03QPFX=01zOYwwL;-L+RxCXy}jb4^X>XW3O3;JkQ2rp6p(-JF8JTTq137;*MT4pXwxTcFbC}U6hM6Ni9ISXxEs6I&%%S&U4 zGv7{Fy^qrLAmm$;$#|u{xtFPWW>0W*ZG_%;W|d5`x^dvl?bHjw$#1xJl@q3|cXJ&s zNC?m=ms^+Y?Bd$A(W~-FKxM80tD03VDP^C`2kzkJ#J;ge17#m>jgsz$Nb7L>_G2oK zz2#31&(@@JP^{}e?i3>C*lF{|7DWYAmd>rY>`oX@(Qcr{pmo?$_--7&IQiyVwIH@L2~!2Su8B} z5;w}$H9ZZXCLSK~);00!)vWvN7$+Q_^Vwzp8q%C;7>+M{Cne`a;$~|%R>w-A$7S1s zG#}8oDy^eEYo&YMY@`OJ?wU?J{+s;luxaObq)1djh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Mo_*zIqSuia@+5 zeqa`@^aRQec%`Z0LIN$ro`a!h zmp(7)J%>00b0KdqJAsXuFTe_j14Im(f$_Yug=Rw8fH}~jk7CruA_K`scrfwzA}&ZLkl_?$odb)rAdmvA>lvY|}OPbdmNKSTz+1kcs< zPa~qJfYRwB_fHQ4^hoD_V;)(BkU&{5x&bc82ORyk<$!AxV@ML1h4xt#8E_Wl9GvOE zGY0febJ9Q6harJi6G#@|49G_N!T+n{jCLCafgt$S|NrD_G8!$A)>0e{$FaA!fK$1q ze|tJ_+~$o?KOfDQJ9A^+-CY@%XUIF`JiI@fTb)})*Hw<;;Bg7Q$S>{#L3RaeHYRA(eHd=|NqD5XNDWEiO^Gjwi|`NJl9w3UCXsR(bwaw1@Fs;%0d0A zhZwOL3tX$X;*mGkjgZQc=Xh~!dv!J&&XceZM~VgYen-#?Bs*ekvDk)H*`D=0VQ*~4 zLK)Uyb?85ojgC%YhB|z8XW@5uCD?&vTp7a{6kQD8-#2rqa|)Gtu2<)1aqY;?rtwf| z(cLwo`{wAJ8QTS?kn&yj%0fCWI!2@1tYYpL0sMHR)zHADp7Mi*nXtv2E|<$^`6(|$ z|YzQ>G;^Bz^!Grg4dbl98fFi%2v-teJi8C zgYcg^YLZCJfqP4{)_l}5UW!NtPK~`b`KR7vF&WG5V}}9%Hxp-H6_4(Ei@Yo1iPLe7 zBSzy@wWloZR#h<8jAL{%OW7I`yg24F7WTb;TF-GaRTpuqWr`HHdK2dqfX!5AS&Z+z z3wbt-PfxrTS37)c7<>L?nkx}GHan1S?}zuW=T#58vSj~k@uN>U@fQQDk4Np=h@zN( E0rnvqga7~l literal 0 HcmV?d00001 diff --git a/robots/BOBB3E/README.md b/robots/BOBB3E/README.md new file mode 100644 index 0000000..73bd0ed --- /dev/null +++ b/robots/BOBB3E/README.md @@ -0,0 +1,23 @@ +# BOBB3E + +> Designed by Kenneth Ravnshøj Madsen +> +> This remote controlled Bobcat® can be steered to move and lift objects with the control buttons on the IR Beacon. + +The build instructions may be found at the official LEGO MINDSTROMS site [here](https://www.lego.com/cdn/cs/set/assets/blt1e45d9c2a9800e3c/BOBB3E.pdf). + +Control BOBB3E as follows: + +- Make BOBB3E lower the forks by pressing the IR Remote Control's 2 Left Buttons together; make him raise the forks by pressing the 2 Right Buttons together + +- Drive BOBB3E around according to instructions from the IR Beacon: + - 2 Top/Up Buttons together: drive forward + - 2 Bottom/Down Buttons together: drive backward + - Top-Left/Red-Up and Bottom-Right/Blue-Down together: turn left on the spot + - Top-Right/Blue-Up and Bottom-Left/Red-Down together: turn right on the spot + - Top-Left/Red-Up: turn left forward + - Top-Right/Blue-Up: turn right forward + - Bottom-Left/Red-Down: turn left backward + - Bottom-Right/Blue-Down: turn right backward + +- BOBB3E beeps his alarm whenever reversing diff --git a/robots/BOBB3E/bobb3e.py b/robots/BOBB3E/bobb3e.py new file mode 100644 index 0000000..433d39e --- /dev/null +++ b/robots/BOBB3E/bobb3e.py @@ -0,0 +1,207 @@ +#!/usr/bin/env micropython + + +from ev3dev2.motor import \ + Motor, LargeMotor, MediumMotor, MoveTank, MoveSteering, \ + OUTPUT_A, OUTPUT_B, OUTPUT_C +from ev3dev2.sensor import INPUT_4 +from ev3dev2.sensor.lego import InfraredSensor +from ev3dev2.console import Console +from ev3dev2.sound import Sound + +from threading import Thread +from time import sleep + + +class Bobb3e: + def __init__( + self, + left_motor_port: str = OUTPUT_B, right_motor_port: str = OUTPUT_C, + lift_motor_port: str = OUTPUT_A, + ir_sensor_port: str = INPUT_4, ir_beacon_channel: int = 1): + self.tank_driver = \ + MoveTank( + left_motor_port=left_motor_port, + right_motor_port=right_motor_port, + motor_class=LargeMotor) + self.steer_driver = \ + MoveSteering( + left_motor_port=left_motor_port, + right_motor_port=right_motor_port, + motor_class=LargeMotor) + self.tank_driver.left_motor.polarity = \ + self.tank_driver.right_motor.polarity = \ + self.steer_driver.left_motor.polarity = \ + self.steer_driver.right_motor.polarity = Motor.POLARITY_INVERSED + + self.lift_motor = MediumMotor(address=lift_motor_port) + + self.ir_sensor = InfraredSensor(address=ir_sensor_port) + self.ir_beacon_channel = ir_beacon_channel + + self.console = Console() + self.speaker = Sound() + + self.reversing = False + + def drive_or_operate_forks_by_ir_beacon(self, driving_speed: float = 100): + """ + Read the commands from the remote control and convert them into actions + such as go forward, lift and turn. + """ + while True: + # lower the forks + if self.ir_sensor.top_left( + channel=self.ir_beacon_channel) and \ + self.ir_sensor.bottom_left( + channel=self.ir_beacon_channel): + self.reversing = False + + self.tank_driver.off(brake=True) + + self.lift_motor.on( + speed=10, + brake=False, + block=False) + + # raise the forks + elif self.ir_sensor.top_right( + channel=self.ir_beacon_channel) and \ + self.ir_sensor.bottom_right( + channel=self.ir_beacon_channel): + self.reversing = False + + self.tank_driver.off(brake=True) + + self.lift_motor.on( + speed=-10, + brake=False, + block=False) + + # forward + elif self.ir_sensor.top_left( + channel=self.ir_beacon_channel) and \ + self.ir_sensor.top_right( + channel=self.ir_beacon_channel): + self.reversing = False + + self.tank_driver.on( + left_speed=driving_speed, + right_speed=driving_speed) + + self.lift_motor.off(brake=True) + + # backward + elif self.ir_sensor.bottom_left( + channel=self.ir_beacon_channel) and \ + self.ir_sensor.bottom_right( + channel=self.ir_beacon_channel): + self.reversing = True + + self.tank_driver.on( + left_speed=-driving_speed, + right_speed=-driving_speed) + + self.lift_motor.off(brake=True) + + # turn left on the spot + elif self.ir_sensor.top_left( + channel=self.ir_beacon_channel) and \ + self.ir_sensor.bottom_right( + channel=self.ir_beacon_channel): + self.reversing = False + + self.steer_driver.on( + steering=-100, + speed=driving_speed) + + self.lift_motor.off(brake=True) + + # turn right on the spot + elif self.ir_sensor.top_right( + channel=self.ir_beacon_channel) and \ + self.ir_sensor.bottom_left( + channel=self.ir_beacon_channel): + self.reversing = False + + self.steer_driver.on( + steering=100, + speed=driving_speed) + + self.lift_motor.off(brake=True) + + # turn left forward + elif self.ir_sensor.top_left(channel=self.ir_beacon_channel): + self.reversing = False + + self.steer_driver.on( + steering=-50, + speed=driving_speed) + + self.lift_motor.off(brake=True) + + # turn right forward + elif self.ir_sensor.top_right(channel=self.ir_beacon_channel): + self.reversing = False + + self.steer_driver.on( + steering=50, + speed=driving_speed) + + self.lift_motor.off(brake=True) + + # turn left backward + elif self.ir_sensor.bottom_left(channel=self.ir_beacon_channel): + self.reversing = True + + self.tank_driver.on( + left_speed=0, + right_speed=-driving_speed) + + self.lift_motor.off(brake=True) + + # turn right backward + elif self.ir_sensor.bottom_right(channel=self.ir_beacon_channel): + self.reversing = True + + self.tank_driver.on( + left_speed=-driving_speed, + right_speed=0) + + self.lift_motor.off(brake=True) + + # otherwise stop + else: + self.reversing = False + + self.tank_driver.off(brake=True) + + self.lift_motor.off(brake=True) + + def sound_alarm_whenever_reversing(self): + while True: + if self.reversing: + self.speaker.play_file( + wav_file='/home/robot/sound/Backing alert.wav', + volume=100, + play_type=Sound.PLAY_WAIT_FOR_COMPLETE) + + sleep(0.01) + + def main(self, driving_speed: float = 100): + self.console.text_at( + text='BOBB3E', + column=3, + row=2, + reset_console=False, + inverse=False, + alignment='L') + + Thread(target=self.sound_alarm_whenever_reversing).start() + + self.drive_or_operate_forks_by_ir_beacon(driving_speed=driving_speed) + + +if __name__ == '__main__': + BOBB3E = Bobb3e() + BOBB3E.main() From 7bd7e2da9840c82f769768a265f568c9cdcb8609 Mon Sep 17 00:00:00 2001 From: Antoni Luong Pham Date: Sun, 13 Dec 2020 00:53:48 -0800 Subject: [PATCH 13/13] add sleep(0.01) to BOBB3E program --- robots/BOBB3E/bobb3e.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/robots/BOBB3E/bobb3e.py b/robots/BOBB3E/bobb3e.py index 433d39e..8e35058 100644 --- a/robots/BOBB3E/bobb3e.py +++ b/robots/BOBB3E/bobb3e.py @@ -178,6 +178,8 @@ def drive_or_operate_forks_by_ir_beacon(self, driving_speed: float = 100): self.lift_motor.off(brake=True) + sleep(0.01) + def sound_alarm_whenever_reversing(self): while True: if self.reversing: