From ee0b8eb6a0f935364483427748e99afb06dbc160 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Wed, 10 Sep 2025 13:28:54 +0000 Subject: [PATCH 01/96] Update README.md --- README.md | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 175af42..83d997f 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,25 @@ -# Team 65266 Lego Dynamics +# 65266 Lego Dynamics - UNEARTHED Season Repository -Pybricks code solving missions in Season UNEARTHED +## Project Overview + +This repository contains the Pybricks code for Team 65266 Lego Dynamics' robot for the UNEARTHED season. + +## Robot Hardware + +* **Robot Name:** Optimus Prime III +* **Robot Firmware:** PyBricks firmware +* **Motors:** Two large motors for attachments, C left, D right, Two small motors for drive, A left, B right +* **Sensors:** visible up-facing color sensor for quick starts +* **Attachments:** Lots of 'em + +## Code Structure + +Files are the different runs we do, with each run consisting of one or multiple mission completions. Another script combines these files into a "master" file, which then adds the color sensor to start logic. + +## How to Use + +Load the master file into PyBricks, then send it over to the robot. Then you hold a color LEGO up to the sensor to start it. + +## License +GNU General Public License +You can take inspiration from our code, but you can't take our exact code. \ No newline at end of file From c4aa9548ed64ec07c65feabc8d360d3a019781af Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 12 Sep 2025 21:52:55 +0000 Subject: [PATCH 02/96] Boat mission --- missions/Boat.py | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 missions/Boat.py diff --git a/missions/Boat.py b/missions/Boat.py new file mode 100644 index 0000000..bb42eb7 --- /dev/null +++ b/missions/Boat.py @@ -0,0 +1,27 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task,multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) + +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) + +drive_base.settings(550,700,100,100) + +drive_base.use_gyro(True) + +first_run = False + +async def main(): + await drive_base.straight(750) + await drive_base.straight(-650) + +run_task(main()) \ No newline at end of file From e8176500f90f5b7bac5857c154b0b4190cdad788 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 12 Sep 2025 21:54:15 +0000 Subject: [PATCH 03/96] Send Over --- missions/Send_Over.py | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/missions/Send_Over.py b/missions/Send_Over.py index a769f1d..97bed5f 100644 --- a/missions/Send_Over.py +++ b/missions/Send_Over.py @@ -13,22 +13,19 @@ right_motor = Motor(Port.B) left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) right_arm = Motor(Port.D) -drive_base = DriveBase(left_motor, right_motor, wheel_diameter=64.8, axle_track=180) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) drive_base.settings(600,500,300,200) drive_base.use_gyro(True) async def main(): - await drive_base.straight(855) + await drive_base.straight(915) await drive_base.turn(-90) - await drive_base.straight(50) + await drive_base.straight(60) await left_arm.run_angle(10000,-15000) - await drive_base.straight(-50) - await drive_base.turn(90) + await drive_base.straight(-60) + await drive_base.turn(85) await drive_base.straight(2000) - - - run_task(main()) \ No newline at end of file From 7eeead7d99aabbd4d88c284bb1c20c4319789472 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 12 Sep 2025 21:55:38 +0000 Subject: [PATCH 04/96] Sand Mission --- missions/Sand Mission.py | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 missions/Sand Mission.py diff --git a/missions/Sand Mission.py b/missions/Sand Mission.py new file mode 100644 index 0000000..73e1e16 --- /dev/null +++ b/missions/Sand Mission.py @@ -0,0 +1,29 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task,multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) + +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) + +drive_base.settings(400,500,100,100) + +drive_base.use_gyro(True) + + +async def main(): + await drive_base.straight(420) + await right_arm.run_angle(300,-100) + await drive_base.straight(-100) + await right_arm.run_angle(300, 100) + await drive_base.straight(-350) + +run_task(main()) \ No newline at end of file From 9cff4d86264df49754052d2421d904407732a198 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 19 Sep 2025 22:00:28 +0000 Subject: [PATCH 05/96] Update missions/Send_Over.py --- missions/Send_Over.py | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/missions/Send_Over.py b/missions/Send_Over.py index a769f1d..c95d702 100644 --- a/missions/Send_Over.py +++ b/missions/Send_Over.py @@ -13,22 +13,19 @@ right_motor = Motor(Port.B) left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) right_arm = Motor(Port.D) -drive_base = DriveBase(left_motor, right_motor, wheel_diameter=64.8, axle_track=180) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) drive_base.settings(600,500,300,200) drive_base.use_gyro(True) async def main(): - await drive_base.straight(855) + await drive_base.straight(915) await drive_base.turn(-90) - await drive_base.straight(50) - await left_arm.run_angle(10000,-15000) - await drive_base.straight(-50) - await drive_base.turn(90) + await drive_base.straight(60) + await left_arm.run_angle(10000,-4000) + await drive_base.straight(-60) + await drive_base.turn(85) await drive_base.straight(2000) - - - - + run_task(main()) \ No newline at end of file From a20bf2255b01c0dcafe2fb1b0126bad014d8962c Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Sat, 20 Sep 2025 22:52:04 +0000 Subject: [PATCH 06/96] Update missions/Send_Over.py --- missions/Send_Over.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/missions/Send_Over.py b/missions/Send_Over.py index c95d702..61e2d37 100644 --- a/missions/Send_Over.py +++ b/missions/Send_Over.py @@ -24,8 +24,8 @@ async def main(): await drive_base.turn(-90) await drive_base.straight(60) await left_arm.run_angle(10000,-4000) - await drive_base.straight(-60) - await drive_base.turn(85) + await drive_base.straight(-90) + await drive_base.turn(80) await drive_base.straight(2000) run_task(main()) \ No newline at end of file From 3527ee56004918e5c57e55377ac9f03bbe1ad61f Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 26 Sep 2025 21:45:42 +0000 Subject: [PATCH 07/96] Add missions/Lift Parthicc made this originally. --- missions/Lift | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 missions/Lift diff --git a/missions/Lift b/missions/Lift new file mode 100644 index 0000000..a5e1773 --- /dev/null +++ b/missions/Lift @@ -0,0 +1,34 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(525) + await drive_base.turn(60) + + await drive_base.straight(50) + await right_arm.run_angle(2000,1000) + await drive_base.straight(-50) + await drive_base.turn(45) + await drive_base.straight(50) + await right_arm.run_angle(350,-1000) + + await drive_base.turn(-100) + await drive_base.straight(-600) +run_task(main()) \ No newline at end of file From b8620e37aa38bf6bed3a1868862d69fcca235d1b Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 26 Sep 2025 21:46:12 +0000 Subject: [PATCH 08/96] Update missions/Lift.py --- missions/{Lift => Lift.py} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename missions/{Lift => Lift.py} (100%) diff --git a/missions/Lift b/missions/Lift.py similarity index 100% rename from missions/Lift rename to missions/Lift.py From 47c89cba0acd61364986eedae6af76876a5bb70f Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 3 Oct 2025 21:26:35 +0000 Subject: [PATCH 09/96] Add missions/Lift2.py --- missions/Lift2.py | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 missions/Lift2.py diff --git a/missions/Lift2.py b/missions/Lift2.py new file mode 100644 index 0000000..a5e1773 --- /dev/null +++ b/missions/Lift2.py @@ -0,0 +1,34 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(525) + await drive_base.turn(60) + + await drive_base.straight(50) + await right_arm.run_angle(2000,1000) + await drive_base.straight(-50) + await drive_base.turn(45) + await drive_base.straight(50) + await right_arm.run_angle(350,-1000) + + await drive_base.turn(-100) + await drive_base.straight(-600) +run_task(main()) \ No newline at end of file From efcc011733e49b6f01f84570afb668f6af9e6cdd Mon Sep 17 00:00:00 2001 From: Vickram <31kapoov@elmbrookstudents.org> Date: Fri, 3 Oct 2025 23:16:03 +0000 Subject: [PATCH 10/96] Initial Commit --- LINEUPS.md | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 LINEUPS.md diff --git a/LINEUPS.md b/LINEUPS.md new file mode 100644 index 0000000..0280d0a --- /dev/null +++ b/LINEUPS.md @@ -0,0 +1,7 @@ +# lineups +Mission Run #1 (Description) -> The lineup +Mission Run #2 (Description) -> The lineup +Mission Run #3 (Description) -> The lineup +Mission Run #4 (Description) -> The lineup +Mission Run #5 (Description) -> The lineup +Mission Run #6 (Description) -> The lineup \ No newline at end of file From d172c70fe230f2dc0b85c4ab2add49579a68a81e Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Fri, 3 Oct 2025 23:28:16 +0000 Subject: [PATCH 11/96] THIS CODE IS OUTDATED!!! DO NOT USE!!! --- missions/{mission_09.py => mission_09_old.py} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename missions/{mission_09.py => mission_09_old.py} (100%) diff --git a/missions/mission_09.py b/missions/mission_09_old.py similarity index 100% rename from missions/mission_09.py rename to missions/mission_09_old.py From 6931731ae122710dc23b62284ea58f30930393c8 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Sat, 4 Oct 2025 00:09:55 +0000 Subject: [PATCH 12/96] Update LINEUPS.md --- LINEUPS.md | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/LINEUPS.md b/LINEUPS.md index 0280d0a..c9a8d30 100644 --- a/LINEUPS.md +++ b/LINEUPS.md @@ -1,7 +1,15 @@ -# lineups -Mission Run #1 (Description) -> The lineup -Mission Run #2 (Description) -> The lineup -Mission Run #3 (Description) -> The lineup -Mission Run #4 (Description) -> The lineup -Mission Run #5 (Description) -> The lineup -Mission Run #6 (Description) -> The lineup \ No newline at end of file +# Lineups + +## These are the line-up positions for the robot game for various missions. + +- Mission Run #1 (Mission #1) [Right/Blue Home] - The left yellow part of the right arm attachment is positioned with its right edge on the 5th thin line from the left. Note that this is NOT positioned from the back of the robot. + +- Mission Run #2 (Send Over) [Right/Blue Home] - The robot should be lined up on the vertical edge of the left home. The robot's right side should be positioned on the 1st thin line from the top. Note that the 0th line is the one that is not part of the curve. + +- Mission Run #3 (Sand mission) [Right/Blue Home] - The robot should be lined up on the vertical edge of the left home. The robot's left side should be positioned on the 1/2th thin line from the bottom. + +- Mission Run #4 (Boat mission) [Left/Red Home] - The robot should be lined up on the vertical edge of the left home. The robot's right side should be positioned on the 2nd thick line from the bottom. + +- Mission Run #5 (Bautism) [Left/Red Home] - The robot's left edge should be positioned at the 1st thick, 2nd thin line from the left. + +- Mission Run #6 (Not-so-heavy Lifting) [Right/Blue Home] - The robot's right edge should be positioned at the 1st thick from the right. \ No newline at end of file From 95c3491b44485526926f29a13ee447111a1ebd2d Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Sat, 4 Oct 2025 00:53:13 +0000 Subject: [PATCH 13/96] Update missions/M8_5.py --- missions/M8_5.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/missions/M8_5.py b/missions/M8_5.py index 69e364d..cf05500 100644 --- a/missions/M8_5.py +++ b/missions/M8_5.py @@ -30,12 +30,12 @@ async def main(): await right_arm.run_angle(5000,-500, Stop.HOLD) await drive_base.turn(-20) - await drive_base.straight(275) + await drive_base.straight(277) await drive_base.turn(20) - await drive_base.straight(63) + await drive_base.straight(65) await drive_base.turn(-30) - right_arm.run_angle(50,500) + right_arm.run_angle(70,500) await drive_base.turn(45) await drive_base.straight(-135) await drive_base.turn(-60) @@ -45,5 +45,5 @@ async def main(): await left_arm.run_angle(1000,450) await drive_base.straight(10) await drive_base.turn(35) - await drive_base.straight(-500) + await drive_base.straight(-600) run_task(main()) \ No newline at end of file From 8008dafccfccf636bba1c324470144f776aa8049 Mon Sep 17 00:00:00 2001 From: Ayaan <32agarwa@elmbrookstudents.org> Date: Sat, 4 Oct 2025 01:18:31 +0000 Subject: [PATCH 14/96] Add missions/tip the scale.py --- missions/tip the scale.py | 42 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 missions/tip the scale.py diff --git a/missions/tip the scale.py b/missions/tip the scale.py new file mode 100644 index 0000000..200b1ea --- /dev/null +++ b/missions/tip the scale.py @@ -0,0 +1,42 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) + +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(300,1000,300,200) + +#drive_base.use_gyro(True) + +async def main(): + left_arm.run_angle(500,200) + right_arm.run_angle(500,200) + await drive_base.straight(70) + + await drive_base.turn(-55) + await drive_base.straight(900) + await drive_base.turn(92.5) + + await drive_base.straight(75) + await drive_base.straight(21) + await right_arm.run_angle(500,-250) + await right_arm.run_angle(500,250) + await drive_base.turn(55) + + await left_arm.run_angle(300,-400) + + await drive_base.turn(46.5) + await drive_base.turn(-40) + await drive_base.straight(900) +run_task(main()) \ No newline at end of file From 89490033515d39d4647f627d1b71bbd33610caf9 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Mon, 6 Oct 2025 18:10:02 +0000 Subject: [PATCH 15/96] Mission 9 not in use --- missions/mission_09_old.py | 1 + 1 file changed, 1 insertion(+) diff --git a/missions/mission_09_old.py b/missions/mission_09_old.py index 3337624..ffdf445 100644 --- a/missions/mission_09_old.py +++ b/missions/mission_09_old.py @@ -1,4 +1,5 @@ # ---JOHANNES--- +# THIS CODE IS NOT USED ANYMORE AND SHOULD NOT BE USED!!!!!! from pybricks.hubs import PrimeHub from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor from pybricks.parameters import Button, Color, Direction, Port, Side, Stop From 4533f952ed19f29bd05bc29f2d8fd1f7935f8753 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Tue, 7 Oct 2025 12:32:40 +0000 Subject: [PATCH 16/96] Add stuff from Johannes accidental fork --- missions/Lift.py | 34 ++++++++++++++++++++++++++++++++++ missions/Lift2.py | 34 ++++++++++++++++++++++++++++++++++ 2 files changed, 68 insertions(+) create mode 100644 missions/Lift.py create mode 100644 missions/Lift2.py diff --git a/missions/Lift.py b/missions/Lift.py new file mode 100644 index 0000000..a5e1773 --- /dev/null +++ b/missions/Lift.py @@ -0,0 +1,34 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(525) + await drive_base.turn(60) + + await drive_base.straight(50) + await right_arm.run_angle(2000,1000) + await drive_base.straight(-50) + await drive_base.turn(45) + await drive_base.straight(50) + await right_arm.run_angle(350,-1000) + + await drive_base.turn(-100) + await drive_base.straight(-600) +run_task(main()) \ No newline at end of file diff --git a/missions/Lift2.py b/missions/Lift2.py new file mode 100644 index 0000000..a5e1773 --- /dev/null +++ b/missions/Lift2.py @@ -0,0 +1,34 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(525) + await drive_base.turn(60) + + await drive_base.straight(50) + await right_arm.run_angle(2000,1000) + await drive_base.straight(-50) + await drive_base.turn(45) + await drive_base.straight(50) + await right_arm.run_angle(350,-1000) + + await drive_base.turn(-100) + await drive_base.straight(-600) +run_task(main()) \ No newline at end of file From 2eca0d7d247c47b8544a74304b2bc3e613cf05b7 Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Sat, 4 Oct 2025 00:23:53 +0000 Subject: [PATCH 17/96] Initial commit Mission Run #5 --- missions/Bautism.py | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 missions/Bautism.py diff --git a/missions/Bautism.py b/missions/Bautism.py new file mode 100644 index 0000000..aeb80c2 --- /dev/null +++ b/missions/Bautism.py @@ -0,0 +1,45 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch, run_task + +hub = PrimeHub() + +# Initialize both motors. In this example, the motor on the +# left must turn counterclockwise to make the robot go forward. +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +arm_motor = Motor(Port.D, Direction.CLOCKWISE) +arm_motor_left= Motor(Port.C, Direction.CLOCKWISE) +# Initialize the drive base. In this example, the wheel diameter is 56mm. +# The distance between the two wheel-ground contact points is 112mm. +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) + +print('The default settings are: ' + str(drive_base.settings())) +drive_base.settings(300,1000,300,750) +# Optionally, uncomment the line below to use the gyro for improved accuracy. +drive_base.use_gyro(True) + +async def main(): + await drive_base.straight(519) + await arm_motor_left.run_angle(300, -100) + await arm_motor_left.run_angle(300, 500) + await drive_base.straight(180) + await drive_base.turn(-37) + await drive_base.straight(50) + await arm_motor.run_angle(300, -400) + await drive_base.straight(-150) + await drive_base.turn(135) + await drive_base.straight(50) + await arm_motor.run_angle(300, 400) + await drive_base.straight(-75) + await arm_motor.run_angle(300, 300) + await drive_base.turn(-50) + await drive_base.straight(162) + await arm_motor.run_angle(100, -200) + await drive_base.straight(30) + await arm_motor.run_angle(50,-500) + +run_task(main()) \ No newline at end of file From 4b765b0e9d5d9cba1b2417f8ca652afc6e22691d Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Sat, 4 Oct 2025 00:55:26 +0000 Subject: [PATCH 18/96] Update missions/M8_5.py --- missions/M8_5.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/missions/M8_5.py b/missions/M8_5.py index 69e364d..95ecc9e 100644 --- a/missions/M8_5.py +++ b/missions/M8_5.py @@ -30,14 +30,14 @@ async def main(): await right_arm.run_angle(5000,-500, Stop.HOLD) await drive_base.turn(-20) - await drive_base.straight(275) + await drive_base.straight(277) await drive_base.turn(20) - await drive_base.straight(63) + await drive_base.straight(65) await drive_base.turn(-30) right_arm.run_angle(50,500) await drive_base.turn(45) - await drive_base.straight(-135) + await drive_base.straight(-145) await drive_base.turn(-60) await drive_base.straight(90) await left_arm.run_angle(1000,-450) @@ -45,5 +45,5 @@ async def main(): await left_arm.run_angle(1000,450) await drive_base.straight(10) await drive_base.turn(35) - await drive_base.straight(-500) + await drive_base.straight(-600) run_task(main()) \ No newline at end of file From 08e0b9a521b5e6142496c148193099edf5c2d58b Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Wed, 8 Oct 2025 23:21:43 +0000 Subject: [PATCH 19/96] Delete missions/Lift2.py --- missions/Lift2.py | 34 ---------------------------------- 1 file changed, 34 deletions(-) delete mode 100644 missions/Lift2.py diff --git a/missions/Lift2.py b/missions/Lift2.py deleted file mode 100644 index a5e1773..0000000 --- a/missions/Lift2.py +++ /dev/null @@ -1,34 +0,0 @@ -from pybricks.hubs import PrimeHub -from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor -from pybricks.parameters import Button, Color, Direction, Port, Side, Stop -from pybricks.robotics import DriveBase -from pybricks.tools import wait, StopWatch -from pybricks.tools import run_task, multitask - -hub = PrimeHub() - -left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) -right_motor = Motor(Port.B) - -left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) -right_arm = Motor(Port.D) -drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) -drive_base.settings(600,500,300,200) -drive_base.use_gyro(True) - -async def main(): - await drive_base.straight(200) - await drive_base.turn(-20) - await drive_base.straight(525) - await drive_base.turn(60) - - await drive_base.straight(50) - await right_arm.run_angle(2000,1000) - await drive_base.straight(-50) - await drive_base.turn(45) - await drive_base.straight(50) - await right_arm.run_angle(350,-1000) - - await drive_base.turn(-100) - await drive_base.straight(-600) -run_task(main()) \ No newline at end of file From 1e612e2325278e1b7adc2215172165dda2d0c2ec Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Thu, 9 Oct 2025 12:23:15 +0000 Subject: [PATCH 20/96] Updated license information --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index fc9cc11..1d682dd 100644 --- a/README.md +++ b/README.md @@ -22,4 +22,7 @@ Load the master file into PyBricks, then send it over to the robot. Then you hol ## License GNU General Public License -You can take inspiration from our code, but you can't take our exact code. \ No newline at end of file + +You can take inspiration from our code, but you can't take our exact code. + +Read LICENSE for more information. \ No newline at end of file From 28e5bea6f5b3e900a6bbd1cccf17c4783fa477d7 Mon Sep 17 00:00:00 2001 From: nifrali Date: Thu, 9 Oct 2025 12:17:59 -0500 Subject: [PATCH 21/96] Updated README file with some formatting help from AI --- README.md | 147 +++++++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 130 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index 1d682dd..dfcd32c 100644 --- a/README.md +++ b/README.md @@ -1,28 +1,141 @@ -# 65266 Lego Dynamics - UNEARTHED Season Repository +# ๐Ÿค– 65266 Lego Dynamics - UNEARTHED Season -## Project Overview +
-This repository contains the Pybricks code for Team 65266 Lego Dynamics' robot for the UNEARTHED season. +**โšก Competitive Robotics Code for FLL SUBMERGEDโ„  Season โšก** -## Robot Hardware +![Team](https://img.shields.io/badge/Team-65266%20Lego%20Dynamics-blue?style=for-the-badge) +![Season](https://img.shields.io/badge/Season-UNEARTHED-green?style=for-the-badge) +![License](https://img.shields.io/badge/License-GPL-red?style=for-the-badge) -* **Robot Name:** Optimus Prime III -* **Robot Firmware:** PyBricks firmware -* **Motors:** Two large motors for attachments, C left, D right, Two small motors for drive, A left, B right -* **Sensors:** visible up-facing color sensor for quick starts -* **Attachments:** Lots of 'em +
-## Code Structure +--- -Files are the different runs we do, with each run consisting of one or multiple mission completions. Another script combines these files into a "master" file, which then adds the color-sensor-to-start logic. +## ๐Ÿ“‹ Project Overview -## How to Use +Welcome to the official code repository for **Team 65266 Lego Dynamics**! This repository contains all the Pybricks code powering our robot through the UNEARTHED season missions. Our modular approach allows for flexible mission execution and quick color-sensor-based run selection. -Load the master file into PyBricks, then send it over to the robot. Then you hold a color LEGO up to the sensor to start it. +--- -## License -GNU General Public License +## ๐Ÿฆพ Robot Hardware -You can take inspiration from our code, but you can't take our exact code. +### ๐ŸŽฏ Meet Optimus Prime III -Read LICENSE for more information. \ No newline at end of file +| Component | Specification | +|-----------|--------------| +| ๐Ÿค– **Robot Name** | Optimus Prime III | +| ๐Ÿ’พ **Firmware** | Pybricks | +| ๐Ÿ”ง **Attachment Motors** | 2ร— Large Motors (Ports C & D) | +| ๐Ÿš— **Drive Motors** | 2ร— Small Motors (Ports A & B) | +| ๐Ÿ‘๏ธ **Sensors** | Up-facing Color Sensor (Quick Start) | +| ๐Ÿ› ๏ธ **Attachments** | Multiple mission-specific tools | + +### โš™๏ธ Motor Configuration +- **Port A**: Left Drive Motor (Small) +- **Port B**: Right Drive Motor (Small) +- **Port C**: Left Attachment Motor (Large) +- **Port D**: Right Attachment Motor (Large) + +--- + +## ๐Ÿ“‚ Code Structure + +Our codebase is organized for maximum efficiency and modularity: + +``` +๐Ÿ“ฆ Repository + โ”ฃ ๐Ÿ“œ run_1.py # Individual mission runs + โ”ฃ ๐Ÿ“œ run_2.py # Each file = 1+ mission completions + โ”ฃ ๐Ÿ“œ run_3.py + โ”ฃ ๐Ÿ“œ ... + โ”— ๐Ÿ“œ master.py # ๐ŸŽฏ Combined master file with color-start logic +``` + +### ๐Ÿ”„ Workflow +1. **Individual Run Files** โ†’ Contain specific mission sequences +2. **Script Combination** โ†’ Merges runs into master file +3. **Color Sensor Logic** โ†’ Adds intelligent run selection based on color detection + +--- + +## ๐Ÿš€ How to Use + +### ๐Ÿ“ฅ Installation & Deployment + +1. **Load the Code** + ```bash + # Open the master.py file in Pybricks IDE + ``` + +2. **๐Ÿ”Œ Connect to Robot** + - Pair your robot via Bluetooth in Pybricks + +3. **๐Ÿ“ค Upload to Robot** + - Click "Download and Run" or send the program to the robot + +4. **๐ŸŽจ Start Your Run** + - Hold a colored LEGO brick up to the color sensor + - Different colors trigger different mission runs! + +### ๐ŸŽฎ Color Start System + +| ๐ŸŸฅ Red | ๐ŸŸฆ Blue | ๐ŸŸฉ Green | ๐ŸŸจ Yellow | +|--------|---------|----------|-----------| +| Run 1 | Run 2 | Run 3 | Run 4 | + +> **๐Ÿ’ก Pro Tip**: Organize your colored bricks before the match for quick run selection! + +--- + +## ๐Ÿ† Competition Notes + +- โฑ๏ธ **Quick Start**: Color sensor enables rapid run switching without reprogramming +- ๐ŸŽฏ **Modular Design**: Easy to test and modify individual missions +- ๐Ÿ”ง **Flexible Attachments**: Multiple tools optimized for different challenges + +--- + +## ๐Ÿค Contributing + +Team members can contribute by: +- ๐Ÿ› Reporting bugs via Issues +- ๐Ÿ’ก Suggesting mission optimizations +- ๐Ÿงช Testing new attachment designs +- ๐Ÿ“ Documenting successful strategies + +--- + +## ๐Ÿ“„ License + +**GNU General Public License v3.0** + +``` +๐Ÿ”’ You can take inspiration from our code, but you can't take our exact code. +``` + +This project is licensed under GPL-3.0 - see the [LICENSE](LICENSE) file for complete details. + +### ๐Ÿ“– What This Means: +- โœ… Learn from our approaches and strategies +- โœ… Understand our logic and algorithms +- โŒ Don't copy-paste our exact code +- โœ… Create your own unique implementations + +--- + +## ๐Ÿ“ž Contact & Support + +**Team 65266 Lego Dynamics** + +Questions about our approach? Interested in collaboration? Reach out! + +--- + +
+ +**๐Ÿ”ง Built with Passion | ๐Ÿค– Powered by Pybricks | ๐Ÿ† Competing for Excellence** + +โญ Star this repo if you found it helpful! โญ + +
\ No newline at end of file From 489add5722f89f34e251549e076d86bf8306a0eb Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Thu, 9 Oct 2025 21:13:36 +0000 Subject: [PATCH 22/96] Removed emojis --- README.md | 76 +++++++++++++++++++++++++++---------------------------- 1 file changed, 37 insertions(+), 39 deletions(-) diff --git a/README.md b/README.md index dfcd32c..3688d70 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# ๐Ÿค– 65266 Lego Dynamics - UNEARTHED Season +# 65266 Lego Dynamics - UNEARTHED Season
@@ -12,26 +12,26 @@ --- -## ๐Ÿ“‹ Project Overview +## Project Overview Welcome to the official code repository for **Team 65266 Lego Dynamics**! This repository contains all the Pybricks code powering our robot through the UNEARTHED season missions. Our modular approach allows for flexible mission execution and quick color-sensor-based run selection. --- -## ๐Ÿฆพ Robot Hardware +## Robot Hardware -### ๐ŸŽฏ Meet Optimus Prime III +### Meet Optimus Prime III | Component | Specification | |-----------|--------------| -| ๐Ÿค– **Robot Name** | Optimus Prime III | -| ๐Ÿ’พ **Firmware** | Pybricks | -| ๐Ÿ”ง **Attachment Motors** | 2ร— Large Motors (Ports C & D) | -| ๐Ÿš— **Drive Motors** | 2ร— Small Motors (Ports A & B) | -| ๐Ÿ‘๏ธ **Sensors** | Up-facing Color Sensor (Quick Start) | -| ๐Ÿ› ๏ธ **Attachments** | Multiple mission-specific tools | +| **Robot Name** | Optimus Prime III | +| **Firmware** | Pybricks | +| **Attachment Motors** | 2ร— Large Motors (Ports C & D) | +| **Drive Motors** | 2ร— Small Motors (Ports A & B) | +| **Sensors** | Up-facing Color Sensor (Quick Start) | +| **Attachments** | Multiple mission-specific tools | -### โš™๏ธ Motor Configuration +### Motor Configuration - **Port A**: Left Drive Motor (Small) - **Port B**: Right Drive Motor (Small) - **Port C**: Left Attachment Motor (Large) @@ -39,56 +39,56 @@ Welcome to the official code repository for **Team 65266 Lego Dynamics**! This r --- -## ๐Ÿ“‚ Code Structure +## Code Structure Our codebase is organized for maximum efficiency and modularity: ``` -๐Ÿ“ฆ Repository - โ”ฃ ๐Ÿ“œ run_1.py # Individual mission runs - โ”ฃ ๐Ÿ“œ run_2.py # Each file = 1+ mission completions - โ”ฃ ๐Ÿ“œ run_3.py - โ”ฃ ๐Ÿ“œ ... - โ”— ๐Ÿ“œ master.py # ๐ŸŽฏ Combined master file with color-start logic +Repository + โ”ฃ run_1.py # Individual mission runs + โ”ฃ run_2.py # Each file = 1+ mission completions + โ”ฃ run_3.py + โ”ฃ ... + โ”— master.py # ๐ŸŽฏ Combined master file with color-start logic ``` -### ๐Ÿ”„ Workflow +### Workflow 1. **Individual Run Files** โ†’ Contain specific mission sequences 2. **Script Combination** โ†’ Merges runs into master file 3. **Color Sensor Logic** โ†’ Adds intelligent run selection based on color detection --- -## ๐Ÿš€ How to Use +## How to Use -### ๐Ÿ“ฅ Installation & Deployment +### Installation & Deployment 1. **Load the Code** ```bash # Open the master.py file in Pybricks IDE ``` -2. **๐Ÿ”Œ Connect to Robot** +2. **Connect to Robot** - Pair your robot via Bluetooth in Pybricks -3. **๐Ÿ“ค Upload to Robot** +3. **Upload to Robot** - Click "Download and Run" or send the program to the robot -4. **๐ŸŽจ Start Your Run** +4. **Start Your Run** - Hold a colored LEGO brick up to the color sensor - Different colors trigger different mission runs! -### ๐ŸŽฎ Color Start System +### Color Start System | ๐ŸŸฅ Red | ๐ŸŸฆ Blue | ๐ŸŸฉ Green | ๐ŸŸจ Yellow | |--------|---------|----------|-----------| | Run 1 | Run 2 | Run 3 | Run 4 | -> **๐Ÿ’ก Pro Tip**: Organize your colored bricks before the match for quick run selection! +> **Tip**: Organize your colored bricks before the match for quick run selection! --- -## ๐Ÿ† Competition Notes +## Competition Notes - โฑ๏ธ **Quick Start**: Color sensor enables rapid run switching without reprogramming - ๐ŸŽฏ **Modular Design**: Easy to test and modify individual missions @@ -96,7 +96,7 @@ Our codebase is organized for maximum efficiency and modularity: --- -## ๐Ÿค Contributing +## Contributing Team members can contribute by: - ๐Ÿ› Reporting bugs via Issues @@ -106,25 +106,25 @@ Team members can contribute by: --- -## ๐Ÿ“„ License +## License **GNU General Public License v3.0** ``` -๐Ÿ”’ You can take inspiration from our code, but you can't take our exact code. +You can take inspiration from our code, but you can't take our exact code. ``` This project is licensed under GPL-3.0 - see the [LICENSE](LICENSE) file for complete details. -### ๐Ÿ“– What This Means: -- โœ… Learn from our approaches and strategies -- โœ… Understand our logic and algorithms -- โŒ Don't copy-paste our exact code -- โœ… Create your own unique implementations +### What This Means: +- Learn from our approaches and strategies +- Understand our logic and algorithms +- Don't copy-paste our exact code +- Create your own unique implementations --- -## ๐Ÿ“ž Contact & Support +## Contact & Support **Team 65266 Lego Dynamics** @@ -134,8 +134,6 @@ Questions about our approach? Interested in collaboration? Reach out!
-**๐Ÿ”ง Built with Passion | ๐Ÿค– Powered by Pybricks | ๐Ÿ† Competing for Excellence** - -โญ Star this repo if you found it helpful! โญ +Star this repo if you found it helpful!
\ No newline at end of file From ee099d91b3fdf3ab365b917e48ab3d0a7ba5fef2 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Thu, 9 Oct 2025 21:14:56 +0000 Subject: [PATCH 23/96] Switched to GPL v3 --- LICENSE | 676 +++++++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 617 insertions(+), 59 deletions(-) diff --git a/LICENSE b/LICENSE index 17cb286..496acdb 100644 --- a/LICENSE +++ b/LICENSE @@ -1,117 +1,675 @@ -GNU GENERAL PUBLIC LICENSE -Version 2, June 1991 +# GNU GENERAL PUBLIC LICENSE -Copyright (C) 1989, 1991 Free Software Foundation, Inc. -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA +Version 3, 29 June 2007 -Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. +Copyright (C) 2007 Free Software Foundation, Inc. + -Preamble +Everyone is permitted to copy and distribute verbatim copies of this +license document, but changing it is not allowed. -The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Lesser General Public License instead.) You can apply it to your programs, too. +## Preamble -When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things. +The GNU General Public License is a free, copyleft license for +software and other kinds of works. -To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it. +The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom +to share and change all versions of a program--to make sure it remains +free software for all its users. We, the Free Software Foundation, use +the GNU General Public License for most of our software; it applies +also to any other work released this way by its authors. You can apply +it to your programs, too. -For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. +When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. -We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software. +To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you +have certain responsibilities if you distribute copies of the +software, or if you modify it: responsibilities to respect the freedom +of others. -Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations. +For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. -Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all. +Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. -The precise terms and conditions for copying, distribution and modification follow. +For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION +Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the +manufacturer can do so. This is fundamentally incompatible with the +aim of protecting users' freedom to change the software. The +systematic pattern of such abuse occurs in the area of products for +individuals to use, which is precisely where it is most unacceptable. +Therefore, we have designed this version of the GPL to prohibit the +practice for those products. If such problems arise substantially in +other domains, we stand ready to extend this provision to those +domains in future versions of the GPL, as needed to protect the +freedom of users. -0. This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you". +Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish +to avoid the special danger that patents applied to a free program +could make it effectively proprietary. To prevent this, the GPL +assures that patents cannot be used to render the program non-free. -Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does. +The precise terms and conditions for copying, distribution and +modification follow. -1. You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program. +## TERMS AND CONDITIONS -You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. +### 0. Definitions. -2. You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: +"This License" refers to version 3 of the GNU General Public License. - a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change. +"Copyright" also means copyright-like laws that apply to other kinds +of works, such as semiconductor masks. - b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License. +"The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. - c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.) +To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of +an exact copy. The resulting work is called a "modified version" of +the earlier work or a work "based on" the earlier work. -These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. +A "covered work" means either the unmodified Program or a work based +on the Program. -Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program. +To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. -In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. +To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user +through a computer network, with no transfer of a copy, is not +conveying. -3. You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following: +An interactive user interface displays "Appropriate Legal Notices" to +the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. - a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, +### 1. Source Code. - b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, +The "source code" for a work means the preferred form of the work for +making modifications to it. "Object code" means any non-source form of +a work. - c) Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.) +A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. -The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. +The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. -If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code. +The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. -4. You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. +The Corresponding Source need not include anything that users can +regenerate automatically from other parts of the Corresponding Source. -5. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it. +The Corresponding Source for a work in source code form is that same +work. -6. Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License. +### 2. Basic Permissions. -7. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program. +All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. -If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances. +You may make, run and propagate covered works that you do not convey, +without conditions so long as your license otherwise remains in force. +You may convey covered works to others for the sole purpose of having +them make modifications exclusively for you, or provide you with +facilities for running those works, provided that you comply with the +terms of this License in conveying all material for which you do not +control copyright. Those thus making or running the covered works for +you must do so exclusively on your behalf, under your direction and +control, on terms that prohibit them from making any copies of your +copyrighted material outside their relationship with you. -It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. +Conveying under any other circumstances is permitted solely under the +conditions stated below. Sublicensing is not allowed; section 10 makes +it unnecessary. -This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. +### 3. Protecting Users' Legal Rights From Anti-Circumvention Law. -8. If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. +No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. -9. The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. +When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such +circumvention is effected by exercising rights under this License with +respect to the covered work, and you disclaim any intention to limit +operation or modification of the work as a means of enforcing, against +the work's users, your or third parties' legal rights to forbid +circumvention of technological measures. -Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation. +### 4. Conveying Verbatim Copies. -10. If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. +You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. -NO WARRANTY +You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. +### 5. Conveying Modified Source Versions. -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. +You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these +conditions: + +- a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. +- b) The work must carry prominent notices stating that it is + released under this License and any conditions added under + section 7. This requirement modifies the requirement in section 4 + to "keep intact all notices". +- c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. +- d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + +A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + +### 6. Conveying Non-Source Forms. + +You may convey a covered work in object code form under the terms of +sections 4 and 5, provided that you also convey the machine-readable +Corresponding Source under the terms of this License, in one of these +ways: + +- a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. +- b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the Corresponding + Source from a network server at no charge. +- c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. +- d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. +- e) Convey the object code using peer-to-peer transmission, + provided you inform other peers where the object code and + Corresponding Source of the work are being offered to the general + public at no charge under subsection 6d. + +A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + +A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, +family, or household purposes, or (2) anything designed or sold for +incorporation into a dwelling. In determining whether a product is a +consumer product, doubtful cases shall be resolved in favor of +coverage. For a particular product received by a particular user, +"normally used" refers to a typical or common use of that class of +product, regardless of the status of the particular user or of the way +in which the particular user actually uses, or expects or is expected +to use, the product. A product is a consumer product regardless of +whether the product has substantial commercial, industrial or +non-consumer uses, unless such uses represent the only significant +mode of use of the product. + +"Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to +install and execute modified versions of a covered work in that User +Product from a modified version of its Corresponding Source. The +information must suffice to ensure that the continued functioning of +the modified object code is in no case prevented or interfered with +solely because modification has been made. + +If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + +The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or +updates for a work that has been modified or installed by the +recipient, or for the User Product in which it has been modified or +installed. Access to a network may be denied when the modification +itself materially and adversely affects the operation of the network +or violates the rules and protocols for communication across the +network. + +Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + +### 7. Additional Terms. + +"Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + +When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + +Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders +of that material) supplement the terms of this License with terms: + +- a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or +- b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or +- c) Prohibiting misrepresentation of the origin of that material, + or requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or +- d) Limiting the use for publicity purposes of names of licensors + or authors of the material; or +- e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or +- f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions + of it) with contractual assumptions of liability to the recipient, + for any liability that these contractual assumptions directly + impose on those licensors and authors. + +All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + +If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + +Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; the +above requirements apply either way. + +### 8. Termination. + +You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + +However, if you cease all violation of this License, then your license +from a particular copyright holder is reinstated (a) provisionally, +unless and until the copyright holder explicitly and finally +terminates your license, and (b) permanently, if the copyright holder +fails to notify you of the violation by some reasonable means prior to +60 days after the cessation. + +Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + +Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + +### 9. Acceptance Not Required for Having Copies. + +You are not required to accept this License in order to receive or run +a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + +### 10. Automatic Licensing of Downstream Recipients. + +Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + +An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + +You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + +### 11. Patents. + +A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + +A contributor's "essential patent claims" are all patent claims owned +or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + +Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + +In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + +If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + +If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + +A patent license is "discriminatory" if it does not include within the +scope of its coverage, prohibits the exercise of, or is conditioned on +the non-exercise of one or more of the rights that are specifically +granted under this License. You may not convey a covered work if you +are a party to an arrangement with a third party that is in the +business of distributing software, under which you make payment to the +third party based on the extent of your activity of conveying the +work, and under which the third party grants, to any of the parties +who would receive the covered work from you, a discriminatory patent +license (a) in connection with copies of the covered work conveyed by +you (or copies made from those copies), or (b) primarily for and in +connection with specific products or compilations that contain the +covered work, unless you entered into that arrangement, or that patent +license was granted, prior to 28 March 2007. + +Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + +### 12. No Surrender of Others' Freedom. + +If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under +this License and any other pertinent obligations, then as a +consequence you may not convey it at all. For example, if you agree to +terms that obligate you to collect a royalty for further conveying +from those to whom you convey the Program, the only way you could +satisfy both those terms and this License would be to refrain entirely +from conveying the Program. + +### 13. Use with the GNU Affero General Public License. + +Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + +### 14. Revised Versions of this License. + +The Free Software Foundation may publish revised and/or new versions +of the GNU General Public License from time to time. Such new versions +will be similar in spirit to the present version, but may differ in +detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies that a certain numbered version of the GNU General Public +License "or any later version" applies to it, you have the option of +following the terms and conditions either of that numbered version or +of any later version published by the Free Software Foundation. If the +Program does not specify a version number of the GNU General Public +License, you may choose any version ever published by the Free +Software Foundation. + +If the Program specifies that a proxy can decide which future versions +of the GNU General Public License can be used, that proxy's public +statement of acceptance of a version permanently authorizes you to +choose that version for the Program. + +Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + +### 15. Disclaimer of Warranty. + +THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT +WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND +PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE +DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR +CORRECTION. + +### 16. Limitation of Liability. + +IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR +CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES +ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT +NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR +LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM +TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER +PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +### 17. Interpretation of Sections 15 and 16. + +If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. END OF TERMS AND CONDITIONS -How to Apply These Terms to Your New Programs +## How to Apply These Terms to Your New Programs -If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. +If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these +terms. -To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. +To do so, attach the following notices to the program. It is safest to +attach them to the start of each source file to most effectively state +the exclusion of warranty; and each file should have at least the +"copyright" line and a pointer to where the full notice is found. - one line to give the program's name and an idea of what it does. Copyright (C) yyyy name of author + + Copyright (C) - This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. - This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. - You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. Also add information on how to contact you by electronic and paper mail. + You should have received a copy of the GNU General Public License + along with this program. If not, see . -If the program is interactive, make it output a short notice like this when it starts in an interactive mode: +Also add information on how to contact you by electronic and paper +mail. - Gnomovision version 69, Copyright (C) year name of author Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. +If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: -The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, the commands you use may be called something other than `show w' and `show c'; they could even be mouse-clicks or menu items--whatever suits your program. + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. -You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the program, if necessary. Here is a sample; alter the names: +The hypothetical commands \`show w' and \`show c' should show the +appropriate parts of the General Public License. Of course, your +program's commands might be different; for a GUI interface, you would +use an "about box". - Yoyodyne, Inc., hereby disclaims all copyright interest in the program `Gnomovision' (which makes passes at compilers) written by James Hacker. +You should also get your employer (if you work as a programmer) or +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. For more information on this, and how to apply and follow +the GNU GPL, see . -signature of Ty Coon, 1 April 1989 Ty Coon, President of Vice +The GNU General Public License does not permit incorporating your +program into proprietary programs. If your program is a subroutine +library, you may consider it more useful to permit linking proprietary +applications with the library. If this is what you want to do, use the +GNU Lesser General Public License instead of this License. But first, +please read . From dd4fb8bda264838825fb410b4ba678429e15c7b9 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Thu, 9 Oct 2025 21:15:27 +0000 Subject: [PATCH 24/96] Switched to GPLv3 --- LICENSE | 713 ++++++++++++++++++++++++++++---------------------------- 1 file changed, 356 insertions(+), 357 deletions(-) diff --git a/LICENSE b/LICENSE index 496acdb..e72bfdd 100644 --- a/LICENSE +++ b/LICENSE @@ -1,205 +1,200 @@ -# GNU GENERAL PUBLIC LICENSE + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 -Version 3, 29 June 2007 + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. -Copyright (C) 2007 Free Software Foundation, Inc. - + Preamble -Everyone is permitted to copy and distribute verbatim copies of this -license document, but changing it is not allowed. - -## Preamble - -The GNU General Public License is a free, copyleft license for + The GNU General Public License is a free, copyleft license for software and other kinds of works. -The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom -to share and change all versions of a program--to make sure it remains -free software for all its users. We, the Free Software Foundation, use -the GNU General Public License for most of our software; it applies -also to any other work released this way by its authors. You can apply -it to your programs, too. + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things. -To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you -have certain responsibilities if you distribute copies of the -software, or if you modify it: responsibilities to respect the freedom -of others. + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. -For example, if you distribute copies of such a program, whether + For example, if you distribute copies of such a program, whether gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they know their rights. -Developers that use the GNU GPL protect your rights with two steps: + Developers that use the GNU GPL protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License giving you legal permission to copy, distribute and/or modify it. -For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and authors' sake, the GPL requires that modified versions be marked as changed, so that their problems will not be attributed erroneously to authors of previous versions. -Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the -manufacturer can do so. This is fundamentally incompatible with the -aim of protecting users' freedom to change the software. The -systematic pattern of such abuse occurs in the area of products for -individuals to use, which is precisely where it is most unacceptable. -Therefore, we have designed this version of the GPL to prohibit the -practice for those products. If such problems arise substantially in -other domains, we stand ready to extend this provision to those -domains in future versions of the GPL, as needed to protect the -freedom of users. + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. -Finally, every program is threatened constantly by software patents. + Finally, every program is threatened constantly by software patents. States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish -to avoid the special danger that patents applied to a free program -could make it effectively proprietary. To prevent this, the GPL -assures that patents cannot be used to render the program non-free. +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. -The precise terms and conditions for copying, distribution and + The precise terms and conditions for copying, distribution and modification follow. -## TERMS AND CONDITIONS + TERMS AND CONDITIONS -### 0. Definitions. + 0. Definitions. -"This License" refers to version 3 of the GNU General Public License. + "This License" refers to version 3 of the GNU General Public License. -"Copyright" also means copyright-like laws that apply to other kinds -of works, such as semiconductor masks. + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. -"The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and "recipients" may be individuals or organizations. -To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of -an exact copy. The resulting work is called a "modified version" of -the earlier work or a work "based on" the earlier work. + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. -A "covered work" means either the unmodified Program or a work based + A "covered work" means either the unmodified Program or a work based on the Program. -To "propagate" a work means to do anything with it that, without + To "propagate" a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, +computer or modifying a private copy. Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well. -To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user -through a computer network, with no transfer of a copy, is not -conveying. + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. -An interactive user interface displays "Appropriate Legal Notices" to -the extent that it includes a convenient and prominently visible + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If +work under this License, and how to view a copy of this License. If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion. -### 1. Source Code. + 1. Source Code. -The "source code" for a work means the preferred form of the work for -making modifications to it. "Object code" means any non-source form of -a work. + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. -A "Standard Interface" means an interface that either is an official + A "Standard Interface" means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language. -The "System Libraries" of an executable work include anything, other + The "System Libraries" of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A +implementation is available to the public in source code form. A "Major Component", in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it. -The "Corresponding Source" for a work in object code form means all + The "Corresponding Source" for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's +control those activities. However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source +which are not part of the work. For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those subprograms and other parts of the work. -The Corresponding Source need not include anything that users can -regenerate automatically from other parts of the Corresponding Source. + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. -The Corresponding Source for a work in source code form is that same -work. + The Corresponding Source for a work in source code form is that +same work. -### 2. Basic Permissions. + 2. Basic Permissions. -All rights granted under this License are granted for the term of + All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your +content, constitutes a covered work. This License acknowledges your rights of fair use or other equivalent, as provided by copyright law. -You may make, run and propagate covered works that you do not convey, -without conditions so long as your license otherwise remains in force. -You may convey covered works to others for the sole purpose of having -them make modifications exclusively for you, or provide you with -facilities for running those works, provided that you comply with the -terms of this License in conveying all material for which you do not -control copyright. Those thus making or running the covered works for -you must do so exclusively on your behalf, under your direction and -control, on terms that prohibit them from making any copies of your -copyrighted material outside their relationship with you. + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. -Conveying under any other circumstances is permitted solely under the -conditions stated below. Sublicensing is not allowed; section 10 makes -it unnecessary. + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. -### 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. -No covered work shall be deemed part of an effective technological + No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures. -When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such -circumvention is effected by exercising rights under this License with -respect to the covered work, and you disclaim any intention to limit -operation or modification of the work as a means of enforcing, against -the work's users, your or third parties' legal rights to forbid -circumvention of technological measures. + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. -### 4. Conveying Verbatim Copies. + 4. Conveying Verbatim Copies. -You may convey verbatim copies of the Program's source code as you + You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any @@ -207,56 +202,59 @@ non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program. -You may charge any price or no price for each copy that you convey, + You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee. -### 5. Conveying Modified Source Versions. + 5. Conveying Modified Source Versions. -You may convey a work based on the Program, or the modifications to + You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these -conditions: +terms of section 4, provided that you also meet all of these conditions: -- a) The work must carry prominent notices stating that you modified + a) The work must carry prominent notices stating that you modified it, and giving a relevant date. -- b) The work must carry prominent notices stating that it is - released under this License and any conditions added under - section 7. This requirement modifies the requirement in section 4 - to "keep intact all notices". -- c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no + regardless of how they are packaged. This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it. -- d) If the work has interactive user interfaces, each must display + + d) If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so. -A compilation of a covered work with other separate and independent + A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an "aggregate" if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work +beyond what the individual works permit. Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate. -### 6. Conveying Non-Source Forms. + 6. Conveying Non-Source Forms. -You may convey a covered work in object code form under the terms of -sections 4 and 5, provided that you also convey the machine-readable -Corresponding Source under the terms of this License, in one of these -ways: + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: -- a) Convey the object code in, or embodied in, a physical product + a) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange. -- b) Convey the object code in, or embodied in, a physical product + + b) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product @@ -265,190 +263,196 @@ ways: product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the Corresponding - Source from a network server at no charge. -- c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b. -- d) Convey the object code by offering access from a designated + + d) Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the + Corresponding Source. Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements. -- e) Convey the object code using peer-to-peer transmission, - provided you inform other peers where the object code and - Corresponding Source of the work are being offered to the general - public at no charge under subsection 6d. -A separable portion of the object code, whose source code is excluded + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work. -A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, -family, or household purposes, or (2) anything designed or sold for -incorporation into a dwelling. In determining whether a product is a -consumer product, doubtful cases shall be resolved in favor of -coverage. For a particular product received by a particular user, -"normally used" refers to a typical or common use of that class of -product, regardless of the status of the particular user or of the way -in which the particular user actually uses, or expects or is expected -to use, the product. A product is a consumer product regardless of -whether the product has substantial commercial, industrial or -non-consumer uses, unless such uses represent the only significant -mode of use of the product. + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. -"Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to -install and execute modified versions of a covered work in that User -Product from a modified version of its Corresponding Source. The -information must suffice to ensure that the continued functioning of -the modified object code is in no case prevented or interfered with -solely because modification has been made. + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. -If you convey an object code work under this section in, or with, or + If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply +by the Installation Information. But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM). -The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or -updates for a work that has been modified or installed by the -recipient, or for the User Product in which it has been modified or -installed. Access to a network may be denied when the modification -itself materially and adversely affects the operation of the network -or violates the rules and protocols for communication across the -network. + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. -Corresponding Source conveyed, and Installation Information provided, + Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying. -### 7. Additional Terms. + 7. Additional Terms. -"Additional permissions" are terms that supplement the terms of this + "Additional permissions" are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions +that they are valid under applicable law. If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions. -When you convey a copy of a covered work, you may at your option + When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission. -Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders -of that material) supplement the terms of this License with terms: + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: -- a) Disclaiming warranty or limiting liability differently from the + a) Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or -- b) Requiring preservation of specified reasonable legal notices or + + b) Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or -- c) Prohibiting misrepresentation of the origin of that material, - or requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or -- d) Limiting the use for publicity purposes of names of licensors - or authors of the material; or -- e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or -- f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions - of it) with contractual assumptions of liability to the recipient, - for any liability that these contractual assumptions directly - impose on those licensors and authors. -All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains +restriction, you may remove that term. If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying. -If you add terms to a covered work in accord with this section, you + If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms. -Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; the -above requirements apply either way. + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. -### 8. Termination. + 8. Termination. -You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11). -However, if you cease all violation of this License, then your license -from a particular copyright holder is reinstated (a) provisionally, -unless and until the copyright holder explicitly and finally -terminates your license, and (b) permanently, if the copyright holder -fails to notify you of the violation by some reasonable means prior to -60 days after the cessation. + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. -Moreover, your license from a particular copyright holder is + Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice. -Termination of your rights under this section does not terminate the + Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently +this License. If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10. -### 9. Acceptance Not Required for Having Copies. + 9. Acceptance Not Required for Having Copies. -You are not required to accept this License in order to receive or run -a copy of the Program. Ancillary propagation of a covered work + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, +to receive a copy likewise does not require acceptance. However, nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so. -### 10. Automatic Licensing of Downstream Recipients. + 10. Automatic Licensing of Downstream Recipients. -Each time you convey a covered work, the recipient automatically + Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible +propagate that work, subject to this License. You are not responsible for enforcing compliance by third parties with this License. -An "entity transaction" is a transaction transferring control of an + An "entity transaction" is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered +organization, or merging organizations. If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could @@ -456,43 +460,43 @@ give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts. -You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it. -### 11. Patents. + 11. Patents. -A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The work thus licensed is called the contributor's "contributor version". -A contributor's "essential patent claims" are all patent claims owned -or controlled by the contributor, whether already acquired or + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For +consequence of further modification of the contributor version. For purposes of this definition, "control" includes the right to grant patent sublicenses in a manner consistent with the requirements of this License. -Each contributor grants you a non-exclusive, worldwide, royalty-free + Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version. -In the following three paragraphs, a "patent license" is any express + In the following three paragraphs, a "patent license" is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a +sue for patent infringement). To "grant" such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party. -If you convey a covered work, knowingly relying on a patent license, + If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, @@ -500,13 +504,13 @@ then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have +license to downstream recipients. "Knowingly relying" means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid. -If, pursuant to or in connection with a single transaction or + If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify @@ -514,162 +518,157 @@ or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it. -A patent license is "discriminatory" if it does not include within the -scope of its coverage, prohibits the exercise of, or is conditioned on -the non-exercise of one or more of the rights that are specifically -granted under this License. You may not convey a covered work if you -are a party to an arrangement with a third party that is in the -business of distributing software, under which you make payment to the -third party based on the extent of your activity of conveying the -work, and under which the third party grants, to any of the parties -who would receive the covered work from you, a discriminatory patent -license (a) in connection with copies of the covered work conveyed by -you (or copies made from those copies), or (b) primarily for and in -connection with specific products or compilations that contain the -covered work, unless you entered into that arrangement, or that patent -license was granted, prior to 28 March 2007. + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. -Nothing in this License shall be construed as excluding or limiting + Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law. -### 12. No Surrender of Others' Freedom. + 12. No Surrender of Others' Freedom. -If conditions are imposed on you (whether by court order, agreement or + If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under -this License and any other pertinent obligations, then as a -consequence you may not convey it at all. For example, if you agree to -terms that obligate you to collect a royalty for further conveying -from those to whom you convey the Program, the only way you could -satisfy both those terms and this License would be to refrain entirely -from conveying the Program. +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. -### 13. Use with the GNU Affero General Public License. + 13. Use with the GNU Affero General Public License. -Notwithstanding any other provision of this License, you have + Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this +combined work, and to convey the resulting work. The terms of this License will continue to apply to the part which is the covered work, but the special requirements of the GNU Affero General Public License, section 13, concerning interaction through a network will apply to the combination as such. -### 14. Revised Versions of this License. + 14. Revised Versions of this License. -The Free Software Foundation may publish revised and/or new versions -of the GNU General Public License from time to time. Such new versions -will be similar in spirit to the present version, but may differ in -detail to address new problems or concerns. + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. -Each version is given a distinguishing version number. If the Program -specifies that a certain numbered version of the GNU General Public -License "or any later version" applies to it, you have the option of -following the terms and conditions either of that numbered version or -of any later version published by the Free Software Foundation. If the -Program does not specify a version number of the GNU General Public -License, you may choose any version ever published by the Free -Software Foundation. + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. -If the Program specifies that a proxy can decide which future versions -of the GNU General Public License can be used, that proxy's public -statement of acceptance of a version permanently authorizes you to -choose that version for the Program. + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. -Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version. -### 15. Disclaimer of Warranty. + 15. Disclaimer of Warranty. -THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT -WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND -PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE -DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR -CORRECTION. + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. -### 16. Limitation of Liability. + 16. Limitation of Liability. -IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR -CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES -ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT -NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR -LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM -TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER -PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. -### 17. Interpretation of Sections 15 and 16. + 17. Interpretation of Sections 15 and 16. -If the disclaimer of warranty and limitation of liability provided + If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee. -END OF TERMS AND CONDITIONS + END OF TERMS AND CONDITIONS -## How to Apply These Terms to Your New Programs + How to Apply These Terms to Your New Programs -If you develop a new program, and you want it to be of the greatest + If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these -terms. +free software which everyone can redistribute and change under these terms. -To do so, attach the following notices to the program. It is safest to -attach them to the start of each source file to most effectively state -the exclusion of warranty; and each file should have at least the -"copyright" line and a pointer to where the full notice is found. + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. - - Copyright (C) + + Copyright (C) - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. - You should have received a copy of the GNU General Public License - along with this program. If not, see . + You should have received a copy of the GNU General Public License + along with this program. If not, see . -Also add information on how to contact you by electronic and paper -mail. +Also add information on how to contact you by electronic and paper mail. -If the program does terminal interaction, make it output a short + If the program does terminal interaction, make it output a short notice like this when it starts in an interactive mode: - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. -The hypothetical commands \`show w' and \`show c' should show the -appropriate parts of the General Public License. Of course, your -program's commands might be different; for a GUI interface, you would -use an "about box". +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". -You should also get your employer (if you work as a programmer) or -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. For more information on this, and how to apply and follow -the GNU GPL, see . + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. -The GNU General Public License does not permit incorporating your -program into proprietary programs. If your program is a subroutine -library, you may consider it more useful to permit linking proprietary -applications with the library. If this is what you want to do, use the -GNU Lesser General Public License instead of this License. But first, -please read . + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. \ No newline at end of file From f7072a6207d0eaeb796260383ac4e2fbb79e6237 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 10 Oct 2025 20:56:17 +0000 Subject: [PATCH 25/96] Update final/main4.py --- final/main4.py | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/final/main4.py b/final/main4.py index 7dc67cc..098e8a4 100644 --- a/final/main4.py +++ b/final/main4.py @@ -25,13 +25,13 @@ async def Run1(): await right_arm.run_angle(5000,500, Stop.HOLD) await right_arm.run_angle(5000,-500, Stop.HOLD) await drive_base.turn(-20) - await drive_base.straight(275) + await drive_base.straight(277) await drive_base.turn(20) - await drive_base.straight(63) + await drive_base.straight(65) await drive_base.turn(-30) right_arm.run_angle(50,500) await drive_base.turn(45) - await drive_base.straight(-135) + await drive_base.straight(-145) await drive_base.turn(-60) await drive_base.straight(90) await left_arm.run_angle(1000,-450) @@ -39,7 +39,7 @@ async def Run1(): await left_arm.run_angle(1000,450) await drive_base.straight(10) await drive_base.turn(35) - await drive_base.straight(-500) + await drive_base.straight(-600) async def Run2(): await drive_base.straight(200) await drive_base.turn(-20) @@ -51,15 +51,16 @@ async def Run2(): await drive_base.turn(45) await drive_base.straight(50) await right_arm.run_angle(350,-1000) + await drive_base.straight(-100) await drive_base.turn(-100) await drive_base.straight(-600) async def Run3(): - await drive_base.straight(915) - await drive_base.turn(-90) - await drive_base.straight(60) - await left_arm.run_angle(10000,-15000) - await drive_base.straight(-60) - await drive_base.turn(85) + await drive_base.straight(920) + await drive_base.turn(-90,Stop.HOLD) + await drive_base.straight(65) + await left_arm.run_angle(10000,-3000) + await drive_base.straight(-100) + await drive_base.turn(90) await drive_base.straight(2000) async def Run5(): await drive_base.straight(420) From 42090eae56f9166b7a3eb102678eede9c2a617f3 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 10 Oct 2025 21:02:03 +0000 Subject: [PATCH 26/96] Update final/main4.py --- final/main4.py | 1 + 1 file changed, 1 insertion(+) diff --git a/final/main4.py b/final/main4.py index 098e8a4..d45f9d3 100644 --- a/final/main4.py +++ b/final/main4.py @@ -58,6 +58,7 @@ async def Run3(): await drive_base.straight(920) await drive_base.turn(-90,Stop.HOLD) await drive_base.straight(65) + drive_base.turn(-10) await left_arm.run_angle(10000,-3000) await drive_base.straight(-100) await drive_base.turn(90) From 2d9eb496a3a78df4e8ab50259fb385fcd8f5896c Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 10 Oct 2025 21:03:57 +0000 Subject: [PATCH 27/96] Update final/main4.py --- final/main4.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/final/main4.py b/final/main4.py index d45f9d3..3d112d8 100644 --- a/final/main4.py +++ b/final/main4.py @@ -59,7 +59,7 @@ async def Run3(): await drive_base.turn(-90,Stop.HOLD) await drive_base.straight(65) drive_base.turn(-10) - await left_arm.run_angle(10000,-3000) + await left_arm.run_angle(10000,-4000) await drive_base.straight(-100) await drive_base.turn(90) await drive_base.straight(2000) From b6cffc6760a53a1a91786cf196a600782c51777b Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Fri, 10 Oct 2025 21:16:17 +0000 Subject: [PATCH 28/96] Update final/4main --- final/{main4emaj.py => 4main} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename final/{main4emaj.py => 4main} (100%) diff --git a/final/main4emaj.py b/final/4main similarity index 100% rename from final/main4emaj.py rename to final/4main From 785c95552450e8d0180e2cc2e80bf4f9b1840316 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Fri, 10 Oct 2025 21:16:29 +0000 Subject: [PATCH 29/96] Update final/4main.py --- final/{4main => 4main.py} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename final/{4main => 4main.py} (100%) diff --git a/final/4main b/final/4main.py similarity index 100% rename from final/4main rename to final/4main.py From 45402694bdaa1645a3d9858eff1095dcc45ccadd Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 10 Oct 2025 21:19:30 +0000 Subject: [PATCH 30/96] Update final/4main.py --- final/4main.py | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/final/4main.py b/final/4main.py index 5335147..7d57c8c 100644 --- a/final/4main.py +++ b/final/4main.py @@ -55,13 +55,13 @@ async def Run1(): await right_arm.run_angle(5000,500, Stop.HOLD) await right_arm.run_angle(5000,-500, Stop.HOLD) await drive_base.turn(-20) - await drive_base.straight(275) + await drive_base.straight(277) await drive_base.turn(20) - await drive_base.straight(63) + await drive_base.straight(65) await drive_base.turn(-30) right_arm.run_angle(50,500) await drive_base.turn(45) - await drive_base.straight(-135) + await drive_base.straight(-145) await drive_base.turn(-60) await drive_base.straight(90) await left_arm.run_angle(1000,-450) @@ -69,7 +69,7 @@ async def Run1(): await left_arm.run_angle(1000,450) await drive_base.straight(10) await drive_base.turn(35) - await drive_base.straight(-500) + await drive_base.straight(-600) async def Run2(): await drive_base.straight(200) await drive_base.turn(-20) @@ -85,12 +85,13 @@ async def Run2(): await drive_base.turn(-100) await drive_base.straight(-600) async def Run3(): - await drive_base.straight(915) + await drive_base.straight(920) await drive_base.turn(-90) await drive_base.straight(60) - await left_arm.run_angle(10000,-15000) - await drive_base.straight(-60) - await drive_base.turn(85) + drive_base.turn(-10) + await left_arm.run_angle(10000,-4000) + await drive_base.straight(-110) + await drive_base.turn(90) await drive_base.straight(2000) async def Run5(): await drive_base.straight(420) From a3b04d3e00872e756f2edfbdb50b562181cc58d3 Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Fri, 10 Oct 2025 21:25:32 +0000 Subject: [PATCH 31/96] Add final/main5.py --- final/main5.py | 278 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 278 insertions(+) create mode 100644 final/main5.py diff --git a/final/main5.py b/final/main5.py new file mode 100644 index 0000000..73e506e --- /dev/null +++ b/final/main5.py @@ -0,0 +1,278 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor +from pybricks.parameters import Port, Stop, Color, Direction +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch, multitask, run_task + +hub = PrimeHub() +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) +left_arm = Motor(Port.C)#, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(550,700,100,100) +drive_base.use_gyro(True) +color_sensor = ColorSensor(Port.F) +Color.ORANGE = Color(37, 85, 95) +Color.BLUE = Color(230,100,100) +color_sensor.detectable_colors([Color.ORANGE, Color.BLUE, Color.GREEN, Color.WHITE, Color.RED, Color.YELLOW]) +hub.speaker.volume(50) # Set the volume of the speaker +color_sensor.detectable_colors() +# Celebration sound types +class CelebrationSound: + VICTORY_FANFARE = 0 + LEVEL_UP = 1 + SUCCESS_CHIME = 2 + TA_DA = 3 + POWER_UP = 4 + RICKROLL_INSPIRED = 5 + +async def play_victory_fanfare(): + """Classic victory fanfare""" + notes = [ + (262, 200), # C4 + (262, 200), # C4 + (262, 200), # C4 + (349, 600), # F4 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(50) +async def play_level_up(): + """Upward scale for level completion""" + notesold = [ + (262, 100), # C4 + (294, 100), # D4 + (330, 100), # E4 + (349, 100), # F4 + (392, 100), # G4 + (440, 100), # A4 + (494, 100), # B4 + (523, 300), # C5 + ] + notes = [ + (277, 100), + (330, 100), + (277, 100), + (554, 100), + (277, 100), + (413, 100), + (330, 100), + (277, 100), + (413, 100), + (277, 100), + (554, 100), + (413, 100), + (277, 100), + (413, 100), + (554, 100), + (413, 100) + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + #await wait(20) +async def play_success_chime(): + """Simple success notification""" + notes = [ + (523, 150), # C5 + (659, 150), # E5 + (784, 300), # G5 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(50) +async def play_ta_da(): + """Classic "ta-da!" sound""" + notes = [ + (392, 200), # G4 + (523, 400), # C5 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(100) +async def play_power_up(): + """Rising power-up sound""" + for freq in range(200, 800, 50): + await hub.speaker.beep(freq, 50) + await wait(10) + await hub.speaker.beep(1000, 200) +async def play_rickroll_inspired(): + """Fun 80s-style dance beat inspired sound""" + # Upbeat bouncy rhythm + pattern = [ + (392, 200), (440, 200), (494, 200), (523, 200), + (440, 200), (392, 200), (349, 200), (392, 300), + (440, 200), (392, 200), (349, 200), (330, 400), + ] + + for freq, duration in pattern: + await hub.speaker.beep(freq, duration) + await wait(50) +async def celebrate_mission_complete(sound_type=CelebrationSound.SUCCESS_CHIME): + """ + Main celebration function to call after completing a mission. + Plays a sound and shows light animation. + + Args: + sound_type: CelebrationSound enum value (default: SUCCESS_CHIME) + """ + # Light show + hub.light.on(Color.GREEN) + + # Play the selected celebration sound + if sound_type == CelebrationSound.VICTORY_FANFARE: + await play_victory_fanfare() + elif sound_type == CelebrationSound.LEVEL_UP: + await play_level_up() + elif sound_type == CelebrationSound.SUCCESS_CHIME: + await play_success_chime() + elif sound_type == CelebrationSound.TA_DA: + await play_ta_da() + elif sound_type == CelebrationSound.POWER_UP: + await play_power_up() + elif sound_type == CelebrationSound.RICKROLL_INSPIRED: + await play_rickroll_inspired() + else: + await play_success_chime() # Default fallback + + # Blink the light + for _ in range(3): + hub.light.off() + await wait(100) + hub.light.on(Color.GREEN) + await wait(100) + + hub.light.off() + +async def Run1(): + await multitask(left_arm.run_angle(1000, 300), right_arm.run_angle(1000,500)) + await drive_base.straight(320) + + await right_arm.run_angle(5000,-500, Stop.HOLD) + await right_arm.run_angle(5000,500, Stop.HOLD) + await right_arm.run_angle(5000,-500, Stop.HOLD) + await right_arm.run_angle(5000,500, Stop.HOLD) + await right_arm.run_angle(5000,-500, Stop.HOLD) + + await drive_base.turn(-20) + await drive_base.straight(275) + await drive_base.turn(20) + await drive_base.straight(63) + + await multitask(drive_base.turn(-30), right_arm.run_angle(50,500)) + await drive_base.turn(45) + await drive_base.straight(-135) + await drive_base.turn(-60) + await drive_base.straight(90) + await left_arm.run_angle(1000,-450) + await drive_base.straight(-145) + await left_arm.run_angle(1000,450) + await drive_base.straight(10) + await drive_base.turn(35) + await drive_base.straight(-500) + +async def Run2(): + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(525) + await drive_base.turn(60) + + await drive_base.straight(50) + await right_arm.run_angle(2000,1000) + await drive_base.straight(-50) + await drive_base.turn(45) + await drive_base.straight(50) + await right_arm.run_angle(350,-1000) + + await drive_base.turn(-100) + await drive_base.straight(-600) + + +async def Run3(): + await drive_base.straight(915) + await drive_base.turn(-90) + await drive_base.straight(60) + await left_arm.run_angle(10000,-15000) + await drive_base.straight(-60) + await drive_base.turn(85) + await drive_base.straight(2000) + +async def Run4(): + await drive_base.straight(519) + await left_arm.run_angle(300, -100) + await left_arm.run_angle(300, 500) + await drive_base.straight(180) + await drive_base.turn(-37) + await drive_base.straight(50) + await right_arm.run_angle(300, -400) + await drive_base.straight(-150) + await drive_base.turn(125) + await drive_base.straight(50) + await right_arm.run_angle(300, 400) + await drive_base.straight(-75) + await right_arm.run_angle(300, 300) + await drive_base.turn(-40) + await drive_base.straight(250) + await right_arm.run_angle(100, -300) + await drive_base.straight(30) + await right_arm.run_angle(50,-300) + await drive_base.turn(30) + await drive_base.straight(-200) + await drive_base.turn(-50) + await drive_base.straight(-800) + +async def Run5(): + await drive_base.straight(420) + await right_arm.run_angle(300,-100) + await drive_base.straight(-100) + await right_arm.run_angle(300, 100) + await drive_base.straight(-350) + + +async def Run6(): + await drive_base.straight(420) + await right_arm.run_angle(300,-100) + await drive_base.straight(-100) + await right_arm.run_angle(300, 100) + await drive_base.straight(-350) +async def main(): + while True: + + await celebrate_mission_complete(CelebrationSound.LEVEL_UP) + color_reflected_percent = await color_sensor.reflection() + print(color_reflected_percent) + + color_detected = await color_sensor.color() + print(f'Detected color: {color_detected.h}, {color_detected.s}, {color_detected.v}') + if color_reflected_percent > 0: + if color_detected == Color.GREEN: + print('Running Mission 1') + await Run1() + await celebrate_mission_complete(CelebrationSound.VICTORY_FANFARE) + elif color_detected == Color.WHITE: + print('Running Mission 2') + await Run2() + await celebrate_mission_complete(CelebrationSound.RICKROLL_INSPIRED) + elif color_detected == Color.YELLOW: + print('Running Mission 3') + await Run3() + await celebrate_mission_complete(CelebrationSound.SUCCESS_CHIME ) + elif color_detected == Color.BLUE: + print('Running Mission 4') + await Run4() + await celebrate_mission_complete(CelebrationSound.POWER_UP) + elif color_detected == Color.RED: + print('Running Mission 5') + await Run5() + await celebrate_mission_complete(CelebrationSound.LEVEL_UP) + else: + hub.light.off() + left_motor.stop() + right_motor.stop() + await wait(1000) #prevent loop from iterating fast +# Main execution loop +run_task(main()) From 29bd9f0e23b4be6da0dbf1bf0ac068e20535e5c6 Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Fri, 10 Oct 2025 21:27:24 +0000 Subject: [PATCH 32/96] Update final/main5.py --- final/main5.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/final/main5.py b/final/main5.py index 73e506e..6de5776 100644 --- a/final/main5.py +++ b/final/main5.py @@ -273,6 +273,6 @@ async def main(): hub.light.off() left_motor.stop() right_motor.stop() - await wait(1000) #prevent loop from iterating fast + await wait(100) #prevent loop from iterating fast # Main execution loop run_task(main()) From 52214be68eb4c76a8c5d26088b47aec80f379eff Mon Sep 17 00:00:00 2001 From: Ayaan <32agarwa@elmbrookstudents.org> Date: Fri, 10 Oct 2025 21:35:56 +0000 Subject: [PATCH 33/96] Update final/4main.py --- final/4main.py | 22 +++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/final/4main.py b/final/4main.py index 7d57c8c..5d61c7e 100644 --- a/final/4main.py +++ b/final/4main.py @@ -100,11 +100,23 @@ async def Run5(): await right_arm.run_angle(300, 100) await drive_base.straight(-350) async def Run6(): - await drive_base.straight(420) - await right_arm.run_angle(300,-100) - await drive_base.straight(-100) - await right_arm.run_angle(300, 100) - await drive_base.straight(-350) + left_arm.run_angle(500,200) + right_arm.run_angle(500,200) + await drive_base.straight(70) + await drive_base.turn(-55) + await drive_base.straight(900) + await drive_base.turn(92.5) + await drive_base.straight(75) + await drive_base.straight(21) + await right_arm.run_angle(500,-250) + await right_arm.run_angle(500,250) + await drive_base.straight(-20) + await drive_base.turn(55) + await left_arm.run_angle(300,-400) + await drive_base.turn(70) + await left_arm.run_angle(300,400) + await drive_base.turn(-60) + await drive_base.straight(900) # Celebration sound types class CelebrationSound: VICTORY_FANFARE = 0 From 7e2dc0b7c99eca606458f95a1b2072378c368b22 Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Fri, 10 Oct 2025 21:44:03 +0000 Subject: [PATCH 34/96] Update final/main5.py --- final/main5.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/final/main5.py b/final/main5.py index 6de5776..2b0fcd6 100644 --- a/final/main5.py +++ b/final/main5.py @@ -219,7 +219,7 @@ async def Run4(): await drive_base.straight(250) await right_arm.run_angle(100, -300) await drive_base.straight(30) - await right_arm.run_angle(50,-300) + await right_arm.run_angle(50,-250) await drive_base.turn(30) await drive_base.straight(-200) await drive_base.turn(-50) @@ -273,6 +273,6 @@ async def main(): hub.light.off() left_motor.stop() right_motor.stop() - await wait(100) #prevent loop from iterating fast + await wait(1000) #prevent loop from iterating fast # Main execution loop run_task(main()) From bbdf0d0e3af24bd2251d9dd525e2b6933a475884 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Sat, 11 Oct 2025 02:25:18 +0000 Subject: [PATCH 35/96] Shortened fun sounds --- twist_scrimmage.py | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/twist_scrimmage.py b/twist_scrimmage.py index d2c3047..b796f44 100644 --- a/twist_scrimmage.py +++ b/twist_scrimmage.py @@ -249,11 +249,7 @@ async def play_power_up(): async def play_rickroll_inspired(): """Fun 80s-style dance beat inspired sound""" # Upbeat bouncy rhythm - pattern = [ - (cn["Gs3"], 200), (cn["A3"], 200), (cn["B3"], 200), (cn["Cs4"], 200), - (cn["A3"], 200), (cn["Gs3"], 200), (cn["Fs3"], 200), (cn["Gs3"], 400), - (cn["A3"], 200), (cn["Gs3"], 200), (cn["Fs3"], 200), (cn["E3"], 400), - ] + pattern = [ (cn["B3"], 100), (cn["Cs4"], 100), (cn["Ds4"], 100), (cn["E4"], 100), (cn["Cs4"], 100), (cn["B3"], 100), (cn["A3"], 100), (cn["B3"], 200), (cn["Cs4"], 100), (cn["B3"], 100), (cn["A3"], 100), (cn["Gs3"], 200), ] @@ -262,7 +258,7 @@ async def play_rickroll_inspired(): #await wait(50) # Basically a big if else statement that calls the functions above -async def celebrate_mission_complete(sound_type=CelebrationSound.WAITING_SOUND): +async def celebrate_mission_complete(sound_type=CelebrationSound.RICKROLL_INSPIRED): """ Main celebration function to call after completing a mission. Plays a sound and shows light animation. @@ -302,7 +298,7 @@ async def celebrate_mission_complete(sound_type=CelebrationSound.WAITING_SOUND): async def main(): # MAIN LOOP while True: - await celebrate_mission_complete(CelebrationSound.WAITING_SOUND) + await celebrate_mission_complete(CelebrationSound.RICKROLL_INSPIRED) color_reflected_percent = await color_sensor.reflection() print(f"Color reflection percentage: {color_reflected_percent}") From d66aecd5ebdbb2520ee1f877a3b1a3bfba7dd623 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Sat, 11 Oct 2025 02:29:50 +0000 Subject: [PATCH 36/96] Update README.md --- README.md | 34 +++++++++++++++++++--------------- 1 file changed, 19 insertions(+), 15 deletions(-) diff --git a/README.md b/README.md index 3688d70..49a400b 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,12 @@ -# 65266 Lego Dynamics - UNEARTHED Season +# 65266 Lego Dynamics - UNEARTHED Season Robot Code
-**โšก Competitive Robotics Code for FLL SUBMERGEDโ„  Season โšก** +**Competitive Robotics Code for FLL SUBMERGEDโ„  Season** ![Team](https://img.shields.io/badge/Team-65266%20Lego%20Dynamics-blue?style=for-the-badge) ![Season](https://img.shields.io/badge/Season-UNEARTHED-green?style=for-the-badge) -![License](https://img.shields.io/badge/License-GPL-red?style=for-the-badge) +![License](https://img.shields.io/badge/License-GPLv3-red?style=for-the-badge)
@@ -79,30 +79,34 @@ Repository - Different colors trigger different mission runs! ### Color Start System +| Color | Mission | Celebration Sound | +|-------|-----------|------------------| +| Green ๐ŸŸฉ | Run 1 | Victory Fanfare | +| White โšช | Run 2 | Rickroll Inspired | +| Yellow ๐ŸŸจ | Run 3 | Success Chime | +| Orange ๐ŸŸง | Run 4 | Power Up | +| Blue ๐ŸŸฆ | Run 5 | Power Up | +| Red ๐ŸŸฅ | Run 6 | Ta-Da! | -| ๐ŸŸฅ Red | ๐ŸŸฆ Blue | ๐ŸŸฉ Green | ๐ŸŸจ Yellow | -|--------|---------|----------|-----------| -| Run 1 | Run 2 | Run 3 | Run 4 | - -> **Tip**: Organize your colored bricks before the match for quick run selection! +> **Tip** Organize your colored bricks before the match for quick run selection! --- ## Competition Notes -- โฑ๏ธ **Quick Start**: Color sensor enables rapid run switching without reprogramming -- ๐ŸŽฏ **Modular Design**: Easy to test and modify individual missions -- ๐Ÿ”ง **Flexible Attachments**: Multiple tools optimized for different challenges +- **Quick Start**: Color sensor enables rapid run switching without reprogramming +- **Modular Design**: Easy to test and modify individual missions +- **Flexible Attachments**: Multiple tools optimized for different challenges --- ## Contributing Team members can contribute by: -- ๐Ÿ› Reporting bugs via Issues -- ๐Ÿ’ก Suggesting mission optimizations -- ๐Ÿงช Testing new attachment designs -- ๐Ÿ“ Documenting successful strategies +- Reporting bugs via Issues +- Suggesting mission optimizations +- Testing new attachment designs +- Documenting successful strategies --- From 8391619c717ed4ce6f26fc4fe5823d0b69162012 Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Sat, 11 Oct 2025 15:24:59 +0000 Subject: [PATCH 37/96] Add members/Rishi.txt --- members/Rishi.txt | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 members/Rishi.txt diff --git a/members/Rishi.txt b/members/Rishi.txt new file mode 100644 index 0000000..e69de29 From ae114667f1651d0c7eb510cbe1c7f2e8fd83661b Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Sat, 11 Oct 2025 15:27:44 +0000 Subject: [PATCH 38/96] Update members/Rishi.txt --- members/Rishi.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/members/Rishi.txt b/members/Rishi.txt index e69de29..88bea53 100644 --- a/members/Rishi.txt +++ b/members/Rishi.txt @@ -0,0 +1,2 @@ +Hi I'm Rishi, the coding manager for Team: 65266 +I love coding and making things that probably end the world. \ No newline at end of file From 1a3abbb4d14f70b83109edd793afbe650a1bc40c Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Sat, 11 Oct 2025 18:03:55 +0000 Subject: [PATCH 39/96] Update twist_scrimmage.py --- twist_scrimmage.py | 389 +++++++++++++++++++-------------------------- 1 file changed, 163 insertions(+), 226 deletions(-) diff --git a/twist_scrimmage.py b/twist_scrimmage.py index b796f44..2b0fcd6 100644 --- a/twist_scrimmage.py +++ b/twist_scrimmage.py @@ -1,11 +1,9 @@ -# Imports... because we kinda need them... from pybricks.hubs import PrimeHub from pybricks.pupdevices import Motor, ColorSensor from pybricks.parameters import Port, Stop, Color, Direction from pybricks.robotics import DriveBase from pybricks.tools import wait, StopWatch, multitask, run_task -# Sets all the default values for the runs hub = PrimeHub() left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) right_motor = Motor(Port.B) @@ -17,59 +15,157 @@ drive_base.use_gyro(True) color_sensor = ColorSensor(Port.F) Color.ORANGE = Color(37, 85, 95) Color.BLUE = Color(230,100,100) -Color.YELLOW = Color(53, 75, 84) -color_sensor.detectable_colors([Color.YELLOW, Color.BLUE, Color.GREEN, Color.WHITE, Color.RED, Color.ORANGE, Color.NONE]) +color_sensor.detectable_colors([Color.ORANGE, Color.BLUE, Color.GREEN, Color.WHITE, Color.RED, Color.YELLOW]) hub.speaker.volume(50) # Set the volume of the speaker color_sensor.detectable_colors() +# Celebration sound types +class CelebrationSound: + VICTORY_FANFARE = 0 + LEVEL_UP = 1 + SUCCESS_CHIME = 2 + TA_DA = 3 + POWER_UP = 4 + RICKROLL_INSPIRED = 5 + +async def play_victory_fanfare(): + """Classic victory fanfare""" + notes = [ + (262, 200), # C4 + (262, 200), # C4 + (262, 200), # C4 + (349, 600), # F4 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(50) +async def play_level_up(): + """Upward scale for level completion""" + notesold = [ + (262, 100), # C4 + (294, 100), # D4 + (330, 100), # E4 + (349, 100), # F4 + (392, 100), # G4 + (440, 100), # A4 + (494, 100), # B4 + (523, 300), # C5 + ] + notes = [ + (277, 100), + (330, 100), + (277, 100), + (554, 100), + (277, 100), + (413, 100), + (330, 100), + (277, 100), + (413, 100), + (277, 100), + (554, 100), + (413, 100), + (277, 100), + (413, 100), + (554, 100), + (413, 100) + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + #await wait(20) +async def play_success_chime(): + """Simple success notification""" + notes = [ + (523, 150), # C5 + (659, 150), # E5 + (784, 300), # G5 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(50) +async def play_ta_da(): + """Classic "ta-da!" sound""" + notes = [ + (392, 200), # G4 + (523, 400), # C5 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(100) +async def play_power_up(): + """Rising power-up sound""" + for freq in range(200, 800, 50): + await hub.speaker.beep(freq, 50) + await wait(10) + await hub.speaker.beep(1000, 200) +async def play_rickroll_inspired(): + """Fun 80s-style dance beat inspired sound""" + # Upbeat bouncy rhythm + pattern = [ + (392, 200), (440, 200), (494, 200), (523, 200), + (440, 200), (392, 200), (349, 200), (392, 300), + (440, 200), (392, 200), (349, 200), (330, 400), + ] + + for freq, duration in pattern: + await hub.speaker.beep(freq, duration) + await wait(50) +async def celebrate_mission_complete(sound_type=CelebrationSound.SUCCESS_CHIME): + """ + Main celebration function to call after completing a mission. + Plays a sound and shows light animation. + + Args: + sound_type: CelebrationSound enum value (default: SUCCESS_CHIME) + """ + # Light show + hub.light.on(Color.GREEN) + + # Play the selected celebration sound + if sound_type == CelebrationSound.VICTORY_FANFARE: + await play_victory_fanfare() + elif sound_type == CelebrationSound.LEVEL_UP: + await play_level_up() + elif sound_type == CelebrationSound.SUCCESS_CHIME: + await play_success_chime() + elif sound_type == CelebrationSound.TA_DA: + await play_ta_da() + elif sound_type == CelebrationSound.POWER_UP: + await play_power_up() + elif sound_type == CelebrationSound.RICKROLL_INSPIRED: + await play_rickroll_inspired() + else: + await play_success_chime() # Default fallback + + # Blink the light + for _ in range(3): + hub.light.off() + await wait(100) + hub.light.on(Color.GREEN) + await wait(100) + + hub.light.off() -# Notes to hertz for nice music -cn = { - "Cs3": 138.59, - "D3": 146.83, - "Ds3": 155.56, - "E3": 164.81, - "F3": 174.61, - "Fs3": 185.00, - "G3": 196.00, - "Gs3": 207.65, - "A3": 220.00, - "As3": 233.08, - "B3": 246.94, - "C4": 261.63, - "Cs4": 277.18, - "D4": 293.66, - "Ds4": 311.13, - "E4": 329.63, - "F4": 349.23, - "Fs4": 369.99, - "G4": 392.00, - "Gs4": 415.30, - "A4": 440.00, - "As4": 466.16, - "B4": 493.88, - "C5": 523.25, - "Cs5": 554.37 -} - - -# RUNS - contains the mission code that will be executed on color sensor detection async def Run1(): - left_arm.run_angle(1000, 300) - right_arm.run_angle(1000,500) + await multitask(left_arm.run_angle(1000, 300), right_arm.run_angle(1000,500)) await drive_base.straight(320) + await right_arm.run_angle(5000,-500, Stop.HOLD) await right_arm.run_angle(5000,500, Stop.HOLD) await right_arm.run_angle(5000,-500, Stop.HOLD) await right_arm.run_angle(5000,500, Stop.HOLD) await right_arm.run_angle(5000,-500, Stop.HOLD) + await drive_base.turn(-20) - await drive_base.straight(277) + await drive_base.straight(275) await drive_base.turn(20) - await drive_base.straight(65) - await drive_base.turn(-30) - right_arm.run_angle(50,500) + await drive_base.straight(63) + + await multitask(drive_base.turn(-30), right_arm.run_angle(50,500)) await drive_base.turn(45) - await drive_base.straight(-145) + await drive_base.straight(-135) await drive_base.turn(-60) await drive_base.straight(90) await left_arm.run_angle(1000,-450) @@ -77,31 +173,32 @@ async def Run1(): await left_arm.run_angle(1000,450) await drive_base.straight(10) await drive_base.turn(35) - await drive_base.straight(-600) + await drive_base.straight(-500) async def Run2(): await drive_base.straight(200) await drive_base.turn(-20) await drive_base.straight(525) await drive_base.turn(60) + await drive_base.straight(50) await right_arm.run_angle(2000,1000) await drive_base.straight(-50) await drive_base.turn(45) await drive_base.straight(50) await right_arm.run_angle(350,-1000) - await drive_base.straight(-100) + await drive_base.turn(-100) await drive_base.straight(-600) + async def Run3(): - await drive_base.straight(920) + await drive_base.straight(915) await drive_base.turn(-90) await drive_base.straight(60) - drive_base.turn(-10) - await left_arm.run_angle(10000,-4000) - await drive_base.straight(-110) - await drive_base.turn(90) + await left_arm.run_angle(10000,-15000) + await drive_base.straight(-60) + await drive_base.turn(85) await drive_base.straight(2000) async def Run4(): @@ -135,177 +232,22 @@ async def Run5(): await right_arm.run_angle(300, 100) await drive_base.straight(-350) + async def Run6(): - left_arm.run_angle(500,200) - right_arm.run_angle(500,200) - await drive_base.straight(70) - await drive_base.turn(-55) - await drive_base.straight(900) - await drive_base.turn(92.5) - await drive_base.straight(75) - await drive_base.straight(21) - await right_arm.run_angle(500,-250) - await right_arm.run_angle(500,250) - await drive_base.straight(-20) - await drive_base.turn(55) - await left_arm.run_angle(300,-400) - await drive_base.turn(70) - await left_arm.run_angle(300,400) - await drive_base.turn(-60) - await drive_base.straight(900) - -# Celebration sound types -class CelebrationSound: - VICTORY_FANFARE = 0 - WAITING_SOUND = 1 - SUCCESS_CHIME = 2 - TA_DA = 3 - POWER_UP = 4 - RICKROLL_INSPIRED = 5 - -# Sounds functions -async def play_victory_fanfare(): - """Classic victory fanfare""" - notes = [ - (cn["B3"], 200), - (cn["B3"], 100), - (cn["B3"], 100), - (cn["E4"], 600) - ] - - for freq, duration in notes: - await hub.speaker.beep(freq, duration) - await wait(50) -async def play_waiting_sound(): - - # T3rm1na1 V3l0c1ty arpeggio recreated in pybricks - notes = [ - (cn["Cs4"], 100), - (cn["E4"], 100), - (cn["Cs4"], 100), - (cn["Cs5"], 100), - (cn["Cs4"], 100), - (cn["Gs4"], 100), - (cn["E4"], 100), - (cn["Cs4"], 100), - (cn["Gs4"], 100), - (cn["Cs4"], 100), - (cn["Cs5"], 100), - (cn["Gs4"], 100), - (cn["Cs4"], 100), - (cn["Gs4"], 100), - (cn["Cs5"], 100), - (cn["Gs4"], 100) - ] - - - for freq, duration in notes: - await hub.speaker.beep(freq, duration) -async def play_success_chime(): - """Simple success notification""" - notes = [ - (cn["E4"], 150), - (cn["Gs4"], 150), - (cn["B4"], 300), - ] - - - for freq, duration in notes: - await hub.speaker.beep(freq, duration) - await wait(50) -async def play_ta_da(): - """Classic "ta-da!" sound""" - notes = [ - (cn["Cs4"], 200), - (cn["Ds4"], 200), - (cn["E4"], 200), - (cn["Ds4"], 200), - (cn["E4"], 200), - (cn["Fs4"], 400), - (cn["Gs4"], 600), - (cn["Fs4"], 400), - (cn["Gs4"], 200), - (cn["A4"], 200), - (cn["B4"], 200), - (cn["C5"], 200), - (cn["Cs5"], 200) - ] - - for freq, duration in notes: - await hub.speaker.beep(freq, duration) - #await wait(100) -async def play_power_up(): - """Rising power-up sound""" - frequencies = [ - 164.81, 207.65, 246.94, 329.63, 415.30, 493.88 - ] - - for freq in frequencies: - await hub.speaker.beep(freq, 50) - await wait(10) - - - await hub.speaker.beep(659.24, 200) -async def play_rickroll_inspired(): - """Fun 80s-style dance beat inspired sound""" - # Upbeat bouncy rhythm - pattern = [ (cn["B3"], 100), (cn["Cs4"], 100), (cn["Ds4"], 100), (cn["E4"], 100), (cn["Cs4"], 100), (cn["B3"], 100), (cn["A3"], 100), (cn["B3"], 200), (cn["Cs4"], 100), (cn["B3"], 100), (cn["A3"], 100), (cn["Gs3"], 200), ] - - - - for freq, duration in pattern: - await hub.speaker.beep(freq, duration) - #await wait(50) - -# Basically a big if else statement that calls the functions above -async def celebrate_mission_complete(sound_type=CelebrationSound.RICKROLL_INSPIRED): - """ - Main celebration function to call after completing a mission. - Plays a sound and shows light animation. - - Args: - sound_type: CelebrationSound enum value (default: SUCCESS_CHIME) - """ - # Light show - hub.light.on(Color.GREEN) - - # Play the selected celebration sound - if sound_type == CelebrationSound.VICTORY_FANFARE: - await play_victory_fanfare() - elif sound_type == CelebrationSound.WAITING_SOUND: - await play_waiting_sound() - elif sound_type == CelebrationSound.SUCCESS_CHIME: - await play_success_chime() - elif sound_type == CelebrationSound.TA_DA: - await play_ta_da() - elif sound_type == CelebrationSound.POWER_UP: - await play_power_up() - elif sound_type == CelebrationSound.RICKROLL_INSPIRED: - await play_rickroll_inspired() - else: - await play_success_chime() # Default fallback - - # Blink the light - for _ in range(3): - hub.light.off() - await wait(100) - hub.light.on(Color.GREEN) - await wait(100) - - hub.light.off() - -# This where everything happens + await drive_base.straight(420) + await right_arm.run_angle(300,-100) + await drive_base.straight(-100) + await right_arm.run_angle(300, 100) + await drive_base.straight(-350) async def main(): - # MAIN LOOP while True: - await celebrate_mission_complete(CelebrationSound.RICKROLL_INSPIRED) + + await celebrate_mission_complete(CelebrationSound.LEVEL_UP) color_reflected_percent = await color_sensor.reflection() - print(f"Color reflection percentage: {color_reflected_percent}") + print(color_reflected_percent) color_detected = await color_sensor.color() - print(f'Detected color: {color_detected}') - hsv = await color_sensor.hsv() - print(f"Measured HSV: {hsv}") + print(f'Detected color: {color_detected.h}, {color_detected.s}, {color_detected.v}') if color_reflected_percent > 0: if color_detected == Color.GREEN: print('Running Mission 1') @@ -318,24 +260,19 @@ async def main(): elif color_detected == Color.YELLOW: print('Running Mission 3') await Run3() - await celebrate_mission_complete(CelebrationSound.SUCCESS_CHIME) - elif color_detected == Color.ORANGE: + await celebrate_mission_complete(CelebrationSound.SUCCESS_CHIME ) + elif color_detected == Color.BLUE: print('Running Mission 4') await Run4() await celebrate_mission_complete(CelebrationSound.POWER_UP) - elif color_detected == Color.BLUE: + elif color_detected == Color.RED: print('Running Mission 5') await Run5() - await celebrate_mission_complete(CelebrationSound.POWER_UP) - elif color_detected == Color.RED: - print('Running Mission 6') - await Run6() - await celebrate_mission_complete(CelebrationSound.TA_DA) + await celebrate_mission_complete(CelebrationSound.LEVEL_UP) else: hub.light.off() left_motor.stop() right_motor.stop() - else: - print("No color was detected.") - await wait(100) # prevent loop from iterating fast -run_task(main()) \ No newline at end of file + await wait(1000) #prevent loop from iterating fast +# Main execution loop +run_task(main()) From 9b04c18889b21db32c2f003b8a77572d201b0698 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Sat, 11 Oct 2025 18:22:21 +0000 Subject: [PATCH 40/96] Update for contest --- twist_scrimmage.py | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/twist_scrimmage.py b/twist_scrimmage.py index 2b0fcd6..1e2d7f1 100644 --- a/twist_scrimmage.py +++ b/twist_scrimmage.py @@ -149,23 +149,22 @@ async def celebrate_mission_complete(sound_type=CelebrationSound.SUCCESS_CHIME): hub.light.off() async def Run1(): - await multitask(left_arm.run_angle(1000, 300), right_arm.run_angle(1000,500)) + left_arm.run_angle(1000, 300) + right_arm.run_angle(1000,500) await drive_base.straight(320) - await right_arm.run_angle(5000,-500, Stop.HOLD) await right_arm.run_angle(5000,500, Stop.HOLD) await right_arm.run_angle(5000,-500, Stop.HOLD) await right_arm.run_angle(5000,500, Stop.HOLD) await right_arm.run_angle(5000,-500, Stop.HOLD) - await drive_base.turn(-20) - await drive_base.straight(275) + await drive_base.straight(277) await drive_base.turn(20) - await drive_base.straight(63) - - await multitask(drive_base.turn(-30), right_arm.run_angle(50,500)) + await drive_base.straight(65) + await drive_base.turn(-30) + right_arm.run_angle(50,500) await drive_base.turn(45) - await drive_base.straight(-135) + await drive_base.straight(-145) await drive_base.turn(-60) await drive_base.straight(90) await left_arm.run_angle(1000,-450) @@ -173,7 +172,7 @@ async def Run1(): await left_arm.run_angle(1000,450) await drive_base.straight(10) await drive_base.turn(35) - await drive_base.straight(-500) + await drive_base.straight(-600) async def Run2(): await drive_base.straight(200) @@ -187,18 +186,19 @@ async def Run2(): await drive_base.turn(45) await drive_base.straight(50) await right_arm.run_angle(350,-1000) - + await drive_base.straight(-100) await drive_base.turn(-100) await drive_base.straight(-600) async def Run3(): - await drive_base.straight(915) + await drive_base.straight(920) await drive_base.turn(-90) await drive_base.straight(60) - await left_arm.run_angle(10000,-15000) - await drive_base.straight(-60) - await drive_base.turn(85) + drive_base.turn(-10) + await left_arm.run_angle(10000,-4000) + await drive_base.straight(-110) + await drive_base.turn(90) await drive_base.straight(2000) async def Run4(): @@ -242,7 +242,7 @@ async def Run6(): async def main(): while True: - await celebrate_mission_complete(CelebrationSound.LEVEL_UP) + #await celebrate_mission_complete(CelebrationSound.LEVEL_UP) color_reflected_percent = await color_sensor.reflection() print(color_reflected_percent) @@ -252,23 +252,23 @@ async def main(): if color_detected == Color.GREEN: print('Running Mission 1') await Run1() - await celebrate_mission_complete(CelebrationSound.VICTORY_FANFARE) + #await celebrate_mission_complete(CelebrationSound.VICTORY_FANFARE) elif color_detected == Color.WHITE: print('Running Mission 2') await Run2() - await celebrate_mission_complete(CelebrationSound.RICKROLL_INSPIRED) + #await celebrate_mission_complete(CelebrationSound.RICKROLL_INSPIRED) elif color_detected == Color.YELLOW: print('Running Mission 3') await Run3() - await celebrate_mission_complete(CelebrationSound.SUCCESS_CHIME ) + #await celebrate_mission_complete(CelebrationSound.SUCCESS_CHIME ) elif color_detected == Color.BLUE: print('Running Mission 4') await Run4() - await celebrate_mission_complete(CelebrationSound.POWER_UP) + #await celebrate_mission_complete(CelebrationSound.POWER_UP) elif color_detected == Color.RED: print('Running Mission 5') await Run5() - await celebrate_mission_complete(CelebrationSound.LEVEL_UP) + #await celebrate_mission_complete(CelebrationSound.LEVEL_UP) else: hub.light.off() left_motor.stop() From 19afacd87b641facc594d031b8cf261aff30288b Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Sat, 11 Oct 2025 18:47:09 +0000 Subject: [PATCH 41/96] Scrimmage update after run 2 well at least yellow works now. --- twist_scrimmage.py | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/twist_scrimmage.py b/twist_scrimmage.py index 1e2d7f1..9e066f7 100644 --- a/twist_scrimmage.py +++ b/twist_scrimmage.py @@ -15,6 +15,7 @@ drive_base.use_gyro(True) color_sensor = ColorSensor(Port.F) Color.ORANGE = Color(37, 85, 95) Color.BLUE = Color(230,100,100) +Color.YELLOW = Color(37, 85, 95) color_sensor.detectable_colors([Color.ORANGE, Color.BLUE, Color.GREEN, Color.WHITE, Color.RED, Color.YELLOW]) hub.speaker.volume(50) # Set the volume of the speaker color_sensor.detectable_colors() @@ -149,7 +150,7 @@ async def celebrate_mission_complete(sound_type=CelebrationSound.SUCCESS_CHIME): hub.light.off() async def Run1(): - left_arm.run_angle(1000, 300) + left_arm.run_angle(1000, -300) right_arm.run_angle(1000,500) await drive_base.straight(320) await right_arm.run_angle(5000,-500, Stop.HOLD) @@ -167,12 +168,12 @@ async def Run1(): await drive_base.straight(-145) await drive_base.turn(-60) await drive_base.straight(90) - await left_arm.run_angle(1000,-450) + await left_arm.run_angle(1000, 450) await drive_base.straight(-145) - await left_arm.run_angle(1000,450) + await left_arm.run_angle(1000,-450) await drive_base.straight(10) await drive_base.turn(35) - await drive_base.straight(-600) + await drive_base.straight(-700) async def Run2(): await drive_base.straight(200) @@ -188,7 +189,7 @@ async def Run2(): await right_arm.run_angle(350,-1000) await drive_base.straight(-100) await drive_base.turn(-100) - await drive_base.straight(-600) + await drive_base.straight(-750) async def Run3(): @@ -248,7 +249,7 @@ async def main(): color_detected = await color_sensor.color() print(f'Detected color: {color_detected.h}, {color_detected.s}, {color_detected.v}') - if color_reflected_percent > 0: + if color_reflected_percent > 1: if color_detected == Color.GREEN: print('Running Mission 1') await Run1() From 5e1f3098f9bd07bf80bfeec1d8959ea6ff06b41a Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Sat, 11 Oct 2025 19:08:38 +0000 Subject: [PATCH 42/96] Changes after scrimmage run 3 --- twist_scrimmage.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/twist_scrimmage.py b/twist_scrimmage.py index 9e066f7..8f68b24 100644 --- a/twist_scrimmage.py +++ b/twist_scrimmage.py @@ -204,26 +204,28 @@ async def Run3(): async def Run4(): await drive_base.straight(519) - await left_arm.run_angle(300, -100) - await left_arm.run_angle(300, 500) + await left_arm.run_angle(300, -200) + await left_arm.run_angle(800, 1000) await drive_base.straight(180) await drive_base.turn(-37) + await right_arm.run_angle(300, -50) await drive_base.straight(50) - await right_arm.run_angle(300, -400) + await right_arm.run_angle(300, -350) await drive_base.straight(-150) await drive_base.turn(125) await drive_base.straight(50) await right_arm.run_angle(300, 400) await drive_base.straight(-75) - await right_arm.run_angle(300, 300) + await right_arm.run_angle(300, -200) await drive_base.turn(-40) - await drive_base.straight(250) + await right_arm.run_angle(300, 250) + await drive_base.straight(260) await right_arm.run_angle(100, -300) await drive_base.straight(30) await right_arm.run_angle(50,-250) await drive_base.turn(30) await drive_base.straight(-200) - await drive_base.turn(-50) + await drive_base.turn(-67) await drive_base.straight(-800) async def Run5(): From 8061eb71d552c80a18683aed7ae5b442cb8ce31e Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 17 Oct 2025 20:51:55 +0000 Subject: [PATCH 43/96] Add missions/Boat_mission.py --- missions/Boat_mission.py | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 missions/Boat_mission.py diff --git a/missions/Boat_mission.py b/missions/Boat_mission.py new file mode 100644 index 0000000..6d87949 --- /dev/null +++ b/missions/Boat_mission.py @@ -0,0 +1,27 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task,multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) + +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) + +drive_base.settings(880,850,700,700) + +drive_base.use_gyro(True) + +first_run = True + +async def main(): + await drive_base.straight(750) + await drive_base.straight(-650) + +run_task(main()) \ No newline at end of file From f69c61e796eb8726e00d0db5914ed46a95c564ca Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 17 Oct 2025 20:52:24 +0000 Subject: [PATCH 44/96] Add missions/Sand_mission.py --- missions/Sand_mission.py | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 missions/Sand_mission.py diff --git a/missions/Sand_mission.py b/missions/Sand_mission.py new file mode 100644 index 0000000..368ba5c --- /dev/null +++ b/missions/Sand_mission.py @@ -0,0 +1,29 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task,multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) + +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) + +drive_base.settings(400,500,100,100) + +drive_base.use_gyro(True) + + +async def main(): + await drive_base.straight(500) + await right_arm.run_angle(300,100) + await drive_base.straight(-100) + await right_arm.run_angle(300,-100) + await drive_base.straight(-350) + +run_task(main()) \ No newline at end of file From c6783889b78338f092c7d97f62b8df6dccc04788 Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Sun, 19 Oct 2025 01:51:03 +0000 Subject: [PATCH 45/96] Add missions/Set2.py Please add the backward part of the code. --- missions/Set2.py | 50 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 missions/Set2.py diff --git a/missions/Set2.py b/missions/Set2.py new file mode 100644 index 0000000..9298da3 --- /dev/null +++ b/missions/Set2.py @@ -0,0 +1,50 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch, run_task, multitask + +hub = PrimeHub() + +# Initialize both motors. In this example, the motor on the +# left must turn counterclockwise to make the robot go forward. +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +arm_motor = Motor(Port.D, Direction.CLOCKWISE) +arm_motor_left= Motor(Port.C, Direction.CLOCKWISE) +# Initialize the drive base. In this example, the wheel diameter is 56mm. +# The distance between the two wheel-ground contact points is 112mm. +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) + +print('The default settings are: ' + str(drive_base.settings())) +drive_base.settings(300,1000,300,750) +# Optionally, uncomment the line below to use the gyro for improved accuracy. +drive_base.use_gyro(True) + +async def main(): + await drive_base.straight(519) + await arm_motor_left.run_angle(-10000, 300) + await arm_motor_left.run_angle(10000, 600) + await drive_base.straight(160) + await drive_base.turn(-30) + await drive_base.straight(50) + await arm_motor.run_angle(3000, 3000) + await drive_base.straight(-150) + await drive_base.turn(135) + await drive_base.straight(50) + await arm_motor.run_angle(10000, -3000) + await drive_base.straight(-100) + await drive_base.turn(-54) + await arm_motor.run_angle(10000, -3000) + await drive_base.straight(250) + await drive_base.turn(-5) + await arm_motor.run_angle(10000, 7000) + await drive_base.straight(-50) + await drive_base.turn(68) + await arm_motor.run_angle(10000, -6000) + await drive_base.straight(200) + await arm_motor.run_angle(10000, 4000) + await drive_base.turn(-40) + await arm_motor.run_angle(10000, 7000) +run_task(main()) \ No newline at end of file From 53d13476a9a5f8cd5efa95d69ef8c4bc0747e911 Mon Sep 17 00:00:00 2001 From: Parthiv <31vadlap@elmbrookstudents.org> Date: Sun, 19 Oct 2025 03:02:40 +0000 Subject: [PATCH 46/96] Add missions/Heavy lifting.py --- missions/Heavy lifting.py | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 missions/Heavy lifting.py diff --git a/missions/Heavy lifting.py b/missions/Heavy lifting.py new file mode 100644 index 0000000..643e47d --- /dev/null +++ b/missions/Heavy lifting.py @@ -0,0 +1,37 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + await right_arm.run_angle(2000,1000) + + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(525) + await drive_base.turn(60) + await drive_base.straight(30) + + await right_arm.run_angle(2000,-1000) + await drive_base.straight(30) + await right_arm.run_angle(3000,1000) + await drive_base.straight(-60) + + await drive_base.turn(-60) + await drive_base.straight(-525) + await drive_base.turn(20) + await drive_base.straight(-200) + From 51d7255cd0e1820a82c06df25b0d004a7617b61b Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Mon, 20 Oct 2025 00:48:18 +0000 Subject: [PATCH 47/96] Add HEAVY_LIFTING_UPD --- HEAVY_LIFTING_UPD | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 HEAVY_LIFTING_UPD diff --git a/HEAVY_LIFTING_UPD b/HEAVY_LIFTING_UPD new file mode 100644 index 0000000..da0f004 --- /dev/null +++ b/HEAVY_LIFTING_UPD @@ -0,0 +1,33 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(536) + await drive_base.turn(60, Stop.HOLD) + await drive_base.straight(30) + + await right_arm.run_angle(5000,3000) + await drive_base.straight(40) + await right_arm.run_angle(5000,-4000) + await drive_base.straight(-60) + + await drive_base.turn(-60) + await drive_base.straight(-670) +run_task(main()) \ No newline at end of file From 9c2b3a2ad9eca9f84d5190c4bc8db75bd6970a3c Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Mon, 20 Oct 2025 15:35:14 +0000 Subject: [PATCH 48/96] Upload files to "/" --- Johannes-dev-dev.zip | Bin 0 -> 23564 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 Johannes-dev-dev.zip diff --git a/Johannes-dev-dev.zip b/Johannes-dev-dev.zip new file mode 100644 index 0000000000000000000000000000000000000000..65a47f0b8bf443b7c843d0312fa1e5196ce7eb55 GIT binary patch literal 23564 zcmeFYV{~QVwk;Z~V%xTD+qRPx+o;&KZQHh0vCT>_9d(M7m?{oJ1|5|&qwKdoJ zGiGbw?4yr9zHjuUC<6)x1N6TyXb4rE|MTNNZg4=*KvwpaMs{{)&UB_`ZVYOw;6T8O zp^uh|{}BWAe`0()jE|rofPezwfPgUmHHO{--~zC)vv)H4NA!$_jQtinV(+B}qC-II zs5Hn%sU%9iATm!)5GmVTC+bLGAthZ8>O|tN+7yFbdr3eItDQX8Lp?KBHb&Skug~aY z<41~~f}@3;<7lqDQtBYQJYc;sQww7`pTG2RWGby1ln-^YCJPLMr(=6%#PhgRAjI~Y zdbZC|g^U%U;Af?U?2b4fu#x;Hl_s%%Ibx61C=|6SH~mw$Mkzz(dWgAdXHAqkesODU zvM)h>5Nhv}W%Dr|REF-cfHvFt{k?+getR5Y2(9B@FMTWz72AT_*3U3{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e0ff7da2b295a Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Mon, 20 Oct 2025 15:39:58 +0000 Subject: [PATCH 49/96] afniawemhcfj8ewa hjciuawefn awenfuiearhi nofuahweof e2q --- Johannes-dev-dev.zip | Bin 23564 -> 0 bytes 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 Johannes-dev-dev.zip diff --git a/Johannes-dev-dev.zip b/Johannes-dev-dev.zip deleted file mode 100644 index 65a47f0b8bf443b7c843d0312fa1e5196ce7eb55..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 23564 zcmeFYV{~QVwk;Z~V%xTD+qRPx+o;&KZQHh0vCT>_9d(M7m?{oJ1|5|&qwKdoJ zGiGbw?4yr9zHjuUC<6)x1N6TyXb4rE|MTNNZg4=*KvwpaMs{{)&UB_`ZVYOw;6T8O zp^uh|{}BWAe`0()jE|rofPezwfPgUmHHO{--~zC)vv)H4NA!$_jQtinV(+B}qC-II zs5Hn%sU%9iATm!)5GmVTC+bLGAthZ8>O|tN+7yFbdr3eItDQX8Lp?KBHb&Skug~aY z<41~~f}@3;<7lqDQtBYQJYc;sQww7`pTG2RWGby1ln-^YCJPLMr(=6%#PhgRAjI~Y zdbZC|g^U%U;Af?U?2b4fu#x;Hl_s%%Ibx61C=|6SH~mw$Mkzz(dWgAdXHAqkesODU zvM)h>5Nhv}W%Dr|REF-cfHvFt{k?+getR5Y2(9B@FMTWz72AT_*3U3{ZZFAcU0GGekjdCi7}90LNDeHsMCbq*j~AMweo9pJy&DkI39Mie=5v$%Y=k*(up))@tH2FoId42|8>-*HIJUMt*Wl@A1KmA)BG*M46d z>5_Df9H_gWp1;pfQ+kd2A!_iW#g~FP`Qu%-nYKA9W(z zrGQN;=P7NPQK8KAE$~9I@-~(ul>Xes%-ZWxa)wJ{r`@S^O#Nt7@HzcWN*wFw{^~5* zrV!T#cXUq43U@Y&r2ACE4qLM^2{<(BAxE0(b5#Sg)h*JQf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8IN|X;NP~sZkJUXo;_E74+Cr3o58I-ODQRA7QEm1{(WaE zGTG^cH35}*8Qw7HMH6wwHIIp_?->^ou3e%^$nx$sxyuyRWJzN$e4r(AvG}?z5uiv}lY^Yl z?tT2ct;fT+*eSp1p_09zf*lHSH}gVw6F2@{RRLytp*WPRH|u@}!34?5;C|-(Ecf^7 z{j1`Q!DC8OJKMHKdbkIJ_T(O)2ivKGi{j|##Ezf87)SdPV9(FPKOd+(2baXb_qVR0 z$8-S2Ms!32_I^9$9MOUf_CUYUPVNK;gaUhvVWG}M04T8I7!U4oJeLE6 z0gql_VIQ~wus;uCU}1kM28Tlb(RKJNXLtdyWAy&tpD9rA#|FmCcLM7e-T!Y99(wxN z2n+t8{u1y1dv*W|I~piJZyy`t(uuH>EPf#S->UJUe~M-23IK2aSD-+}{BO)deHqJ) z6Z{+VH<=j-1&Xp*Xt3}}P@pyoWCEp1Ec3~^lb9zdmOwVp^TV>;!6&khv;Kf!pksyw z>xi8MKHfOPlK*_I4$YmT>+rSGmjsZH)}kklSfI&+jWP0g(%-!vY@q+i69KBSSUi)$ zv4Q@zMhm0^D_B_iMdcId$JeufU|=c_3r1?506r$M2c!a%W?1T7tz)UjrqF;?;7$Zf zjWRfvdg8tWNCvJav1C@`W6A$}b!ntW06N4l9DG&|YL9b}LxD{4yo0ouq@=wA*zvrK f7#JoaW)GHfa1xWW13Q4h5-@40^U`)w=k5LvB(nkI From b8476d4bfc6525dc6eb1f631b245cd5a5401b1ab Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Mon, 20 Oct 2025 15:43:35 +0000 Subject: [PATCH 50/96] Upload files to "missions" --- missions/Boat_mission.py | 27 +++++++++++++++++++++++++++ missions/HEAVY_LIFTING_UPD.py | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 60 insertions(+) create mode 100644 missions/Boat_mission.py create mode 100644 missions/HEAVY_LIFTING_UPD.py diff --git a/missions/Boat_mission.py b/missions/Boat_mission.py new file mode 100644 index 0000000..6d87949 --- /dev/null +++ b/missions/Boat_mission.py @@ -0,0 +1,27 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task,multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) + +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) + +drive_base.settings(880,850,700,700) + +drive_base.use_gyro(True) + +first_run = True + +async def main(): + await drive_base.straight(750) + await drive_base.straight(-650) + +run_task(main()) \ No newline at end of file diff --git a/missions/HEAVY_LIFTING_UPD.py b/missions/HEAVY_LIFTING_UPD.py new file mode 100644 index 0000000..da0f004 --- /dev/null +++ b/missions/HEAVY_LIFTING_UPD.py @@ -0,0 +1,33 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(536) + await drive_base.turn(60, Stop.HOLD) + await drive_base.straight(30) + + await right_arm.run_angle(5000,3000) + await drive_base.straight(40) + await right_arm.run_angle(5000,-4000) + await drive_base.straight(-60) + + await drive_base.turn(-60) + await drive_base.straight(-670) +run_task(main()) \ No newline at end of file From ce4435e7eb9740fc39d8520da18219414f29e6ae Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Mon, 20 Oct 2025 15:44:31 +0000 Subject: [PATCH 51/96] Changed line 23 from 420 to 500 johannes did it idk --- missions/Sand Mission.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/missions/Sand Mission.py b/missions/Sand Mission.py index 73e1e16..368ba5c 100644 --- a/missions/Sand Mission.py +++ b/missions/Sand Mission.py @@ -20,10 +20,10 @@ drive_base.use_gyro(True) async def main(): - await drive_base.straight(420) - await right_arm.run_angle(300,-100) + await drive_base.straight(500) + await right_arm.run_angle(300,100) await drive_base.straight(-100) - await right_arm.run_angle(300, 100) + await right_arm.run_angle(300,-100) await drive_base.straight(-350) run_task(main()) \ No newline at end of file From 50dd00cba6cf44de91cc11051f2b0ebbcb1e3077 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Mon, 20 Oct 2025 15:48:22 +0000 Subject: [PATCH 52/96] Changed Johannes values Old code was: from pybricks.hubs import PrimeHub from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor from pybricks.parameters import Button, Color, Direction, Port, Side, Stop from pybricks.robotics import DriveBase from pybricks.tools import wait, StopWatch from pybricks.tools import run_task, multitask hub = PrimeHub() left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) right_motor = Motor(Port.B) left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) right_arm = Motor(Port.D) drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) drive_base.settings(600,500,300,200) drive_base.use_gyro(True) async def main(): await drive_base.straight(915) await drive_base.turn(-90) await drive_base.straight(60) await left_arm.run_angle(10000,-15000) await drive_base.straight(-60) await drive_base.turn(85) await drive_base.straight(2000) run_task(main()) --- missions/Send_Over.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/missions/Send_Over.py b/missions/Send_Over.py index 97bed5f..61e2d37 100644 --- a/missions/Send_Over.py +++ b/missions/Send_Over.py @@ -23,9 +23,9 @@ async def main(): await drive_base.straight(915) await drive_base.turn(-90) await drive_base.straight(60) - await left_arm.run_angle(10000,-15000) - await drive_base.straight(-60) - await drive_base.turn(85) + await left_arm.run_angle(10000,-4000) + await drive_base.straight(-90) + await drive_base.turn(80) await drive_base.straight(2000) - + run_task(main()) \ No newline at end of file From b263687c3b3faeb1080fe8d9de09b6f68df1ee76 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Mon, 20 Oct 2025 16:13:13 +0000 Subject: [PATCH 53/96] dis id vewwy impotent codes AAAGGGHHHHHHHHHHHHH COLOR SENSORS CAUSE ME PAIN!!!!!!!!!!! --- test_10_17_2025.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test_10_17_2025.py b/test_10_17_2025.py index a9994ae..d36725d 100644 --- a/test_10_17_2025.py +++ b/test_10_17_2025.py @@ -1,3 +1,5 @@ +# Stuff from 10/15/2025 +# Atharv trying with no avail to add more colors to the color sensor logic ๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿ˜ญ from pybricks.hubs import PrimeHub from pybricks.pupdevices import Motor, ColorSensor from pybricks.parameters import Port, Stop, Color, Direction From 97963488eb4bc11b25cfa290295ff537b00bcef2 Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Tue, 21 Oct 2025 00:21:53 +0000 Subject: [PATCH 54/96] Update test_10_17_2025.py Rishi, A.K.A me replaced my outdated code with the new one. --- test_10_17_2025.py | 39 ++++++++++++++++++++------------------- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/test_10_17_2025.py b/test_10_17_2025.py index d36725d..1d89281 100644 --- a/test_10_17_2025.py +++ b/test_10_17_2025.py @@ -207,29 +207,30 @@ async def Run3(): async def Run4(): await drive_base.straight(519) - await left_arm.run_angle(300, -200) - await left_arm.run_angle(800, 1000) - await drive_base.straight(180) - await drive_base.turn(-37) - await right_arm.run_angle(300, -50) + await drive_base.straight(519) + await arm_motor_left.run_angle(-10000, 300) + await arm_motor_left.run_angle(10000, 600) + await drive_base.straight(160) + await drive_base.turn(-30) await drive_base.straight(50) - await right_arm.run_angle(300, -350) + await arm_motor.run_angle(3000, 3000) await drive_base.straight(-150) - await drive_base.turn(125) + await drive_base.turn(135) await drive_base.straight(50) - await right_arm.run_angle(300, 400) - await drive_base.straight(-75) - await right_arm.run_angle(300, -200) + await arm_motor.run_angle(10000, -3000) + await drive_base.straight(-100) + await drive_base.turn(-54) + await arm_motor.run_angle(10000, -3000) + await drive_base.straight(250) + await drive_base.turn(-5) + await arm_motor.run_angle(10000, 7000) + await drive_base.straight(-50) + await drive_base.turn(68) + await arm_motor.run_angle(10000, -6000) + await drive_base.straight(200) + await arm_motor.run_angle(10000, 4000) await drive_base.turn(-40) - await right_arm.run_angle(300, 250) - await drive_base.straight(260) - await right_arm.run_angle(100, -300) - await drive_base.straight(30) - await right_arm.run_angle(50,-250) - await drive_base.turn(30) - await drive_base.straight(-200) - await drive_base.turn(-67) - await drive_base.straight(-800) + await arm_motor.run_angle(10000, 7000) async def Run5(): await drive_base.straight(420) From 59213ae3f6d7fede36b6131ea866935d835ef68c Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Tue, 21 Oct 2025 00:24:33 +0000 Subject: [PATCH 55/96] Update final/main5.py Just adjusted my code!! --- final/main5.py | 36 +++++++++++++++++++----------------- 1 file changed, 19 insertions(+), 17 deletions(-) diff --git a/final/main5.py b/final/main5.py index 2b0fcd6..7461d72 100644 --- a/final/main5.py +++ b/final/main5.py @@ -203,27 +203,29 @@ async def Run3(): async def Run4(): await drive_base.straight(519) - await left_arm.run_angle(300, -100) - await left_arm.run_angle(300, 500) - await drive_base.straight(180) - await drive_base.turn(-37) + await arm_motor_left.run_angle(-10000, 300) + await arm_motor_left.run_angle(10000, 600) + await drive_base.straight(160) + await drive_base.turn(-30) await drive_base.straight(50) - await right_arm.run_angle(300, -400) + await arm_motor.run_angle(3000, 3000) await drive_base.straight(-150) - await drive_base.turn(125) + await drive_base.turn(135) await drive_base.straight(50) - await right_arm.run_angle(300, 400) - await drive_base.straight(-75) - await right_arm.run_angle(300, 300) - await drive_base.turn(-40) + await arm_motor.run_angle(10000, -3000) + await drive_base.straight(-100) + await drive_base.turn(-54) + await arm_motor.run_angle(10000, -3000) await drive_base.straight(250) - await right_arm.run_angle(100, -300) - await drive_base.straight(30) - await right_arm.run_angle(50,-250) - await drive_base.turn(30) - await drive_base.straight(-200) - await drive_base.turn(-50) - await drive_base.straight(-800) + await drive_base.turn(-5) + await arm_motor.run_angle(10000, 7000) + await drive_base.straight(-50) + await drive_base.turn(68) + await arm_motor.run_angle(10000, -6000) + await drive_base.straight(200) + await arm_motor.run_angle(10000, 4000) + await drive_base.turn(-40) + await arm_motor.run_angle(10000, 7000) async def Run5(): await drive_base.straight(420) From cb79ecbb956600d7294b4a106baaa6fb5e0b15f2 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Tue, 21 Oct 2025 23:54:55 +0000 Subject: [PATCH 56/96] Add missions/Heavy_lifting_final.py --- missions/Heavy_lifting_final.py | 35 +++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 missions/Heavy_lifting_final.py diff --git a/missions/Heavy_lifting_final.py b/missions/Heavy_lifting_final.py new file mode 100644 index 0000000..95c8889 --- /dev/null +++ b/missions/Heavy_lifting_final.py @@ -0,0 +1,35 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(525) + await drive_base.turn(60) + + await drive_base.straight(50) + await right_arm.run_angle(2000,1000) + await drive_base.straight(-50) + await drive_base.turn(45) + await drive_base.straight(50) + await right_arm.run_angle(350,-1000) + + await drive_base.straight(-100) + await drive_base.turn(-100) + await drive_base.straight(-600) +run_task(main()) \ No newline at end of file From 2567e8b8d75ac4725ec1c20cb1e42a07ca9a680c Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Tue, 21 Oct 2025 23:57:13 +0000 Subject: [PATCH 57/96] Add missions/Send_Over_Final.py --- missions/Send_Over_Final.py | 43 +++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 missions/Send_Over_Final.py diff --git a/missions/Send_Over_Final.py b/missions/Send_Over_Final.py new file mode 100644 index 0000000..7296ef4 --- /dev/null +++ b/missions/Send_Over_Final.py @@ -0,0 +1,43 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +lazer_ranger = UltrasonicSensor(Port.E) + +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) + +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + await drive_base.straight(920) + await drive_base.turn(-90,Stop.HOLD) + await drive_base.straight(65) + drive_base.turn(-10) + await left_arm.run_angle(10000,-4000) + await drive_base.straight(-110) + await drive_base.turn(90) + await drive_base.straight(500) + while True: + distance_mm = await lazer_ranger.distance() + print('distancing...',distance_mm) + + if distance_mm < 300: + drive_base.stop + break + else: + drive_base.straight(300) + print('running...') + await wait(10) + +run_task(main()) \ No newline at end of file From cf1f8a1995903d94325a75cee7777691f20593f6 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Wed, 22 Oct 2025 00:04:16 +0000 Subject: [PATCH 58/96] Update missions/Send_Over_Final.py --- missions/Send_Over_Final.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/missions/Send_Over_Final.py b/missions/Send_Over_Final.py index 7296ef4..db9a179 100644 --- a/missions/Send_Over_Final.py +++ b/missions/Send_Over_Final.py @@ -20,11 +20,14 @@ drive_base.settings(600,500,300,200) drive_base.use_gyro(True) async def main(): + #Get to mission await drive_base.straight(920) await drive_base.turn(-90,Stop.HOLD) await drive_base.straight(65) + #Solve mission drive_base.turn(-10) await left_arm.run_angle(10000,-4000) + #Get to Red Start await drive_base.straight(-110) await drive_base.turn(90) await drive_base.straight(500) From 6c9efe26f9da87dc9b409715b3dbe2561fa04ce1 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Wed, 22 Oct 2025 00:05:00 +0000 Subject: [PATCH 59/96] Update missions/Heavy_lifting_final.py --- missions/Heavy_lifting_final.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/missions/Heavy_lifting_final.py b/missions/Heavy_lifting_final.py index 95c8889..5a9dd1d 100644 --- a/missions/Heavy_lifting_final.py +++ b/missions/Heavy_lifting_final.py @@ -17,18 +17,19 @@ drive_base.settings(600,500,300,200) drive_base.use_gyro(True) async def main(): + #Get to mission await drive_base.straight(200) await drive_base.turn(-20) await drive_base.straight(525) await drive_base.turn(60) - + #Solve mission await drive_base.straight(50) await right_arm.run_angle(2000,1000) await drive_base.straight(-50) await drive_base.turn(45) await drive_base.straight(50) await right_arm.run_angle(350,-1000) - + #Return home await drive_base.straight(-100) await drive_base.turn(-100) await drive_base.straight(-600) From 3ec1aafbeb86a08628b692888e33aad29309474a Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Wed, 22 Oct 2025 00:07:04 +0000 Subject: [PATCH 60/96] Update missions/M8_5.py --- missions/M8_5.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/missions/M8_5.py b/missions/M8_5.py index cf05500..77a036b 100644 --- a/missions/M8_5.py +++ b/missions/M8_5.py @@ -19,31 +19,35 @@ drive_base.settings(600,500,300,200) drive_base.use_gyro(True) async def main(): + #Setup for mission left_arm.run_angle(1000, 300) right_arm.run_angle(1000,500) await drive_base.straight(320) - + # Solve "Silo" await right_arm.run_angle(5000,-500, Stop.HOLD) await right_arm.run_angle(5000,500, Stop.HOLD) await right_arm.run_angle(5000,-500, Stop.HOLD) await right_arm.run_angle(5000,500, Stop.HOLD) await right_arm.run_angle(5000,-500, Stop.HOLD) - + #Get to next mission await drive_base.turn(-20) await drive_base.straight(277) await drive_base.turn(20) await drive_base.straight(65) - + #Solve "Who Lived Here?" await drive_base.turn(-30) right_arm.run_angle(70,500) + #Get to next mission await drive_base.turn(45) - await drive_base.straight(-135) + await drive_base.straight(-145) await drive_base.turn(-60) await drive_base.straight(90) + #Solve "What's on Sale?" await left_arm.run_angle(1000,-450) await drive_base.straight(-145) await left_arm.run_angle(1000,450) await drive_base.straight(10) + #Return to home await drive_base.turn(35) await drive_base.straight(-600) run_task(main()) \ No newline at end of file From 4496396d0be5bea35ac860b21c75a011e4f66b1f Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Wed, 22 Oct 2025 00:15:11 +0000 Subject: [PATCH 61/96] Update missions/M8_5.py --- missions/M8_5.py | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/missions/M8_5.py b/missions/M8_5.py index 77a036b..95ecc9e 100644 --- a/missions/M8_5.py +++ b/missions/M8_5.py @@ -19,35 +19,31 @@ drive_base.settings(600,500,300,200) drive_base.use_gyro(True) async def main(): - #Setup for mission left_arm.run_angle(1000, 300) right_arm.run_angle(1000,500) await drive_base.straight(320) - # Solve "Silo" + await right_arm.run_angle(5000,-500, Stop.HOLD) await right_arm.run_angle(5000,500, Stop.HOLD) await right_arm.run_angle(5000,-500, Stop.HOLD) await right_arm.run_angle(5000,500, Stop.HOLD) await right_arm.run_angle(5000,-500, Stop.HOLD) - #Get to next mission + await drive_base.turn(-20) await drive_base.straight(277) await drive_base.turn(20) await drive_base.straight(65) - #Solve "Who Lived Here?" + await drive_base.turn(-30) - right_arm.run_angle(70,500) - #Get to next mission + right_arm.run_angle(50,500) await drive_base.turn(45) await drive_base.straight(-145) await drive_base.turn(-60) await drive_base.straight(90) - #Solve "What's on Sale?" await left_arm.run_angle(1000,-450) await drive_base.straight(-145) await left_arm.run_angle(1000,450) await drive_base.straight(10) - #Return to home await drive_base.turn(35) await drive_base.straight(-600) run_task(main()) \ No newline at end of file From d8f1d47882bef7116a7b040bc65884726964125b Mon Sep 17 00:00:00 2001 From: nifrali Date: Wed, 22 Oct 2025 12:37:05 -0500 Subject: [PATCH 62/96] Organize mission codes for scrimmage. Fixed some coolor detection issues --- .../hazmat/Heavy_lifting_final.py | 36 ++ codes_for_scrimmage/hazmat/M8_5.py | 49 +++ codes_for_scrimmage/hazmat/Send_Over_Final.py | 46 +++ codes_for_scrimmage/hazmat/hazmat_main.py | 361 ++++++++++++++++++ codes_for_scrimmage/hazmat/tip the scale.py | 42 ++ 5 files changed, 534 insertions(+) create mode 100644 codes_for_scrimmage/hazmat/Heavy_lifting_final.py create mode 100644 codes_for_scrimmage/hazmat/M8_5.py create mode 100644 codes_for_scrimmage/hazmat/Send_Over_Final.py create mode 100644 codes_for_scrimmage/hazmat/hazmat_main.py create mode 100644 codes_for_scrimmage/hazmat/tip the scale.py diff --git a/codes_for_scrimmage/hazmat/Heavy_lifting_final.py b/codes_for_scrimmage/hazmat/Heavy_lifting_final.py new file mode 100644 index 0000000..5a9dd1d --- /dev/null +++ b/codes_for_scrimmage/hazmat/Heavy_lifting_final.py @@ -0,0 +1,36 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + #Get to mission + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(525) + await drive_base.turn(60) + #Solve mission + await drive_base.straight(50) + await right_arm.run_angle(2000,1000) + await drive_base.straight(-50) + await drive_base.turn(45) + await drive_base.straight(50) + await right_arm.run_angle(350,-1000) + #Return home + await drive_base.straight(-100) + await drive_base.turn(-100) + await drive_base.straight(-600) +run_task(main()) \ No newline at end of file diff --git a/codes_for_scrimmage/hazmat/M8_5.py b/codes_for_scrimmage/hazmat/M8_5.py new file mode 100644 index 0000000..95ecc9e --- /dev/null +++ b/codes_for_scrimmage/hazmat/M8_5.py @@ -0,0 +1,49 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) + +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) + +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + left_arm.run_angle(1000, 300) + right_arm.run_angle(1000,500) + await drive_base.straight(320) + + await right_arm.run_angle(5000,-500, Stop.HOLD) + await right_arm.run_angle(5000,500, Stop.HOLD) + await right_arm.run_angle(5000,-500, Stop.HOLD) + await right_arm.run_angle(5000,500, Stop.HOLD) + await right_arm.run_angle(5000,-500, Stop.HOLD) + + await drive_base.turn(-20) + await drive_base.straight(277) + await drive_base.turn(20) + await drive_base.straight(65) + + await drive_base.turn(-30) + right_arm.run_angle(50,500) + await drive_base.turn(45) + await drive_base.straight(-145) + await drive_base.turn(-60) + await drive_base.straight(90) + await left_arm.run_angle(1000,-450) + await drive_base.straight(-145) + await left_arm.run_angle(1000,450) + await drive_base.straight(10) + await drive_base.turn(35) + await drive_base.straight(-600) +run_task(main()) \ No newline at end of file diff --git a/codes_for_scrimmage/hazmat/Send_Over_Final.py b/codes_for_scrimmage/hazmat/Send_Over_Final.py new file mode 100644 index 0000000..db9a179 --- /dev/null +++ b/codes_for_scrimmage/hazmat/Send_Over_Final.py @@ -0,0 +1,46 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) +lazer_ranger = UltrasonicSensor(Port.E) + +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) + +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +async def main(): + #Get to mission + await drive_base.straight(920) + await drive_base.turn(-90,Stop.HOLD) + await drive_base.straight(65) + #Solve mission + drive_base.turn(-10) + await left_arm.run_angle(10000,-4000) + #Get to Red Start + await drive_base.straight(-110) + await drive_base.turn(90) + await drive_base.straight(500) + while True: + distance_mm = await lazer_ranger.distance() + print('distancing...',distance_mm) + + if distance_mm < 300: + drive_base.stop + break + else: + drive_base.straight(300) + print('running...') + await wait(10) + +run_task(main()) \ No newline at end of file diff --git a/codes_for_scrimmage/hazmat/hazmat_main.py b/codes_for_scrimmage/hazmat/hazmat_main.py new file mode 100644 index 0000000..e55bd2e --- /dev/null +++ b/codes_for_scrimmage/hazmat/hazmat_main.py @@ -0,0 +1,361 @@ +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.tools import run_task, multitask +from pybricks.tools import wait, StopWatch +from pybricks.robotics import DriveBase +from pybricks.hubs import PrimeHub + +# Initialize hub and devices +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C) +right_arm = Motor(Port.D) +lazer_ranger = UltrasonicSensor(Port.E) +color_sensor = ColorSensor(Port.F) + +# DriveBase configuration +WHEEL_DIAMETER = 68.8 # mm (adjust for your wheels) +AXLE_TRACK = 180 # mm (distance between wheels) +drive_base = DriveBase(left_motor, right_motor, WHEEL_DIAMETER, AXLE_TRACK) +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +# Color Settings +# https://docs.pybricks.com/en/latest/parameters/color.html +print("Default Detected Colors:", color_sensor.detectable_colors()) + +# Custom color Hue, Saturation, Brightness value for Lego bricks +Color.MAGENTA = Color(300,100,100) +Color.VIOLET = Color(270,100,100) +Color.ORANGE = Color(17,78,15) +Color.BLUE = Color(240,100,100) +Color.CYAN = Color(180,100,100) + +LEGO_BRICKS_COLOR = [ + Color.ORANGE, + Color.BLUE, + Color.GREEN, + Color.WHITE, + Color.RED, + Color.YELLOW, + Color.MAGENTA, + Color.VIOLET, + Color.NONE +] +#Update Detectable colors +color_sensor.detectable_colors(LEGO_BRICKS_COLOR) + +print("Updated Detected Colors:", color_sensor.detectable_colors()) + +hub.speaker.volume(50) # Set the volume of the speaker + +# Celebration sound types +class CelebrationSound: + VICTORY_FANFARE = 0 + LEVEL_UP = 1 + SUCCESS_CHIME = 2 + TA_DA = 3 + POWER_UP = 4 + RICKROLL_INSPIRED = 5 + +async def play_victory_fanfare(): + """Classic victory fanfare""" + notes = [ + (262, 200), # C4 + (262, 200), # C4 + (262, 200), # C4 + (349, 600), # F4 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(50) +async def play_level_up(): + """Upward scale for level completion""" + notesold = [ + (262, 100), # C4 + (294, 100), # D4 + (330, 100), # E4 + (349, 100), # F4 + (392, 100), # G4 + (440, 100), # A4 + (494, 100), # B4 + (523, 300), # C5 + ] + notes = [ + (277, 100), + (330, 100), + (277, 100), + (554, 100), + (277, 100), + (413, 100), + (330, 100), + (277, 100), + (413, 100), + (277, 100), + (554, 100), + (413, 100), + (277, 100), + (413, 100), + (554, 100), + (413, 100) + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + #await wait(20) +async def play_success_chime(): + """Simple success notification""" + notes = [ + (523, 150), # C5 + (659, 150), # E5 + (784, 300), # G5 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(50) +async def play_ta_da(): + """Classic "ta-da!" sound""" + notes = [ + (392, 200), # G4 + (523, 400), # C5 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(100) +async def play_power_up(): + """Rising power-up sound""" + for freq in range(200, 800, 50): + await hub.speaker.beep(freq, 50) + await wait(10) + await hub.speaker.beep(1000, 200) +async def play_rickroll_inspired(): + """Fun 80s-style dance beat inspired sound""" + # Upbeat bouncy rhythm + pattern = [ + (392, 200), (440, 200), (494, 200), (523, 200), + (440, 200), (392, 200), (349, 200), (392, 300), + (440, 200), (392, 200), (349, 200), (330, 400), + ] + + for freq, duration in pattern: + await hub.speaker.beep(freq, duration) + await wait(50) +async def celebrate_mission_complete(sound_type=CelebrationSound.SUCCESS_CHIME): + """ + Main celebration function to call after completing a mission. + Plays a sound and shows light animation. + + Args: + sound_type: CelebrationSound enum value (default: SUCCESS_CHIME) + """ + # Light show + hub.light.on(Color.GREEN) + + # Play the selected celebration sound + if sound_type == CelebrationSound.VICTORY_FANFARE: + await play_victory_fanfare() + elif sound_type == CelebrationSound.LEVEL_UP: + await play_level_up() + elif sound_type == CelebrationSound.SUCCESS_CHIME: + await play_success_chime() + elif sound_type == CelebrationSound.TA_DA: + await play_ta_da() + elif sound_type == CelebrationSound.POWER_UP: + await play_power_up() + elif sound_type == CelebrationSound.RICKROLL_INSPIRED: + await play_rickroll_inspired() + else: + await play_success_chime() # Default fallback + + # Blink the light + for _ in range(3): + hub.light.off() + await wait(100) + hub.light.on(Color.GREEN) + await wait(100) + + hub.light.off() + +WALL_DISTANCE = 200 # mm +async def drive_forward(): + """Drive forward continuously using DriveBase.""" + #await drive_base.straight(5000) + drive_base.drive(400,0) +async def monitor_distance(): + """Monitor ultrasonic sensor and stop when wall is detected.""" + while True: + distance = await lazer_ranger.distance() + + if distance < WALL_DISTANCE: + # Stop the drivebase + await drive_base.turn(-180) + drive_base.brake + print(f"Wall detected at {distance}mm!") + break + + # Small delay to prevent overwhelming the sensor + await wait(50) + +async def Run1(): #From M8_5.py + left_arm.run_angle(1000, 300) + right_arm.run_angle(1000,500) + await drive_base.straight(320) + + await right_arm.run_angle(5000,-500, Stop.HOLD) + await right_arm.run_angle(5000,500, Stop.HOLD) + await right_arm.run_angle(5000,-500, Stop.HOLD) + await right_arm.run_angle(5000,500, Stop.HOLD) + await right_arm.run_angle(5000,-500, Stop.HOLD) + + await drive_base.turn(-20) + await drive_base.straight(277) + await drive_base.turn(20) + await drive_base.straight(65) + + await drive_base.turn(-30) + right_arm.run_angle(50,500) + await drive_base.turn(45) + await drive_base.straight(-145) + await drive_base.turn(-60) + await drive_base.straight(90) + await left_arm.run_angle(1000,-450) + await drive_base.straight(-145) + await left_arm.run_angle(1000,450) + await drive_base.straight(10) + await drive_base.turn(35) + await drive_base.straight(-600) + +async def Run2(): #From Heavy_lifting_final.py + #Get to mission + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(525) + await drive_base.turn(60) + #Solve mission + await drive_base.straight(50) + await right_arm.run_angle(2000,1000) + await drive_base.straight(-50) + await drive_base.turn(45) + await drive_base.straight(50) + await right_arm.run_angle(350,-1000) + #Return home + await drive_base.straight(-100) + await drive_base.turn(-100) + await drive_base.straight(-600) + + +async def Run3(): #tip the scale.py + drive_base.settings(300,1000,300,200) #Custom drive_base setting based on Ayaan's code + + left_arm.run_angle(500,200) + right_arm.run_angle(500,200) + await drive_base.straight(70) + + await drive_base.turn(-55) + await drive_base.straight(900) + await drive_base.turn(92.5) + + await drive_base.straight(75) + await drive_base.straight(21) + await right_arm.run_angle(500,-250) + await right_arm.run_angle(500,250) + await drive_base.turn(55) + + await left_arm.run_angle(300,-400) + + await drive_base.turn(46.5) + await drive_base.turn(-40) + await drive_base.straight(900) + + drive_base.settings(600,500,300,200) #Reset it to the initial values + +async def Run4(): #From Send_Over_Final.py + + #Get to mission + await drive_base.straight(920) + await drive_base.turn(-90,Stop.HOLD) + await drive_base.straight(65) + #Solve mission + drive_base.turn(-10) + await left_arm.run_angle(10000,-4000) + #Get to Red Start + await drive_base.straight(-110) + await drive_base.turn(90) + await drive_base.straight(500) + + # while True: + # distance_mm = await lazer_ranger.distance() + # print('distancing...',distance_mm) + + # if distance_mm < 300: + # drive_base.stop + # break + # else: + # drive_base.straight(300) + # print('running...') + # await wait(10) + await multitask( + drive_forward(), + monitor_distance() + ) + +#Add Rishi's code here +async def Run5(): + pass + +#Add - Adi's code here +async def Run6(): + pass + +async def main(): + while True: + + #await celebrate_mission_complete(CelebrationSound.LEVEL_UP) + color_reflected_percent = await color_sensor.reflection() + print(color_reflected_percent) + + + if color_reflected_percent > 5: # Make sure we actually have color reflections before checking for color + color_detected = await color_sensor.color() # Moved this inside the if clause + print(f'Detected color:{color_detected} : {color_detected.h}, {color_detected.s}, {color_detected.v}') + + if color_detected == Color.GREEN: + print('Running Mission 1') + await Run1() + #await celebrate_mission_complete(CelebrationSound.VICTORY_FANFARE) + elif color_detected == Color.WHITE: + print('Running Mission 2') + await Run2() + #await celebrate_mission_complete(CelebrationSound.RICKROLL_INSPIRED) + elif color_detected == Color.RED: + print('Running Mission 3') + await Run3() + #await celebrate_mission_complete(CelebrationSound.SUCCESS_CHIME ) + elif color_detected == Color.YELLOW: + print('Running Mission 4') + await Run4() + #await celebrate_mission_complete(CelebrationSound.POWER_UP) + elif color_detected == Color.BLUE: + print('Running Mission 5') + await Run5() + #await celebrate_mission_complete(CelebrationSound.LEVEL_UP) + elif color_detected == Color.ORANGE: + print('Running Mission 6') + await Run6() + else: + hub.light.off() + left_motor.stop() + right_motor.stop() + color_detected = Color.NONE + else: + color_detected = Color.NONE + + await wait(1000) #prevent loop from iterating fast +# Main execution loop +run_task(main()) diff --git a/codes_for_scrimmage/hazmat/tip the scale.py b/codes_for_scrimmage/hazmat/tip the scale.py new file mode 100644 index 0000000..200b1ea --- /dev/null +++ b/codes_for_scrimmage/hazmat/tip the scale.py @@ -0,0 +1,42 @@ +from pybricks.hubs import PrimeHub +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.robotics import DriveBase +from pybricks.tools import wait, StopWatch +from pybricks.tools import run_task, multitask + +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + + +left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) +right_arm = Motor(Port.D) + +drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) +drive_base.settings(300,1000,300,200) + +#drive_base.use_gyro(True) + +async def main(): + left_arm.run_angle(500,200) + right_arm.run_angle(500,200) + await drive_base.straight(70) + + await drive_base.turn(-55) + await drive_base.straight(900) + await drive_base.turn(92.5) + + await drive_base.straight(75) + await drive_base.straight(21) + await right_arm.run_angle(500,-250) + await right_arm.run_angle(500,250) + await drive_base.turn(55) + + await left_arm.run_angle(300,-400) + + await drive_base.turn(46.5) + await drive_base.turn(-40) + await drive_base.straight(900) +run_task(main()) \ No newline at end of file From 1f2a467b9b646e8f21f66fb74d35733d0cf7487a Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Thu, 23 Oct 2025 00:28:52 +0000 Subject: [PATCH 63/96] Update codes_for_scrimmage/hazmat/Heavy_lifting_final.py --- .../hazmat/Heavy_lifting_final.py | 27 +++++++++---------- 1 file changed, 12 insertions(+), 15 deletions(-) diff --git a/codes_for_scrimmage/hazmat/Heavy_lifting_final.py b/codes_for_scrimmage/hazmat/Heavy_lifting_final.py index 5a9dd1d..86a67e9 100644 --- a/codes_for_scrimmage/hazmat/Heavy_lifting_final.py +++ b/codes_for_scrimmage/hazmat/Heavy_lifting_final.py @@ -17,20 +17,17 @@ drive_base.settings(600,500,300,200) drive_base.use_gyro(True) async def main(): - #Get to mission - await drive_base.straight(200) + #await drive_base.straight(200) await drive_base.turn(-20) - await drive_base.straight(525) - await drive_base.turn(60) - #Solve mission - await drive_base.straight(50) - await right_arm.run_angle(2000,1000) - await drive_base.straight(-50) - await drive_base.turn(45) - await drive_base.straight(50) - await right_arm.run_angle(350,-1000) - #Return home - await drive_base.straight(-100) - await drive_base.turn(-100) - await drive_base.straight(-600) + await drive_base.straight(536) + await drive_base.turn(60, Stop.HOLD) + await drive_base.straight(30) + + await right_arm.run_angle(5000,2900) + await drive_base.straight(40) + await right_arm.run_angle(5000,-4000) + await drive_base.straight(-60) + + await drive_base.turn(-60) + await drive_base.straight(-670) run_task(main()) \ No newline at end of file From 68aff887da32f3ec2c6aed3a3495fd394e928910 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Thu, 23 Oct 2025 00:29:22 +0000 Subject: [PATCH 64/96] Update codes_for_scrimmage/hazmat/hazmat_main.py --- codes_for_scrimmage/hazmat/hazmat_main.py | 25 ++++++++++------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/codes_for_scrimmage/hazmat/hazmat_main.py b/codes_for_scrimmage/hazmat/hazmat_main.py index e55bd2e..f40fe31 100644 --- a/codes_for_scrimmage/hazmat/hazmat_main.py +++ b/codes_for_scrimmage/hazmat/hazmat_main.py @@ -232,22 +232,19 @@ async def Run1(): #From M8_5.py await drive_base.straight(-600) async def Run2(): #From Heavy_lifting_final.py - #Get to mission await drive_base.straight(200) await drive_base.turn(-20) - await drive_base.straight(525) - await drive_base.turn(60) - #Solve mission - await drive_base.straight(50) - await right_arm.run_angle(2000,1000) - await drive_base.straight(-50) - await drive_base.turn(45) - await drive_base.straight(50) - await right_arm.run_angle(350,-1000) - #Return home - await drive_base.straight(-100) - await drive_base.turn(-100) - await drive_base.straight(-600) + await drive_base.straight(536) + await drive_base.turn(60, Stop.HOLD) + await drive_base.straight(30) + + await right_arm.run_angle(5000,2900) + await drive_base.straight(40) + await right_arm.run_angle(5000,-4000) + await drive_base.straight(-60) + + await drive_base.turn(-60) + await drive_base.straight(-670) async def Run3(): #tip the scale.py From 1cb08a0c32b39004ca6c0b059f17842816e7444f Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Thu, 23 Oct 2025 00:34:14 +0000 Subject: [PATCH 65/96] Update codes_for_scrimmage/hazmat/hazmat_main.py Adding Rishi/Vickram + Adi Mission's --- codes_for_scrimmage/hazmat/hazmat_main.py | 57 +++++++++++++++++------ 1 file changed, 44 insertions(+), 13 deletions(-) diff --git a/codes_for_scrimmage/hazmat/hazmat_main.py b/codes_for_scrimmage/hazmat/hazmat_main.py index f40fe31..0bb9103 100644 --- a/codes_for_scrimmage/hazmat/hazmat_main.py +++ b/codes_for_scrimmage/hazmat/hazmat_main.py @@ -232,19 +232,22 @@ async def Run1(): #From M8_5.py await drive_base.straight(-600) async def Run2(): #From Heavy_lifting_final.py + #Get to mission await drive_base.straight(200) await drive_base.turn(-20) - await drive_base.straight(536) - await drive_base.turn(60, Stop.HOLD) - await drive_base.straight(30) - - await right_arm.run_angle(5000,2900) - await drive_base.straight(40) - await right_arm.run_angle(5000,-4000) - await drive_base.straight(-60) - - await drive_base.turn(-60) - await drive_base.straight(-670) + await drive_base.straight(525) + await drive_base.turn(60) + #Solve mission + await drive_base.straight(50) + await right_arm.run_angle(2000,1000) + await drive_base.straight(-50) + await drive_base.turn(45) + await drive_base.straight(50) + await right_arm.run_angle(350,-1000) + #Return home + await drive_base.straight(-100) + await drive_base.turn(-100) + await drive_base.straight(-600) async def Run3(): #tip the scale.py @@ -304,11 +307,39 @@ async def Run4(): #From Send_Over_Final.py #Add Rishi's code here async def Run5(): - pass + await drive_base.straight(519) + await left_arm.run_angle(-10000, 300) + await left_arm.run_angle(10000, 600) + await drive_base.straight(160) + await drive_base.turn(-30) + await drive_base.straight(50) + await right_arm.run_angle(3000, 3000) + await drive_base.straight(-150) + await drive_base.turn(135) + await drive_base.straight(25) + await right_arm.run_angle(10000, -3000) + await drive_base.straight(-100) + await drive_base.turn(-55) + await right_arm.run_angle(10000, -3000) + await drive_base.straight(250) + await drive_base.turn(-5) + await right_arm.run_angle(10000, 7000) + await drive_base.straight(-50) + await drive_base.turn(45) + await drive_base.straight(100) + await drive_base.turn(37) + await right_arm.run_angle(10000, -6000) + await drive_base.straight(90) + await right_arm.run_angle(3000, 3000) + await drive_base.turn(-40) #Add - Adi's code here async def Run6(): - pass + await drive_base.straight(420) + await right_arm.run_angle(300,-100) + await drive_base.straight(-100) + await right_arm.run_angle(300, 100) + await drive_base.straight(-350) async def main(): while True: From a16d5deb926ea527d50e4051b302fba486ea7202 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Thu, 23 Oct 2025 00:35:38 +0000 Subject: [PATCH 66/96] Update codes_for_scrimmage/hazmat/hazmat_main.py --- codes_for_scrimmage/hazmat/hazmat_main.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/codes_for_scrimmage/hazmat/hazmat_main.py b/codes_for_scrimmage/hazmat/hazmat_main.py index 0bb9103..d314b77 100644 --- a/codes_for_scrimmage/hazmat/hazmat_main.py +++ b/codes_for_scrimmage/hazmat/hazmat_main.py @@ -29,13 +29,11 @@ print("Default Detected Colors:", color_sensor.detectable_colors()) # Custom color Hue, Saturation, Brightness value for Lego bricks Color.MAGENTA = Color(300,100,100) -Color.VIOLET = Color(270,100,100) -Color.ORANGE = Color(17,78,15) +Color.VIOLET = Color(277,68,32) Color.BLUE = Color(240,100,100) Color.CYAN = Color(180,100,100) LEGO_BRICKS_COLOR = [ - Color.ORANGE, Color.BLUE, Color.GREEN, Color.WHITE, @@ -349,7 +347,7 @@ async def main(): print(color_reflected_percent) - if color_reflected_percent > 5: # Make sure we actually have color reflections before checking for color + if color_reflected_percent > 0: # Make sure we actually have color reflections before checking for color color_detected = await color_sensor.color() # Moved this inside the if clause print(f'Detected color:{color_detected} : {color_detected.h}, {color_detected.s}, {color_detected.v}') @@ -373,7 +371,7 @@ async def main(): print('Running Mission 5') await Run5() #await celebrate_mission_complete(CelebrationSound.LEVEL_UP) - elif color_detected == Color.ORANGE: + elif color_detected == Color.VIOLET: print('Running Mission 6') await Run6() else: From 819b22261051db963f9aa00202b0333c8424bc9f Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Thu, 23 Oct 2025 00:38:23 +0000 Subject: [PATCH 67/96] Update codes_for_scrimmage/hazmat/hazmat_main.py --- codes_for_scrimmage/hazmat/hazmat_main.py | 27 ++++++++++------------- 1 file changed, 12 insertions(+), 15 deletions(-) diff --git a/codes_for_scrimmage/hazmat/hazmat_main.py b/codes_for_scrimmage/hazmat/hazmat_main.py index d314b77..eb1542c 100644 --- a/codes_for_scrimmage/hazmat/hazmat_main.py +++ b/codes_for_scrimmage/hazmat/hazmat_main.py @@ -230,22 +230,19 @@ async def Run1(): #From M8_5.py await drive_base.straight(-600) async def Run2(): #From Heavy_lifting_final.py - #Get to mission - await drive_base.straight(200) + await drive_base.straight(200) await drive_base.turn(-20) - await drive_base.straight(525) - await drive_base.turn(60) - #Solve mission - await drive_base.straight(50) - await right_arm.run_angle(2000,1000) - await drive_base.straight(-50) - await drive_base.turn(45) - await drive_base.straight(50) - await right_arm.run_angle(350,-1000) - #Return home - await drive_base.straight(-100) - await drive_base.turn(-100) - await drive_base.straight(-600) + await drive_base.straight(536) + await drive_base.turn(60, Stop.HOLD) + await drive_base.straight(30) + + await right_arm.run_angle(5000,2900) + await drive_base.straight(40) + await right_arm.run_angle(5000,-4000) + await drive_base.straight(-60) + + await drive_base.turn(-60) + await drive_base.straight(-670) async def Run3(): #tip the scale.py From 9e0c82b26b76e71b12905b52881d7de2bc3a8d6f Mon Sep 17 00:00:00 2001 From: Ayaan <32agarwa@elmbrookstudents.org> Date: Thu, 23 Oct 2025 00:52:26 +0000 Subject: [PATCH 68/96] Update missions/tip the scale.py --- missions/tip the scale.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/missions/tip the scale.py b/missions/tip the scale.py index 200b1ea..4573352 100644 --- a/missions/tip the scale.py +++ b/missions/tip the scale.py @@ -39,4 +39,7 @@ async def main(): await drive_base.turn(46.5) await drive_base.turn(-40) await drive_base.straight(900) -run_task(main()) \ No newline at end of file +run_task(main()) + + + From 4ad60502b97074ee5c56cb9a8af00dadf236b0f8 Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Thu, 23 Oct 2025 02:14:42 +0000 Subject: [PATCH 69/96] Add codes_for_scrimmage/hazmat/mainhazmatUPD.py --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 384 ++++++++++++++++++++ 1 file changed, 384 insertions(+) create mode 100644 codes_for_scrimmage/hazmat/mainhazmatUPD.py diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py new file mode 100644 index 0000000..eb1542c --- /dev/null +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -0,0 +1,384 @@ +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.tools import run_task, multitask +from pybricks.tools import wait, StopWatch +from pybricks.robotics import DriveBase +from pybricks.hubs import PrimeHub + +# Initialize hub and devices +hub = PrimeHub() + +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) + +left_arm = Motor(Port.C) +right_arm = Motor(Port.D) +lazer_ranger = UltrasonicSensor(Port.E) +color_sensor = ColorSensor(Port.F) + +# DriveBase configuration +WHEEL_DIAMETER = 68.8 # mm (adjust for your wheels) +AXLE_TRACK = 180 # mm (distance between wheels) +drive_base = DriveBase(left_motor, right_motor, WHEEL_DIAMETER, AXLE_TRACK) +drive_base.settings(600,500,300,200) +drive_base.use_gyro(True) + +# Color Settings +# https://docs.pybricks.com/en/latest/parameters/color.html +print("Default Detected Colors:", color_sensor.detectable_colors()) + +# Custom color Hue, Saturation, Brightness value for Lego bricks +Color.MAGENTA = Color(300,100,100) +Color.VIOLET = Color(277,68,32) +Color.BLUE = Color(240,100,100) +Color.CYAN = Color(180,100,100) + +LEGO_BRICKS_COLOR = [ + Color.BLUE, + Color.GREEN, + Color.WHITE, + Color.RED, + Color.YELLOW, + Color.MAGENTA, + Color.VIOLET, + Color.NONE +] +#Update Detectable colors +color_sensor.detectable_colors(LEGO_BRICKS_COLOR) + +print("Updated Detected Colors:", color_sensor.detectable_colors()) + +hub.speaker.volume(50) # Set the volume of the speaker + +# Celebration sound types +class CelebrationSound: + VICTORY_FANFARE = 0 + LEVEL_UP = 1 + SUCCESS_CHIME = 2 + TA_DA = 3 + POWER_UP = 4 + RICKROLL_INSPIRED = 5 + +async def play_victory_fanfare(): + """Classic victory fanfare""" + notes = [ + (262, 200), # C4 + (262, 200), # C4 + (262, 200), # C4 + (349, 600), # F4 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(50) +async def play_level_up(): + """Upward scale for level completion""" + notesold = [ + (262, 100), # C4 + (294, 100), # D4 + (330, 100), # E4 + (349, 100), # F4 + (392, 100), # G4 + (440, 100), # A4 + (494, 100), # B4 + (523, 300), # C5 + ] + notes = [ + (277, 100), + (330, 100), + (277, 100), + (554, 100), + (277, 100), + (413, 100), + (330, 100), + (277, 100), + (413, 100), + (277, 100), + (554, 100), + (413, 100), + (277, 100), + (413, 100), + (554, 100), + (413, 100) + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + #await wait(20) +async def play_success_chime(): + """Simple success notification""" + notes = [ + (523, 150), # C5 + (659, 150), # E5 + (784, 300), # G5 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(50) +async def play_ta_da(): + """Classic "ta-da!" sound""" + notes = [ + (392, 200), # G4 + (523, 400), # C5 + ] + + for freq, duration in notes: + await hub.speaker.beep(freq, duration) + await wait(100) +async def play_power_up(): + """Rising power-up sound""" + for freq in range(200, 800, 50): + await hub.speaker.beep(freq, 50) + await wait(10) + await hub.speaker.beep(1000, 200) +async def play_rickroll_inspired(): + """Fun 80s-style dance beat inspired sound""" + # Upbeat bouncy rhythm + pattern = [ + (392, 200), (440, 200), (494, 200), (523, 200), + (440, 200), (392, 200), (349, 200), (392, 300), + (440, 200), (392, 200), (349, 200), (330, 400), + ] + + for freq, duration in pattern: + await hub.speaker.beep(freq, duration) + await wait(50) +async def celebrate_mission_complete(sound_type=CelebrationSound.SUCCESS_CHIME): + """ + Main celebration function to call after completing a mission. + Plays a sound and shows light animation. + + Args: + sound_type: CelebrationSound enum value (default: SUCCESS_CHIME) + """ + # Light show + hub.light.on(Color.GREEN) + + # Play the selected celebration sound + if sound_type == CelebrationSound.VICTORY_FANFARE: + await play_victory_fanfare() + elif sound_type == CelebrationSound.LEVEL_UP: + await play_level_up() + elif sound_type == CelebrationSound.SUCCESS_CHIME: + await play_success_chime() + elif sound_type == CelebrationSound.TA_DA: + await play_ta_da() + elif sound_type == CelebrationSound.POWER_UP: + await play_power_up() + elif sound_type == CelebrationSound.RICKROLL_INSPIRED: + await play_rickroll_inspired() + else: + await play_success_chime() # Default fallback + + # Blink the light + for _ in range(3): + hub.light.off() + await wait(100) + hub.light.on(Color.GREEN) + await wait(100) + + hub.light.off() + +WALL_DISTANCE = 200 # mm +async def drive_forward(): + """Drive forward continuously using DriveBase.""" + #await drive_base.straight(5000) + drive_base.drive(400,0) +async def monitor_distance(): + """Monitor ultrasonic sensor and stop when wall is detected.""" + while True: + distance = await lazer_ranger.distance() + + if distance < WALL_DISTANCE: + # Stop the drivebase + await drive_base.turn(-180) + drive_base.brake + print(f"Wall detected at {distance}mm!") + break + + # Small delay to prevent overwhelming the sensor + await wait(50) + +async def Run1(): #From M8_5.py + left_arm.run_angle(1000, 300) + right_arm.run_angle(1000,500) + await drive_base.straight(320) + + await right_arm.run_angle(5000,-500, Stop.HOLD) + await right_arm.run_angle(5000,500, Stop.HOLD) + await right_arm.run_angle(5000,-500, Stop.HOLD) + await right_arm.run_angle(5000,500, Stop.HOLD) + await right_arm.run_angle(5000,-500, Stop.HOLD) + + await drive_base.turn(-20) + await drive_base.straight(277) + await drive_base.turn(20) + await drive_base.straight(65) + + await drive_base.turn(-30) + right_arm.run_angle(50,500) + await drive_base.turn(45) + await drive_base.straight(-145) + await drive_base.turn(-60) + await drive_base.straight(90) + await left_arm.run_angle(1000,-450) + await drive_base.straight(-145) + await left_arm.run_angle(1000,450) + await drive_base.straight(10) + await drive_base.turn(35) + await drive_base.straight(-600) + +async def Run2(): #From Heavy_lifting_final.py + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(536) + await drive_base.turn(60, Stop.HOLD) + await drive_base.straight(30) + + await right_arm.run_angle(5000,2900) + await drive_base.straight(40) + await right_arm.run_angle(5000,-4000) + await drive_base.straight(-60) + + await drive_base.turn(-60) + await drive_base.straight(-670) + + +async def Run3(): #tip the scale.py + drive_base.settings(300,1000,300,200) #Custom drive_base setting based on Ayaan's code + + left_arm.run_angle(500,200) + right_arm.run_angle(500,200) + await drive_base.straight(70) + + await drive_base.turn(-55) + await drive_base.straight(900) + await drive_base.turn(92.5) + + await drive_base.straight(75) + await drive_base.straight(21) + await right_arm.run_angle(500,-250) + await right_arm.run_angle(500,250) + await drive_base.turn(55) + + await left_arm.run_angle(300,-400) + + await drive_base.turn(46.5) + await drive_base.turn(-40) + await drive_base.straight(900) + + drive_base.settings(600,500,300,200) #Reset it to the initial values + +async def Run4(): #From Send_Over_Final.py + + #Get to mission + await drive_base.straight(920) + await drive_base.turn(-90,Stop.HOLD) + await drive_base.straight(65) + #Solve mission + drive_base.turn(-10) + await left_arm.run_angle(10000,-4000) + #Get to Red Start + await drive_base.straight(-110) + await drive_base.turn(90) + await drive_base.straight(500) + + # while True: + # distance_mm = await lazer_ranger.distance() + # print('distancing...',distance_mm) + + # if distance_mm < 300: + # drive_base.stop + # break + # else: + # drive_base.straight(300) + # print('running...') + # await wait(10) + await multitask( + drive_forward(), + monitor_distance() + ) + +#Add Rishi's code here +async def Run5(): + await drive_base.straight(519) + await left_arm.run_angle(-10000, 300) + await left_arm.run_angle(10000, 600) + await drive_base.straight(160) + await drive_base.turn(-30) + await drive_base.straight(50) + await right_arm.run_angle(3000, 3000) + await drive_base.straight(-150) + await drive_base.turn(135) + await drive_base.straight(25) + await right_arm.run_angle(10000, -3000) + await drive_base.straight(-100) + await drive_base.turn(-55) + await right_arm.run_angle(10000, -3000) + await drive_base.straight(250) + await drive_base.turn(-5) + await right_arm.run_angle(10000, 7000) + await drive_base.straight(-50) + await drive_base.turn(45) + await drive_base.straight(100) + await drive_base.turn(37) + await right_arm.run_angle(10000, -6000) + await drive_base.straight(90) + await right_arm.run_angle(3000, 3000) + await drive_base.turn(-40) + +#Add - Adi's code here +async def Run6(): + await drive_base.straight(420) + await right_arm.run_angle(300,-100) + await drive_base.straight(-100) + await right_arm.run_angle(300, 100) + await drive_base.straight(-350) + +async def main(): + while True: + + #await celebrate_mission_complete(CelebrationSound.LEVEL_UP) + color_reflected_percent = await color_sensor.reflection() + print(color_reflected_percent) + + + if color_reflected_percent > 0: # Make sure we actually have color reflections before checking for color + color_detected = await color_sensor.color() # Moved this inside the if clause + print(f'Detected color:{color_detected} : {color_detected.h}, {color_detected.s}, {color_detected.v}') + + if color_detected == Color.GREEN: + print('Running Mission 1') + await Run1() + #await celebrate_mission_complete(CelebrationSound.VICTORY_FANFARE) + elif color_detected == Color.WHITE: + print('Running Mission 2') + await Run2() + #await celebrate_mission_complete(CelebrationSound.RICKROLL_INSPIRED) + elif color_detected == Color.RED: + print('Running Mission 3') + await Run3() + #await celebrate_mission_complete(CelebrationSound.SUCCESS_CHIME ) + elif color_detected == Color.YELLOW: + print('Running Mission 4') + await Run4() + #await celebrate_mission_complete(CelebrationSound.POWER_UP) + elif color_detected == Color.BLUE: + print('Running Mission 5') + await Run5() + #await celebrate_mission_complete(CelebrationSound.LEVEL_UP) + elif color_detected == Color.VIOLET: + print('Running Mission 6') + await Run6() + else: + hub.light.off() + left_motor.stop() + right_motor.stop() + color_detected = Color.NONE + else: + color_detected = Color.NONE + + await wait(1000) #prevent loop from iterating fast +# Main execution loop +run_task(main()) From acfe0e622e38a9daec254fe27f7ebbfb06a215b2 Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Thu, 23 Oct 2025 02:30:26 +0000 Subject: [PATCH 70/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py This is the new version of Hazmat Code with the colors. Check to see if your color is different. Only Run2 is different, it was white, now violet. --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 239 ++++---------------- 1 file changed, 38 insertions(+), 201 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index eb1542c..37a00a9 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -23,168 +23,13 @@ drive_base = DriveBase(left_motor, right_motor, WHEEL_DIAMETER, AXLE_TRACK) drive_base.settings(600,500,300,200) drive_base.use_gyro(True) -# Color Settings -# https://docs.pybricks.com/en/latest/parameters/color.html -print("Default Detected Colors:", color_sensor.detectable_colors()) - -# Custom color Hue, Saturation, Brightness value for Lego bricks -Color.MAGENTA = Color(300,100,100) -Color.VIOLET = Color(277,68,32) -Color.BLUE = Color(240,100,100) -Color.CYAN = Color(180,100,100) - -LEGO_BRICKS_COLOR = [ - Color.BLUE, - Color.GREEN, - Color.WHITE, - Color.RED, - Color.YELLOW, - Color.MAGENTA, - Color.VIOLET, - Color.NONE -] -#Update Detectable colors -color_sensor.detectable_colors(LEGO_BRICKS_COLOR) - -print("Updated Detected Colors:", color_sensor.detectable_colors()) - -hub.speaker.volume(50) # Set the volume of the speaker - -# Celebration sound types -class CelebrationSound: - VICTORY_FANFARE = 0 - LEVEL_UP = 1 - SUCCESS_CHIME = 2 - TA_DA = 3 - POWER_UP = 4 - RICKROLL_INSPIRED = 5 - -async def play_victory_fanfare(): - """Classic victory fanfare""" - notes = [ - (262, 200), # C4 - (262, 200), # C4 - (262, 200), # C4 - (349, 600), # F4 - ] - - for freq, duration in notes: - await hub.speaker.beep(freq, duration) - await wait(50) -async def play_level_up(): - """Upward scale for level completion""" - notesold = [ - (262, 100), # C4 - (294, 100), # D4 - (330, 100), # E4 - (349, 100), # F4 - (392, 100), # G4 - (440, 100), # A4 - (494, 100), # B4 - (523, 300), # C5 - ] - notes = [ - (277, 100), - (330, 100), - (277, 100), - (554, 100), - (277, 100), - (413, 100), - (330, 100), - (277, 100), - (413, 100), - (277, 100), - (554, 100), - (413, 100), - (277, 100), - (413, 100), - (554, 100), - (413, 100) - ] - - for freq, duration in notes: - await hub.speaker.beep(freq, duration) - #await wait(20) -async def play_success_chime(): - """Simple success notification""" - notes = [ - (523, 150), # C5 - (659, 150), # E5 - (784, 300), # G5 - ] - - for freq, duration in notes: - await hub.speaker.beep(freq, duration) - await wait(50) -async def play_ta_da(): - """Classic "ta-da!" sound""" - notes = [ - (392, 200), # G4 - (523, 400), # C5 - ] - - for freq, duration in notes: - await hub.speaker.beep(freq, duration) - await wait(100) -async def play_power_up(): - """Rising power-up sound""" - for freq in range(200, 800, 50): - await hub.speaker.beep(freq, 50) - await wait(10) - await hub.speaker.beep(1000, 200) -async def play_rickroll_inspired(): - """Fun 80s-style dance beat inspired sound""" - # Upbeat bouncy rhythm - pattern = [ - (392, 200), (440, 200), (494, 200), (523, 200), - (440, 200), (392, 200), (349, 200), (392, 300), - (440, 200), (392, 200), (349, 200), (330, 400), - ] - - for freq, duration in pattern: - await hub.speaker.beep(freq, duration) - await wait(50) -async def celebrate_mission_complete(sound_type=CelebrationSound.SUCCESS_CHIME): - """ - Main celebration function to call after completing a mission. - Plays a sound and shows light animation. - - Args: - sound_type: CelebrationSound enum value (default: SUCCESS_CHIME) - """ - # Light show - hub.light.on(Color.GREEN) - - # Play the selected celebration sound - if sound_type == CelebrationSound.VICTORY_FANFARE: - await play_victory_fanfare() - elif sound_type == CelebrationSound.LEVEL_UP: - await play_level_up() - elif sound_type == CelebrationSound.SUCCESS_CHIME: - await play_success_chime() - elif sound_type == CelebrationSound.TA_DA: - await play_ta_da() - elif sound_type == CelebrationSound.POWER_UP: - await play_power_up() - elif sound_type == CelebrationSound.RICKROLL_INSPIRED: - await play_rickroll_inspired() - else: - await play_success_chime() # Default fallback - - # Blink the light - for _ in range(3): - hub.light.off() - await wait(100) - hub.light.on(Color.GREEN) - await wait(100) - - hub.light.off() WALL_DISTANCE = 200 # mm async def drive_forward(): """Drive forward continuously using DriveBase.""" #await drive_base.straight(5000) drive_base.drive(400,0) + async def monitor_distance(): """Monitor ultrasonic sensor and stop when wall is detected.""" while True: @@ -200,6 +45,7 @@ async def monitor_distance(): # Small delay to prevent overwhelming the sensor await wait(50) +#New Section async def Run1(): #From M8_5.py left_arm.run_angle(1000, 300) right_arm.run_angle(1000,500) @@ -336,49 +182,40 @@ async def Run6(): await right_arm.run_angle(300, 100) await drive_base.straight(-350) -async def main(): - while True: - - #await celebrate_mission_complete(CelebrationSound.LEVEL_UP) - color_reflected_percent = await color_sensor.reflection() - print(color_reflected_percent) - - - if color_reflected_percent > 0: # Make sure we actually have color reflections before checking for color - color_detected = await color_sensor.color() # Moved this inside the if clause - print(f'Detected color:{color_detected} : {color_detected.h}, {color_detected.s}, {color_detected.v}') - - if color_detected == Color.GREEN: - print('Running Mission 1') - await Run1() - #await celebrate_mission_complete(CelebrationSound.VICTORY_FANFARE) - elif color_detected == Color.WHITE: - print('Running Mission 2') - await Run2() - #await celebrate_mission_complete(CelebrationSound.RICKROLL_INSPIRED) - elif color_detected == Color.RED: - print('Running Mission 3') - await Run3() - #await celebrate_mission_complete(CelebrationSound.SUCCESS_CHIME ) - elif color_detected == Color.YELLOW: - print('Running Mission 4') - await Run4() - #await celebrate_mission_complete(CelebrationSound.POWER_UP) - elif color_detected == Color.BLUE: - print('Running Mission 5') - await Run5() - #await celebrate_mission_complete(CelebrationSound.LEVEL_UP) - elif color_detected == Color.VIOLET: - print('Running Mission 6') - await Run6() - else: - hub.light.off() - left_motor.stop() - right_motor.stop() - color_detected = Color.NONE +# Function to classify color based on HSV +async def main: + if reflected > 4: + if h < 4 or h > 350: #red + return "Red" + print('Running Mission 3') + await Run3() + elif 3 < h < 40 and s > 70: #orange + return "Orange" + print('Running Mission 6') + await Run6() + elif 47 < h < 56: #yellow + return "Yellow" + print('Running Mission 4') + await Run4() + elif 70 < h < 160: #green - do it vertically not horizontally for accuracy + return "Green" + print('Running Mission 1') + await Run1() + elif 210 < h < 225: #blue - do it vertically not horizontally for accuracy + return "Blue" + print('Running Mission 5') + await Run5() + elif 230 < h < 320: #purple + return "Purple" + print('Running Mission 2') + await Run2() else: - color_detected = Color.NONE - - await wait(1000) #prevent loop from iterating fast -# Main execution loop -run_task(main()) + return "Unknown" + +# Main loop +while True: + h, s, v = sensor.hsv() + reflected = sensor.reflection() + color = detect_color(h, s, v, reflected) + print(f"Detected Color: {color} (Hue: {h}, Sat: {s}, Val: {v})") + wait(1000) From 1dec912abbc9ad9c00b226530f252021fb480e40 Mon Sep 17 00:00:00 2001 From: Ayaan <32agarwa@elmbrookstudents.org> Date: Fri, 24 Oct 2025 00:11:38 +0000 Subject: [PATCH 71/96] Update missions/tip the scale.py --- missions/tip the scale.py | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/missions/tip the scale.py b/missions/tip the scale.py index 4573352..3a4264e 100644 --- a/missions/tip the scale.py +++ b/missions/tip the scale.py @@ -15,31 +15,34 @@ left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) right_arm = Motor(Port.D) drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) -drive_base.settings(300,1000,300,200) +drive_base.settings(600,500,300,200) -#drive_base.use_gyro(True) +drive_base.use_gyro(True) async def main(): - left_arm.run_angle(500,200) + left_arm.run_angle(600,200) right_arm.run_angle(500,200) await drive_base.straight(70) - await drive_base.turn(-55) + await drive_base.turn(-70) await drive_base.straight(900) - await drive_base.turn(92.5) + await drive_base.turn(115) await drive_base.straight(75) - await drive_base.straight(21) + await drive_base.straight(33) await right_arm.run_angle(500,-250) await right_arm.run_angle(500,250) - await drive_base.turn(55) + await drive_base.turn(66) + await drive_base.straight(7) - await left_arm.run_angle(300,-400) + await left_arm.run_angle(560,-390) #going down + print('turning now...') + await drive_base.turn(40) # turning right + await left_arm.run_angle(-410,-400) #lift a little bit - await drive_base.turn(46.5) + await drive_base.turn(-46.5) #ma din din din dun await drive_base.turn(-40) await drive_base.straight(900) run_task(main()) - From 2d2863726b6296c9dca0c8c0a18be051e97dcccc Mon Sep 17 00:00:00 2001 From: Vickram <31kapoov@elmbrookstudents.org> Date: Fri, 24 Oct 2025 00:35:06 +0000 Subject: [PATCH 72/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 164 ++++++++++---------- 1 file changed, 80 insertions(+), 84 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index 37a00a9..a243e83 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -7,95 +7,88 @@ from pybricks.hubs import PrimeHub # Initialize hub and devices hub = PrimeHub() - left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) right_motor = Motor(Port.B) - left_arm = Motor(Port.C) right_arm = Motor(Port.D) -lazer_ranger = UltrasonicSensor(Port.E) +lazer_ranger = UltrasonicSensor(Port.E) color_sensor = ColorSensor(Port.F) # DriveBase configuration WHEEL_DIAMETER = 68.8 # mm (adjust for your wheels) AXLE_TRACK = 180 # mm (distance between wheels) drive_base = DriveBase(left_motor, right_motor, WHEEL_DIAMETER, AXLE_TRACK) -drive_base.settings(600,500,300,200) +drive_base.settings(600, 500, 300, 200) drive_base.use_gyro(True) - WALL_DISTANCE = 200 # mm + async def drive_forward(): """Drive forward continuously using DriveBase.""" - #await drive_base.straight(5000) - drive_base.drive(400,0) + drive_base.drive(400, 0) + async def monitor_distance(): """Monitor ultrasonic sensor and stop when wall is detected.""" while True: - distance = await lazer_ranger.distance() + distance = lazer_ranger.distance() if distance < WALL_DISTANCE: # Stop the drivebase await drive_base.turn(-180) - drive_base.brake + drive_base.brake() print(f"Wall detected at {distance}mm!") break # Small delay to prevent overwhelming the sensor await wait(50) -#New Section -async def Run1(): #From M8_5.py +# New Section +async def Run1(): # From M8_5.py left_arm.run_angle(1000, 300) - right_arm.run_angle(1000,500) + right_arm.run_angle(1000, 500) await drive_base.straight(320) - - await right_arm.run_angle(5000,-500, Stop.HOLD) - await right_arm.run_angle(5000,500, Stop.HOLD) - await right_arm.run_angle(5000,-500, Stop.HOLD) - await right_arm.run_angle(5000,500, Stop.HOLD) - await right_arm.run_angle(5000,-500, Stop.HOLD) - + await right_arm.run_angle(5000, -500, Stop.HOLD) + await right_arm.run_angle(5000, 500, Stop.HOLD) + await right_arm.run_angle(5000, -500, Stop.HOLD) + await right_arm.run_angle(5000, 500, Stop.HOLD) + await right_arm.run_angle(5000, -500, Stop.HOLD) await drive_base.turn(-20) await drive_base.straight(277) await drive_base.turn(20) await drive_base.straight(65) - await drive_base.turn(-30) - right_arm.run_angle(50,500) + right_arm.run_angle(50, 500) await drive_base.turn(45) await drive_base.straight(-145) await drive_base.turn(-60) await drive_base.straight(90) - await left_arm.run_angle(1000,-450) + await left_arm.run_angle(1000, -450) await drive_base.straight(-145) - await left_arm.run_angle(1000,450) + await left_arm.run_angle(1000, 450) await drive_base.straight(10) await drive_base.turn(35) await drive_base.straight(-600) -async def Run2(): #From Heavy_lifting_final.py - await drive_base.straight(200) +async def Run2(): # From Heavy_lifting_final.py + await drive_base.straight(200) await drive_base.turn(-20) await drive_base.straight(536) await drive_base.turn(60, Stop.HOLD) await drive_base.straight(30) - - await right_arm.run_angle(5000,2900) + await right_arm.run_angle(5000, 2900) await drive_base.straight(40) - await right_arm.run_angle(5000,-4000) + await right_arm.run_angle(5000, -4000) await drive_base.straight(-60) - await drive_base.turn(-60) await drive_base.straight(-670) -async def Run3(): #tip the scale.py - drive_base.settings(300,1000,300,200) #Custom drive_base setting based on Ayaan's code +async def Run3(): # tip the scale.py + drive_base.settings(300, 1000, 300, 200) # Custom drive_base setting based on Ayaan's code - left_arm.run_angle(500,200) - right_arm.run_angle(500,200) + left_arm.run_angle(500, 200) + right_arm.run_angle(500, 200) await drive_base.straight(70) await drive_base.turn(-55) @@ -104,49 +97,38 @@ async def Run3(): #tip the scale.py await drive_base.straight(75) await drive_base.straight(21) - await right_arm.run_angle(500,-250) - await right_arm.run_angle(500,250) + await right_arm.run_angle(500, -250) + await right_arm.run_angle(500, 250) await drive_base.turn(55) - await left_arm.run_angle(300,-400) + await left_arm.run_angle(300, -400) await drive_base.turn(46.5) await drive_base.turn(-40) await drive_base.straight(900) + drive_base.settings(600, 500, 300, 200) # Reset it to the initial values - drive_base.settings(600,500,300,200) #Reset it to the initial values -async def Run4(): #From Send_Over_Final.py - - #Get to mission +async def Run4(): # From Send_Over_Final.py + # Get to mission await drive_base.straight(920) - await drive_base.turn(-90,Stop.HOLD) + await drive_base.turn(-90, Stop.HOLD) await drive_base.straight(65) - #Solve mission + # Solve mission drive_base.turn(-10) - await left_arm.run_angle(10000,-4000) - #Get to Red Start + await left_arm.run_angle(10000, -4000) + # Get to Red Start await drive_base.straight(-110) await drive_base.turn(90) await drive_base.straight(500) - # while True: - # distance_mm = await lazer_ranger.distance() - # print('distancing...',distance_mm) - - # if distance_mm < 300: - # drive_base.stop - # break - # else: - # drive_base.straight(300) - # print('running...') - # await wait(10) await multitask( drive_forward(), monitor_distance() ) -#Add Rishi's code here + +# Add Rishi's code here async def Run5(): await drive_base.straight(519) await left_arm.run_angle(-10000, 300) @@ -174,48 +156,62 @@ async def Run5(): await right_arm.run_angle(3000, 3000) await drive_base.turn(-40) -#Add - Adi's code here + +# Add - Adi's code here async def Run6(): await drive_base.straight(420) - await right_arm.run_angle(300,-100) + await right_arm.run_angle(300, -100) await drive_base.straight(-100) await right_arm.run_angle(300, 100) await drive_base.straight(-350) + # Function to classify color based on HSV -async def main: +def detect_color(h, s, v, reflected): if reflected > 4: - if h < 4 or h > 350: #red + if h < 4 or h > 350: # red return "Red" - print('Running Mission 3') - await Run3() - elif 3 < h < 40 and s > 70: #orange + elif 3 < h < 40 and s > 70: # orange return "Orange" - print('Running Mission 6') - await Run6() - elif 47 < h < 56: #yellow + elif 47 < h < 56: # yellow return "Yellow" - print('Running Mission 4') - await Run4() - elif 70 < h < 160: #green - do it vertically not horizontally for accuracy + elif 70 < h < 160: # green - do it vertically not horizontally for accuracy return "Green" - print('Running Mission 1') - await Run1() - elif 210 < h < 225: #blue - do it vertically not horizontally for accuracy + elif 210 < h < 225: # blue - do it vertically not horizontally for accuracy return "Blue" - print('Running Mission 5') - await Run5() - elif 230 < h < 320: #purple + elif 260 < h < 350: # purple return "Purple" - print('Running Mission 2') - await Run2() else: return "Unknown" + return "Unknown" -# Main loop -while True: - h, s, v = sensor.hsv() - reflected = sensor.reflection() - color = detect_color(h, s, v, reflected) - print(f"Detected Color: {color} (Hue: {h}, Sat: {s}, Val: {v})") - wait(1000) + +async def main(): + while True: + h, s, v = await color_sensor.hsv() + reflected = await color_sensor.reflection() + color = detect_color(h, s, v, reflected) + + if color == "Red": + print('Running Mission 3') + await Run3() #red + elif color == "Orange": + print('Running Mission 6') + await Run6() #orange + elif color == "Yellow": + print('Running Mission 4') + await Run4() #yellow + elif color == "Green": + print('Running Mission 1') + await Run1() #green - vertically + elif color == "Blue": + print('Running Mission 5') + await Run5() #blue - vertically + elif color == "Purple": + print('Running Mission 2') + await Run2() #purple - vertically + else: + print(f"Unknown color detected (Hue: {h}, Sat: {s}, Val: {v})") + await wait(10) +# Run the main function +run_task(main()) \ No newline at end of file From 32a695e9ca07ca6fd10974b9ac0f981b0394ea1c Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 24 Oct 2025 00:38:26 +0000 Subject: [PATCH 73/96] Update codes_for_scrimmage/hazmat/hazmat_main.py --- codes_for_scrimmage/hazmat/hazmat_main.py | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/codes_for_scrimmage/hazmat/hazmat_main.py b/codes_for_scrimmage/hazmat/hazmat_main.py index eb1542c..ea87f5e 100644 --- a/codes_for_scrimmage/hazmat/hazmat_main.py +++ b/codes_for_scrimmage/hazmat/hazmat_main.py @@ -189,6 +189,7 @@ async def monitor_distance(): """Monitor ultrasonic sensor and stop when wall is detected.""" while True: distance = await lazer_ranger.distance() + print('distancing...',distance) if distance < WALL_DISTANCE: # Stop the drivebase @@ -246,30 +247,29 @@ async def Run2(): #From Heavy_lifting_final.py async def Run3(): #tip the scale.py - drive_base.settings(300,1000,300,200) #Custom drive_base setting based on Ayaan's code - - left_arm.run_angle(500,200) + left_arm.run_angle(600,200) right_arm.run_angle(500,200) await drive_base.straight(70) - await drive_base.turn(-55) + await drive_base.turn(-70) await drive_base.straight(900) - await drive_base.turn(92.5) + await drive_base.turn(115) await drive_base.straight(75) - await drive_base.straight(21) + await drive_base.straight(33) await right_arm.run_angle(500,-250) await right_arm.run_angle(500,250) - await drive_base.turn(55) + await drive_base.turn(66) + await drive_base.straight(7) - await left_arm.run_angle(300,-400) + await left_arm.run_angle(560,-390) #going down + await drive_base.turn(40) # turning right + await left_arm.run_angle(-410,-400) #lift a little bit - await drive_base.turn(46.5) + await drive_base.turn(-46.5) #ma din din din dun await drive_base.turn(-40) await drive_base.straight(900) - drive_base.settings(600,500,300,200) #Reset it to the initial values - async def Run4(): #From Send_Over_Final.py #Get to mission From 249071f5c306dbc7421a5160dc52175649a06a00 Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Fri, 24 Oct 2025 00:42:21 +0000 Subject: [PATCH 74/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 22 ++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index a243e83..38c1a00 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -132,7 +132,7 @@ async def Run4(): # From Send_Over_Final.py async def Run5(): await drive_base.straight(519) await left_arm.run_angle(-10000, 300) - await left_arm.run_angle(10000, 600) + await left_arm_left.run_angle(10000, 600) await drive_base.straight(160) await drive_base.turn(-30) await drive_base.straight(50) @@ -142,19 +142,23 @@ async def Run5(): await drive_base.straight(25) await right_arm.run_angle(10000, -3000) await drive_base.straight(-100) - await drive_base.turn(-55) + await drive_base.turn(-52) await right_arm.run_angle(10000, -3000) - await drive_base.straight(250) + await drive_base.straight(245) await drive_base.turn(-5) await right_arm.run_angle(10000, 7000) - await drive_base.straight(-50) + await drive_base.straight(-65) await drive_base.turn(45) - await drive_base.straight(100) - await drive_base.turn(37) - await right_arm.run_angle(10000, -6000) - await drive_base.straight(90) - await right_arm.run_angle(3000, 3000) + await drive_base.straight(125) + await drive_base.turn(26) + await right_arm.run_angle(10000, -8000) + await drive_base.straight(50) + await aright_arm.run_angle(10000, 3500) await drive_base.turn(-40) + await drive_base.turn(5) + await drive_base.straight(-300) + await drive_base.turn(-78) + await drive_base.straight(-700) # Add - Adi's code here From 831b75025d6ae24dd97385cc1e48345a193d1f3d Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Fri, 24 Oct 2025 00:45:10 +0000 Subject: [PATCH 75/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py Minor changes. --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 27 +++++++++++---------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index 38c1a00..59471a4 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -85,28 +85,29 @@ async def Run2(): # From Heavy_lifting_final.py async def Run3(): # tip the scale.py - drive_base.settings(300, 1000, 300, 200) # Custom drive_base setting based on Ayaan's code - - left_arm.run_angle(500, 200) - right_arm.run_angle(500, 200) + left_arm.run_angle(600,200) + right_arm.run_angle(500,200) await drive_base.straight(70) - await drive_base.turn(-55) + await drive_base.turn(-70) await drive_base.straight(900) - await drive_base.turn(92.5) + await drive_base.turn(115) await drive_base.straight(75) - await drive_base.straight(21) - await right_arm.run_angle(500, -250) - await right_arm.run_angle(500, 250) - await drive_base.turn(55) + await drive_base.straight(33) + await right_arm.run_angle(500,-250) + await right_arm.run_angle(500,250) + await drive_base.turn(66) + await drive_base.straight(7) - await left_arm.run_angle(300, -400) + await left_arm.run_angle(560,-390) #going down + print('turning now...') + await drive_base.turn(40) # turning right + await left_arm.run_angle(-410,-400) #lift a little bit - await drive_base.turn(46.5) + await drive_base.turn(-46.5) #ma din din din dun await drive_base.turn(-40) await drive_base.straight(900) - drive_base.settings(600, 500, 300, 200) # Reset it to the initial values async def Run4(): # From Send_Over_Final.py From dbb0749ff366bb7bd08f6c3ee236b4054eeaf19a Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Fri, 24 Oct 2025 00:49:24 +0000 Subject: [PATCH 76/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py Minor Changes AGAIN!! --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 22 ++++++++++++++++----- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index 59471a4..bffb210 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -111,24 +111,36 @@ async def Run3(): # tip the scale.py async def Run4(): # From Send_Over_Final.py - # Get to mission + #Get to mission await drive_base.straight(920) - await drive_base.turn(-90, Stop.HOLD) + await drive_base.turn(-90,Stop.HOLD) await drive_base.straight(65) - # Solve mission + #Solve mission drive_base.turn(-10) - await left_arm.run_angle(10000, -4000) - # Get to Red Start + await left_arm.run_angle(10000,-4000) + #Get to Red Start await drive_base.straight(-110) await drive_base.turn(90) await drive_base.straight(500) + # while True: + # distance_mm = await lazer_ranger.distance() + # print('distancing...',distance_mm) + + # if distance_mm < 300: + # drive_base.stop + # break + # else: + # drive_base.straight(300) + # print('running...') + # await wait(10) await multitask( drive_forward(), monitor_distance() ) + # Add Rishi's code here async def Run5(): await drive_base.straight(519) From 94bae3c140079cd0818f34c111565a141109233f Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Fri, 24 Oct 2025 00:52:40 +0000 Subject: [PATCH 77/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index bffb210..20d182e 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -45,7 +45,7 @@ async def monitor_distance(): # New Section async def Run1(): # From M8_5.py - left_arm.run_angle(1000, 300) + left_arm.run_angle(1000, -300) right_arm.run_angle(1000, 500) await drive_base.straight(320) await right_arm.run_angle(5000, -500, Stop.HOLD) @@ -63,9 +63,9 @@ async def Run1(): # From M8_5.py await drive_base.straight(-145) await drive_base.turn(-60) await drive_base.straight(90) - await left_arm.run_angle(1000, -450) - await drive_base.straight(-145) await left_arm.run_angle(1000, 450) + await drive_base.straight(-145) + await left_arm.run_angle(1000, -450) await drive_base.straight(10) await drive_base.turn(35) await drive_base.straight(-600) @@ -85,7 +85,7 @@ async def Run2(): # From Heavy_lifting_final.py async def Run3(): # tip the scale.py - left_arm.run_angle(600,200) + left_arm.run_angle(600,-200) right_arm.run_angle(500,200) await drive_base.straight(70) @@ -100,7 +100,7 @@ async def Run3(): # tip the scale.py await drive_base.turn(66) await drive_base.straight(7) - await left_arm.run_angle(560,-390) #going down + await left_arm.run_angle(560,390) #going down print('turning now...') await drive_base.turn(40) # turning right await left_arm.run_angle(-410,-400) #lift a little bit From 3765db30018e1c0e1dd0d47093ad9da6c1ed97bd Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Fri, 24 Oct 2025 01:01:04 +0000 Subject: [PATCH 78/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py MINOR CHANGES AGAIN --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index 20d182e..daa6814 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -177,9 +177,9 @@ async def Run5(): # Add - Adi's code here async def Run6(): await drive_base.straight(420) - await right_arm.run_angle(300, -100) - await drive_base.straight(-100) await right_arm.run_angle(300, 100) + await drive_base.straight(-100) + await right_arm.run_angle(300,-100) await drive_base.straight(-350) From b41f833c5ece709de71adeae5006f85b8897c560 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 24 Oct 2025 01:07:23 +0000 Subject: [PATCH 79/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index daa6814..af312ee 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -21,7 +21,7 @@ drive_base = DriveBase(left_motor, right_motor, WHEEL_DIAMETER, AXLE_TRACK) drive_base.settings(600, 500, 300, 200) drive_base.use_gyro(True) -WALL_DISTANCE = 200 # mm +WALL_DISTANCE = 300 # mm async def drive_forward(): """Drive forward continuously using DriveBase.""" @@ -32,11 +32,11 @@ async def monitor_distance(): """Monitor ultrasonic sensor and stop when wall is detected.""" while True: distance = lazer_ranger.distance() + print('Distancing...',distance) if distance < WALL_DISTANCE: # Stop the drivebase - await drive_base.turn(-180) - drive_base.brake() + await drive_base.stop print(f"Wall detected at {distance}mm!") break @@ -117,7 +117,7 @@ async def Run4(): # From Send_Over_Final.py await drive_base.straight(65) #Solve mission drive_base.turn(-10) - await left_arm.run_angle(10000,-4000) + await left_arm.run_angle(10000, 4000) #Get to Red Start await drive_base.straight(-110) await drive_base.turn(90) From 5427c73f1cc169acc2a04541df73e2da0a8c5f7c Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Fri, 24 Oct 2025 01:09:49 +0000 Subject: [PATCH 80/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py I am not a monkey --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index af312ee..55e9945 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -176,11 +176,8 @@ async def Run5(): # Add - Adi's code here async def Run6(): - await drive_base.straight(420) - await right_arm.run_angle(300, 100) - await drive_base.straight(-100) - await right_arm.run_angle(300,-100) - await drive_base.straight(-350) + await drive_base.straight(750) + await drive_base.straight(-650) # Function to classify color based on HSV From 702e05e7f771e6e721bb71acf1c6346f5d7fc437 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 24 Oct 2025 01:13:45 +0000 Subject: [PATCH 81/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index 55e9945..647f370 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -31,7 +31,7 @@ async def drive_forward(): async def monitor_distance(): """Monitor ultrasonic sensor and stop when wall is detected.""" while True: - distance = lazer_ranger.distance() + distance = await lazer_ranger.distance() print('Distancing...',distance) if distance < WALL_DISTANCE: From 9d3d8b48e46acee052be00e8dc457563f83a24d4 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 24 Oct 2025 01:15:43 +0000 Subject: [PATCH 82/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 1 - 1 file changed, 1 deletion(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index 647f370..6f05d42 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -121,7 +121,6 @@ async def Run4(): # From Send_Over_Final.py #Get to Red Start await drive_base.straight(-110) await drive_base.turn(90) - await drive_base.straight(500) # while True: # distance_mm = await lazer_ranger.distance() From 54e8c9eba5f9374ee5284d077e5d6d340a55c4e3 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Fri, 24 Oct 2025 01:16:19 +0000 Subject: [PATCH 83/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 1 - 1 file changed, 1 deletion(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index 6f05d42..eed6bef 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -121,7 +121,6 @@ async def Run4(): # From Send_Over_Final.py #Get to Red Start await drive_base.straight(-110) await drive_base.turn(90) - # while True: # distance_mm = await lazer_ranger.distance() # print('distancing...',distance_mm) From 1317c8e8cef7384d7eecdbfe7725b283bb28fde3 Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Sat, 25 Oct 2025 01:15:49 +0000 Subject: [PATCH 84/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py Minor Changes --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 27 ++++++++++----------- 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index eed6bef..4b98dc0 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -143,32 +143,31 @@ async def Run4(): # From Send_Over_Final.py async def Run5(): await drive_base.straight(519) await left_arm.run_angle(-10000, 300) - await left_arm_left.run_angle(10000, 600) + await left_arm.run_angle(10000, 600) await drive_base.straight(160) await drive_base.turn(-30) await drive_base.straight(50) await right_arm.run_angle(3000, 3000) await drive_base.straight(-150) - await drive_base.turn(135) + await drive_base.turn(120) await drive_base.straight(25) await right_arm.run_angle(10000, -3000) - await drive_base.straight(-100) - await drive_base.turn(-52) + await drive_base.straight(-110) + await drive_base.turn(-43) await right_arm.run_angle(10000, -3000) - await drive_base.straight(245) - await drive_base.turn(-5) - await right_arm.run_angle(10000, 7000) + await drive_base.straight(295) + await right_arm.run_angle(10000, 9000) await drive_base.straight(-65) await drive_base.turn(45) - await drive_base.straight(125) + await drive_base.straight(175) await drive_base.turn(26) - await right_arm.run_angle(10000, -8000) - await drive_base.straight(50) - await aright_arm.run_angle(10000, 3500) - await drive_base.turn(-40) - await drive_base.turn(5) + await drive_base.straight(-100) + await right_arm.run_angle(10000, -9000) + await drive_base.straight(100) + await right_arm.run_angle(10000, 3500) + await drive_base.turn(-30) await drive_base.straight(-300) - await drive_base.turn(-78) + await drive_base.turn(-80) await drive_base.straight(-700) From 4d1bd8abe36cd82d019ed90c0cb2da2df2373f8b Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Sat, 25 Oct 2025 01:26:41 +0000 Subject: [PATCH 85/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index 4b98dc0..257c9f8 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -105,7 +105,7 @@ async def Run3(): # tip the scale.py await drive_base.turn(40) # turning right await left_arm.run_angle(-410,-400) #lift a little bit - await drive_base.turn(-46.5) #ma din din din dun + await drive_base.turn(46.5) #ma din din din dun await drive_base.turn(-40) await drive_base.straight(900) From 9a320589ab74255891852c935be71cfb3dd66dd5 Mon Sep 17 00:00:00 2001 From: Johannes <31liwaj@elmbrookstudents.org> Date: Sat, 25 Oct 2025 01:38:57 +0000 Subject: [PATCH 86/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py 67 --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index 257c9f8..7ad8fba 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -103,10 +103,9 @@ async def Run3(): # tip the scale.py await left_arm.run_angle(560,390) #going down print('turning now...') await drive_base.turn(40) # turning right - await left_arm.run_angle(-410,-400) #lift a little bit - - await drive_base.turn(46.5) #ma din din din dun - await drive_base.turn(-40) + await left_arm.run_angle(410,-400) #lift a little bit + await drive_base.straight(80) + await drive_base.turn(-41) #ma din din din dun 67 41 21 69 await drive_base.straight(900) From 7b539b45d006e21819744996a7be8d53454c8ccf Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Sat, 25 Oct 2025 02:05:16 +0000 Subject: [PATCH 87/96] Update codes_for_scrimmage/hazmat/mainhazmatUPD.py CVC --- codes_for_scrimmage/hazmat/mainhazmatUPD.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/codes_for_scrimmage/hazmat/mainhazmatUPD.py b/codes_for_scrimmage/hazmat/mainhazmatUPD.py index 7ad8fba..c48de0b 100644 --- a/codes_for_scrimmage/hazmat/mainhazmatUPD.py +++ b/codes_for_scrimmage/hazmat/mainhazmatUPD.py @@ -159,9 +159,9 @@ async def Run5(): await drive_base.straight(-65) await drive_base.turn(45) await drive_base.straight(175) - await drive_base.turn(26) + await drive_base.turn(24.5) await drive_base.straight(-100) - await right_arm.run_angle(10000, -9000) + await right_arm.run_angle(10000, -8500) await drive_base.straight(100) await right_arm.run_angle(10000, 3500) await drive_base.turn(-30) From ef0ff44f2be6ebde4d52c094ad9a410200d295ef Mon Sep 17 00:00:00 2001 From: Rishikesh Lolapu <31lolapr@elmbrookstudents.org> Date: Sat, 25 Oct 2025 02:06:49 +0000 Subject: [PATCH 88/96] HazmatCodeChanges This is the code we changed at the scrimmage. --- .../hazmat/HazmatCodeChanges.py | 227 ++++++++++++++++++ 1 file changed, 227 insertions(+) create mode 100644 codes_for_scrimmage/hazmat/HazmatCodeChanges.py diff --git a/codes_for_scrimmage/hazmat/HazmatCodeChanges.py b/codes_for_scrimmage/hazmat/HazmatCodeChanges.py new file mode 100644 index 0000000..c48de0b --- /dev/null +++ b/codes_for_scrimmage/hazmat/HazmatCodeChanges.py @@ -0,0 +1,227 @@ +from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor +from pybricks.parameters import Button, Color, Direction, Port, Side, Stop +from pybricks.tools import run_task, multitask +from pybricks.tools import wait, StopWatch +from pybricks.robotics import DriveBase +from pybricks.hubs import PrimeHub + +# Initialize hub and devices +hub = PrimeHub() +left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) +right_motor = Motor(Port.B) +left_arm = Motor(Port.C) +right_arm = Motor(Port.D) +lazer_ranger = UltrasonicSensor(Port.E) +color_sensor = ColorSensor(Port.F) + +# DriveBase configuration +WHEEL_DIAMETER = 68.8 # mm (adjust for your wheels) +AXLE_TRACK = 180 # mm (distance between wheels) +drive_base = DriveBase(left_motor, right_motor, WHEEL_DIAMETER, AXLE_TRACK) +drive_base.settings(600, 500, 300, 200) +drive_base.use_gyro(True) + +WALL_DISTANCE = 300 # mm + +async def drive_forward(): + """Drive forward continuously using DriveBase.""" + drive_base.drive(400, 0) + + +async def monitor_distance(): + """Monitor ultrasonic sensor and stop when wall is detected.""" + while True: + distance = await lazer_ranger.distance() + print('Distancing...',distance) + + if distance < WALL_DISTANCE: + # Stop the drivebase + await drive_base.stop + print(f"Wall detected at {distance}mm!") + break + + # Small delay to prevent overwhelming the sensor + await wait(50) + +# New Section +async def Run1(): # From M8_5.py + left_arm.run_angle(1000, -300) + right_arm.run_angle(1000, 500) + await drive_base.straight(320) + await right_arm.run_angle(5000, -500, Stop.HOLD) + await right_arm.run_angle(5000, 500, Stop.HOLD) + await right_arm.run_angle(5000, -500, Stop.HOLD) + await right_arm.run_angle(5000, 500, Stop.HOLD) + await right_arm.run_angle(5000, -500, Stop.HOLD) + await drive_base.turn(-20) + await drive_base.straight(277) + await drive_base.turn(20) + await drive_base.straight(65) + await drive_base.turn(-30) + right_arm.run_angle(50, 500) + await drive_base.turn(45) + await drive_base.straight(-145) + await drive_base.turn(-60) + await drive_base.straight(90) + await left_arm.run_angle(1000, 450) + await drive_base.straight(-145) + await left_arm.run_angle(1000, -450) + await drive_base.straight(10) + await drive_base.turn(35) + await drive_base.straight(-600) + +async def Run2(): # From Heavy_lifting_final.py + await drive_base.straight(200) + await drive_base.turn(-20) + await drive_base.straight(536) + await drive_base.turn(60, Stop.HOLD) + await drive_base.straight(30) + await right_arm.run_angle(5000, 2900) + await drive_base.straight(40) + await right_arm.run_angle(5000, -4000) + await drive_base.straight(-60) + await drive_base.turn(-60) + await drive_base.straight(-670) + + +async def Run3(): # tip the scale.py + left_arm.run_angle(600,-200) + right_arm.run_angle(500,200) + await drive_base.straight(70) + + await drive_base.turn(-70) + await drive_base.straight(900) + await drive_base.turn(115) + + await drive_base.straight(75) + await drive_base.straight(33) + await right_arm.run_angle(500,-250) + await right_arm.run_angle(500,250) + await drive_base.turn(66) + await drive_base.straight(7) + + await left_arm.run_angle(560,390) #going down + print('turning now...') + await drive_base.turn(40) # turning right + await left_arm.run_angle(410,-400) #lift a little bit + await drive_base.straight(80) + await drive_base.turn(-41) #ma din din din dun 67 41 21 69 + await drive_base.straight(900) + + +async def Run4(): # From Send_Over_Final.py + #Get to mission + await drive_base.straight(920) + await drive_base.turn(-90,Stop.HOLD) + await drive_base.straight(65) + #Solve mission + drive_base.turn(-10) + await left_arm.run_angle(10000, 4000) + #Get to Red Start + await drive_base.straight(-110) + await drive_base.turn(90) + # while True: + # distance_mm = await lazer_ranger.distance() + # print('distancing...',distance_mm) + + # if distance_mm < 300: + # drive_base.stop + # break + # else: + # drive_base.straight(300) + # print('running...') + # await wait(10) + await multitask( + drive_forward(), + monitor_distance() + ) + + + +# Add Rishi's code here +async def Run5(): + await drive_base.straight(519) + await left_arm.run_angle(-10000, 300) + await left_arm.run_angle(10000, 600) + await drive_base.straight(160) + await drive_base.turn(-30) + await drive_base.straight(50) + await right_arm.run_angle(3000, 3000) + await drive_base.straight(-150) + await drive_base.turn(120) + await drive_base.straight(25) + await right_arm.run_angle(10000, -3000) + await drive_base.straight(-110) + await drive_base.turn(-43) + await right_arm.run_angle(10000, -3000) + await drive_base.straight(295) + await right_arm.run_angle(10000, 9000) + await drive_base.straight(-65) + await drive_base.turn(45) + await drive_base.straight(175) + await drive_base.turn(24.5) + await drive_base.straight(-100) + await right_arm.run_angle(10000, -8500) + await drive_base.straight(100) + await right_arm.run_angle(10000, 3500) + await drive_base.turn(-30) + await drive_base.straight(-300) + await drive_base.turn(-80) + await drive_base.straight(-700) + + +# Add - Adi's code here +async def Run6(): + await drive_base.straight(750) + await drive_base.straight(-650) + + +# Function to classify color based on HSV +def detect_color(h, s, v, reflected): + if reflected > 4: + if h < 4 or h > 350: # red + return "Red" + elif 3 < h < 40 and s > 70: # orange + return "Orange" + elif 47 < h < 56: # yellow + return "Yellow" + elif 70 < h < 160: # green - do it vertically not horizontally for accuracy + return "Green" + elif 210 < h < 225: # blue - do it vertically not horizontally for accuracy + return "Blue" + elif 260 < h < 350: # purple + return "Purple" + else: + return "Unknown" + return "Unknown" + + +async def main(): + while True: + h, s, v = await color_sensor.hsv() + reflected = await color_sensor.reflection() + color = detect_color(h, s, v, reflected) + + if color == "Red": + print('Running Mission 3') + await Run3() #red + elif color == "Orange": + print('Running Mission 6') + await Run6() #orange + elif color == "Yellow": + print('Running Mission 4') + await Run4() #yellow + elif color == "Green": + print('Running Mission 1') + await Run1() #green - vertically + elif color == "Blue": + print('Running Mission 5') + await Run5() #blue - vertically + elif color == "Purple": + print('Running Mission 2') + await Run2() #purple - vertically + else: + print(f"Unknown color detected (Hue: {h}, Sat: {s}, Val: {v})") + await wait(10) +# Run the main function +run_task(main()) \ No newline at end of file From 4ff5de480d17316d40cd4aaf46e4ede8ed802ec7 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Tue, 28 Oct 2025 18:06:09 +0000 Subject: [PATCH 89/96] Update README.md --- README.md | 53 +++++++++++++++++++++++------------------------------ 1 file changed, 23 insertions(+), 30 deletions(-) diff --git a/README.md b/README.md index 49a400b..298ed1d 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ ## Project Overview -Welcome to the official code repository for **Team 65266 Lego Dynamics**! This repository contains all the Pybricks code powering our robot through the UNEARTHED season missions. Our modular approach allows for flexible mission execution and quick color-sensor-based run selection. +Welcome to the official code repository for **Team 65266 - Lego Dynamics**! This repository contains all the Pybricks code powering our robot through the UNEARTHED season missions. Our modular approach allows for flexible mission execution and quick color-sensor-based run selection. --- @@ -26,8 +26,8 @@ Welcome to the official code repository for **Team 65266 Lego Dynamics**! This r |-----------|--------------| | **Robot Name** | Optimus Prime III | | **Firmware** | Pybricks | -| **Attachment Motors** | 2ร— Large Motors (Ports C & D) | -| **Drive Motors** | 2ร— Small Motors (Ports A & B) | +| **Attachment Motors** | 2x Large Motors (Ports C & D) | +| **Drive Motors** | 2x Small Motors (Ports A & B) | | **Sensors** | Up-facing Color Sensor (Quick Start) | | **Attachments** | Multiple mission-specific tools | @@ -46,10 +46,10 @@ Our codebase is organized for maximum efficiency and modularity: ``` Repository โ”ฃ run_1.py # Individual mission runs - โ”ฃ run_2.py # Each file = 1+ mission completions + โ”ฃ run_2.py โ”ฃ run_3.py โ”ฃ ... - โ”— master.py # ๐ŸŽฏ Combined master file with color-start logic + โ”— masterFile.py # ๐ŸŽฏ Combined master file with color-start logic - this changes periodically as we release new versions. Check this README if you are unsure what code should be loaded on the robot. ``` ### Workflow @@ -61,15 +61,16 @@ Repository ## How to Use -### Installation & Deployment +### Installation & Deployment - from the server - everyday -1. **Load the Code** - ```bash - # Open the master.py file in Pybricks IDE - ``` +1. Download the file codes_for_scrimmage/hazmat/mainhazmatUPD.py -2. **Connect to Robot** - - Pair your robot via Bluetooth in Pybricks +2. Open https://code.pybricks.com/ and select the "Import a file" button on the top of the left bar. Import the .py file. Pair your robot via Bluetooth in Pybricks by selecting the Bluetooth button. + + - Import button looks like this: + ![alt text](https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed/raw/branch/do-not-merge/import.png) + - Bluetooth button looks like this: + ![alt text](https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed/raw/branch/do-not-merge/bluetooth.png) 3. **Upload to Robot** - Click "Download and Run" or send the program to the robot @@ -79,16 +80,14 @@ Repository - Different colors trigger different mission runs! ### Color Start System -| Color | Mission | Celebration Sound | -|-------|-----------|------------------| -| Green ๐ŸŸฉ | Run 1 | Victory Fanfare | -| White โšช | Run 2 | Rickroll Inspired | -| Yellow ๐ŸŸจ | Run 3 | Success Chime | -| Orange ๐ŸŸง | Run 4 | Power Up | -| Blue ๐ŸŸฆ | Run 5 | Power Up | -| Red ๐ŸŸฅ | Run 6 | Ta-Da! | - -> **Tip** Organize your colored bricks before the match for quick run selection! +| Color | Mission | +|-------|-----------| +| Green ๐ŸŸฉ | Run 1 | +| Purple ๐ŸŸช | Run 2 | +| Red ๐ŸŸฅ| Run 3 | +| Yellow ๐ŸŸจ| Run 4 | +| Blue ๐ŸŸฆ| Run 5 | +| Orange ๐ŸŸง| Run 6 | --- @@ -130,14 +129,8 @@ This project is licensed under GPL-3.0 - see the [LICENSE](LICENSE) file for com ## Contact & Support -**Team 65266 Lego Dynamics** +**Team 65266 - Lego Dynamics** Questions about our approach? Interested in collaboration? Reach out! ---- - -
- -Star this repo if you found it helpful! - -
\ No newline at end of file +--- \ No newline at end of file From 33b926cb1f39615382e743f7fcc03aa90ad5830c Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Tue, 28 Oct 2025 18:06:44 +0000 Subject: [PATCH 90/96] Upload files to "/" --- Screenshot 2025-10-28 1.06.30 PM.png | Bin 0 -> 878 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 Screenshot 2025-10-28 1.06.30 PM.png diff --git a/Screenshot 2025-10-28 1.06.30 PM.png b/Screenshot 2025-10-28 1.06.30 PM.png new file mode 100644 index 0000000000000000000000000000000000000000..44fad26fd8c9a90a630eb6545deacb1c9e8d6435 GIT binary patch literal 878 zcmV-!1CjiRP)0tEAWM-if2hMU&XT|;PbxXAA6PUuvgg*epWdG0|}94m9VJw?NBOpmofk4vVJ_T_nW(=)m#h=ISiWOqO;O%afwR03Rym(Eu-xYlfG*$6s6 zTF%QZ$r61$M8FJ1Rq*es*e8`}N)$)7ZxS+iuA!@H9vX|YQ)1hT{wN&}UdUMn@{S5n=StRAG(kj_S49s#lJ>_m~VuQ$=%6>7%yE89i8wuBxV2eW!0X ze;pYIW@xGUJoGE8va#*`0N}uV)%cXI_+i`4XD>}=Y=;k*RYsG!QrU}=P#9pvSruAr zXvv|42Ly0X^<{W0r>Yel3_uL4Ra)Kb#mDW}o4O4qGmykm6}n8(m74$H`IvSZ$YZ0b zt8ehcjfPL(M}RG4tGB Date: Tue, 28 Oct 2025 18:07:08 +0000 Subject: [PATCH 91/96] Delete Screenshot 2025-10-28 1.06.30 PM.png --- Screenshot 2025-10-28 1.06.30 PM.png | Bin 878 -> 0 bytes 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 Screenshot 2025-10-28 1.06.30 PM.png diff --git a/Screenshot 2025-10-28 1.06.30 PM.png b/Screenshot 2025-10-28 1.06.30 PM.png deleted file mode 100644 index 44fad26fd8c9a90a630eb6545deacb1c9e8d6435..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 878 zcmV-!1CjiRP)0tEAWM-if2hMU&XT|;PbxXAA6PUuvgg*epWdG0|}94m9VJw?NBOpmofk4vVJ_T_nW(=)m#h=ISiWOqO;O%afwR03Rym(Eu-xYlfG*$6s6 zTF%QZ$r61$M8FJ1Rq*es*e8`}N)$)7ZxS+iuA!@H9vX|YQ)1hT{wN&}UdUMn@{S5n=StRAG(kj_S49s#lJ>_m~VuQ$=%6>7%yE89i8wuBxV2eW!0X ze;pYIW@xGUJoGE8va#*`0N}uV)%cXI_+i`4XD>}=Y=;k*RYsG!QrU}=P#9pvSruAr zXvv|42Ly0X^<{W0r>Yel3_uL4Ra)Kb#mDW}o4O4qGmykm6}n8(m74$H`IvSZ$YZ0b zt8ehcjfPL(M}RG4tGB Date: Tue, 28 Oct 2025 18:11:19 +0000 Subject: [PATCH 92/96] Update README.md --- README.md | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 298ed1d..ef5a38b 100644 --- a/README.md +++ b/README.md @@ -72,12 +72,14 @@ Repository - Bluetooth button looks like this: ![alt text](https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed/raw/branch/do-not-merge/bluetooth.png) -3. **Upload to Robot** - - Click "Download and Run" or send the program to the robot +3. **Upload to Robot** - Click "Download and Run" or send the program to the robot + - Run button looks like this: ![alt text](https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed/raw/branch/do-not-merge/run.png) + 4. **Start Your Run** - - Hold a colored LEGO brick up to the color sensor - - Different colors trigger different mission runs! + - If starting without Pybricks, press the center circular button on the SPIKE Prime Hub to start the program. + - Hold a colored LEGO brick up to the color sensor. + - Different colors trigger different mission runs - color mapping is below. ### Color Start System | Color | Mission | From bb95852bf1a00f16e42bf220dca0b6521b33ec2e Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Tue, 28 Oct 2025 18:22:25 +0000 Subject: [PATCH 93/96] Update README.md --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index ef5a38b..1082a39 100644 --- a/README.md +++ b/README.md @@ -64,6 +64,10 @@ Repository ### Installation & Deployment - from the server - everyday 1. Download the file codes_for_scrimmage/hazmat/mainhazmatUPD.py + - You can do this through the repo, by using cURL, or by using git. + - Repo - Go to [codes_for_scrimmage/hazmat/mainhazmatUPD.py](codes_for_scrimmage/hazmat/mainhazmatUPD.py) and click the "Download" button. + - cURL or another HTTP data transferrer - curl -o mainhazmatUPD.py https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed/raw/branch/main/codes_for_scrimmage/hazmat/mainhazmatUPD.py + - git CLI - git clone -b dev https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed.git && cd solutions_season_unearthed/codes_for_scrimmage/hazmat - Then use mainhazmatUPD.py. 2. Open https://code.pybricks.com/ and select the "Import a file" button on the top of the left bar. Import the .py file. Pair your robot via Bluetooth in Pybricks by selecting the Bluetooth button. From 8ccf8b9a5a70ab667628a277731fe6104ae542e9 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Thu, 30 Oct 2025 12:21:46 +0000 Subject: [PATCH 94/96] Update README.md --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 1082a39..b0ef79a 100644 --- a/README.md +++ b/README.md @@ -66,8 +66,10 @@ Repository 1. Download the file codes_for_scrimmage/hazmat/mainhazmatUPD.py - You can do this through the repo, by using cURL, or by using git. - Repo - Go to [codes_for_scrimmage/hazmat/mainhazmatUPD.py](codes_for_scrimmage/hazmat/mainhazmatUPD.py) and click the "Download" button. - - cURL or another HTTP data transferrer - curl -o mainhazmatUPD.py https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed/raw/branch/main/codes_for_scrimmage/hazmat/mainhazmatUPD.py - - git CLI - git clone -b dev https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed.git && cd solutions_season_unearthed/codes_for_scrimmage/hazmat - Then use mainhazmatUPD.py. + - cURL or another HTTP data transferrer - + ```curl -o mainhazmatUPD.py https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed/raw/branch/main/codes_for_scrimmage/hazmat/mainhazmatUPD.py``` + - git CLI - + ```git clone -b dev https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed.git && cd solutions_season_unearthed/codes_for_scrimmage/hazmat``` - Then use mainhazmatUPD.py. 2. Open https://code.pybricks.com/ and select the "Import a file" button on the top of the left bar. Import the .py file. Pair your robot via Bluetooth in Pybricks by selecting the Bluetooth button. @@ -119,9 +121,7 @@ Team members can contribute by: **GNU General Public License v3.0** -``` You can take inspiration from our code, but you can't take our exact code. -``` This project is licensed under GPL-3.0 - see the [LICENSE](LICENSE) file for complete details. From a6bbba94192417459685d0ba00643bd6ff5ffd53 Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Thu, 30 Oct 2025 15:42:31 +0000 Subject: [PATCH 95/96] Update README.md --- README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index b0ef79a..5187815 100644 --- a/README.md +++ b/README.md @@ -67,9 +67,13 @@ Repository - You can do this through the repo, by using cURL, or by using git. - Repo - Go to [codes_for_scrimmage/hazmat/mainhazmatUPD.py](codes_for_scrimmage/hazmat/mainhazmatUPD.py) and click the "Download" button. - cURL or another HTTP data transferrer - + ```curl -o mainhazmatUPD.py https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed/raw/branch/main/codes_for_scrimmage/hazmat/mainhazmatUPD.py``` - git CLI - - ```git clone -b dev https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed.git && cd solutions_season_unearthed/codes_for_scrimmage/hazmat``` - Then use mainhazmatUPD.py. + + ```git clone -b dev https://codes.fll-65266.org/FLL_65266_LEGO_DYNAMICS/solutions_season_unearthed.git && cd solutions_season_unearthed/codes_for_scrimmage/hazmat``` + + Then use mainhazmatUPD.py. 2. Open https://code.pybricks.com/ and select the "Import a file" button on the top of the left bar. Import the .py file. Pair your robot via Bluetooth in Pybricks by selecting the Bluetooth button. From e785a8ad05f57cd4fe35b9d8168cd30fa00aa2bf Mon Sep 17 00:00:00 2001 From: Atharv <30nagava@elmbrookstudents.org> Date: Thu, 30 Oct 2025 15:42:53 +0000 Subject: [PATCH 96/96] Delete HEAVY_LIFTING_UPD we dont need it it is alr in missions/ --- HEAVY_LIFTING_UPD | 33 --------------------------------- 1 file changed, 33 deletions(-) delete mode 100644 HEAVY_LIFTING_UPD diff --git a/HEAVY_LIFTING_UPD b/HEAVY_LIFTING_UPD deleted file mode 100644 index da0f004..0000000 --- a/HEAVY_LIFTING_UPD +++ /dev/null @@ -1,33 +0,0 @@ -from pybricks.hubs import PrimeHub -from pybricks.pupdevices import Motor, ColorSensor, UltrasonicSensor, ForceSensor -from pybricks.parameters import Button, Color, Direction, Port, Side, Stop -from pybricks.robotics import DriveBase -from pybricks.tools import wait, StopWatch -from pybricks.tools import run_task, multitask - -hub = PrimeHub() - -left_motor = Motor(Port.A, Direction.COUNTERCLOCKWISE) -right_motor = Motor(Port.B) - -left_arm = Motor(Port.C, Direction.COUNTERCLOCKWISE) -right_arm = Motor(Port.D) -drive_base = DriveBase(left_motor, right_motor, wheel_diameter=68.8, axle_track=180) -drive_base.settings(600,500,300,200) -drive_base.use_gyro(True) - -async def main(): - await drive_base.straight(200) - await drive_base.turn(-20) - await drive_base.straight(536) - await drive_base.turn(60, Stop.HOLD) - await drive_base.straight(30) - - await right_arm.run_angle(5000,3000) - await drive_base.straight(40) - await right_arm.run_angle(5000,-4000) - await drive_base.straight(-60) - - await drive_base.turn(-60) - await drive_base.straight(-670) -run_task(main()) \ No newline at end of file