13 Commits

Author SHA1 Message Date
1dec912abb Update missions/tip the scale.py 2025-10-24 00:11:38 +00:00
9e0c82b26b Update missions/tip the scale.py 2025-10-23 00:52:26 +00:00
8008dafccf Add missions/tip the scale.py 2025-10-04 01:18:31 +00:00
6931731ae1 Update LINEUPS.md 2025-10-04 00:09:55 +00:00
d172c70fe2 THIS CODE IS OUTDATED!!! DO NOT USE!!! 2025-10-03 23:28:16 +00:00
efcc011733 Initial Commit 2025-10-03 23:16:03 +00:00
28bb3fa48c Merge pull request 'Pull from Vickram to dev' (#2) from Vickram_dev_ into dev
Reviewed-on: #2
2025-10-03 21:26:08 +00:00
7ba2453152 Merge pull request 'Pull from Johannes_Dev to dev' (#3) from Johannes_Dev into dev
Reviewed-on: #3
2025-10-03 21:25:54 +00:00
c690ae451b Update members/Vickram.txt 2025-09-29 02:15:06 +00:00
d309b0098f '{Johannes}' 2025-09-12 20:32:12 +00:00
37fb0a647e Add members/Ayaan.txt 2025-09-12 20:29:44 +00:00
e895fd1d2c Add members/Vickram.txt 2025-09-12 20:28:02 +00:00
70e09fb42b Add members/Carlos.txt 2025-09-12 20:27:44 +00:00
7 changed files with 71 additions and 0 deletions

15
LINEUPS.md Normal file
View File

@@ -0,0 +1,15 @@
# 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.

0
members/Ayaan.txt Normal file
View File

0
members/Carlos.txt Normal file
View File

7
members/Johannes Normal file
View File

@@ -0,0 +1,7 @@
I am Johannes
I am the building manager for the team. I like making art.
Parthiv, Diddy will touch you tonight.

1
members/Vickram.txt Normal file
View File

@@ -0,0 +1 @@
Hello my name is Vickram and I like coding and video games.

48
missions/tip the scale.py Normal file
View File

@@ -0,0 +1,48 @@
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(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.turn(-46.5) #ma din din din dun
await drive_base.turn(-40)
await drive_base.straight(900)
run_task(main())