Upload files to "hazmat_scrimmage"

This commit is contained in:
2026-10-20 23:14:14 +00:00
parent c6c117daf7
commit 81842d5a75
5 changed files with 175 additions and 0 deletions

View File

@@ -0,0 +1,29 @@
#####################################
# Solution for BioGlow Mission 12
#####################################
import bioglow_helpers as helper
from bioglow_robot_settings import * # drive_base, left_arm, right_arm, ... all come from settings
async def solve_missions(): # Forest Elder - Parthiv
await drive_base.straight(475)
await right_arm.run_angle(300,25)
await drive_base.turn(-20)
await left_arm.run_angle(200,245)
await drive_base.straight(60)
await drive_base.turn(25)
await left_arm.run_angle(100,-56.5)
await drive_base.straight(-50)
await drive_base.straight(50)
await drive_base.turn(-25)
await left_arm.run_angle(200,-200)
await drive_base.straight(-240)
await drive_base.turn(15)
await right_arm.run_angle(200,-200)
await drive_base.straight(-200)
await drive_base.stop
if __name__ == "__main__": # This run this mission stand-alone when not called from bioglow_main.py
run_task(solve_missions())

View File

@@ -0,0 +1,29 @@
#####################################
# Solution for BioGlow Mission 13
#####################################
import bioglow_helpers as helper
from bioglow_robot_settings import * # drive_base, left_arm, right_arm, ... all come from settings
async def solve_missions(): # Interchangeable Mission - Parthiv
await left_arm.run_angle(200,-80)
await drive_base.arc(-350,angle=90)
await drive_base.turn(50)
await drive_base.straight(238)
await drive_base.turn(-33)
await drive_base.straight(85)
await drive_base.straight(-33)
await multitask(
left_arm.run_angle(200,80),
right_arm.run_angle(200,-100)
)
await drive_base.straight(-60)
await right_arm.run_angle(200,100)
await drive_base.turn(30)
await drive_base.straight(-775)
await drive_base.stop
if __name__ == "__main__": # This run this mission stand-alone when not called from bioglow_main.py
run_task(solve_missions())

View File

@@ -0,0 +1,58 @@
#####################################
# Solution for BioGlow Mission 2
#####################################
import bioglow_helpers as helper
from bioglow_robot_settings import * # drive_base, left_arm, right_arm, ... all come from settings
async def solve_missions(): # Exploding Seeds - Johannes
drive_base.reset(0,0) # always reset drivebase for heading reset especially with turns
await multitask(
drive_base.arc(150,None,115),
left_arm.run_angle(300,40),
right_arm.run_angle(300,90)
)
# drive to mission until robot will stall
dist_to_model = 350
rev_move = -1 * dist_to_model
reach_mission = await helper.drive_until_stalled(dist_to_model)
if reach_mission:
print("Exploding seeds reach.Solving now...")
else:
print(f"Drove full {dist_to_model}, no stall")
await left_arm.run_angle(100,-40)
#await left_arm.run_until_stalled(-100, then=Stop.HOLD, duty_limit=5)
await drive_base.straight(-60)
await left_arm.run_angle(300,-90)
await multitask(
drive_base.straight(rev_move),
right_arm.run_angle(500,-90),
left_arm.run_angle(500,-80)
)
# Go towards tangled mission
helper.set_default_speed()
#helper.set_speed(600,200,100,100)
await drive_base.turn(-23)
await drive_base.straight(700,Stop.COAST) # move fast
#slowing down here
helper.set_speed(100,200,300,200)
await drive_base.straight(120)
await right_arm.run_angle(700,70) #raise arm to untangled
await drive_base.straight(-100,Stop.COAST) # moving back
helper.set_speed(800,500,300,200)
await multitask(
drive_base.straight(-800),
right_arm.run_angle(300,90)
)
drive_base.stop()
if __name__ == "__main__": # This run this mission stand-alone when not called from bioglow_main.py
run_task(solve_missions())

View File

@@ -0,0 +1,37 @@
#####################################
# Solution for BioGlow Mission 3,4,5
#####################################
import bioglow_helpers as helper
from bioglow_robot_settings import * # drive_base, left_arm, right_arm, ... all come from settings
async def solve_missions(): # Flip the rock,etc
drive_base.reset(0,0) # always reset drivebase for heading reset especially with turns
print (left_arm.angle(),right_arm.angle())
helper.set_speed(600,200,300,300)
await drive_base.straight(400,Stop.COAST)
helper.set_speed(800,300,300,300)
await drive_base.straight(100)
helper.set_speed(100,100,100,100)
await multitask(
right_arm.run_angle(100,-60),
left_arm.run_angle(100,60),
drive_base.straight(-60)
)
await multitask(
right_arm.run_angle(50,50),
left_arm.run_angle(50,-50),
drive_base.straight(-40)
)
helper.set_default_speed()
await drive_base.straight(-300)
await drive_base.straight(-100)
drive_base.stop()
if __name__ == "__main__": # This run this mission stand-alone when not called from bioglow_main.py
run_task(solve_missions())

View File

@@ -0,0 +1,22 @@
#####################################
# Solution for BioGlow Mission 8
#####################################
import bioglow_helpers as helper
from bioglow_robot_settings import * # drive_base, left_arm, right_arm, ... all come from settings
async def solve_missions(): # Research Platform - Johannes
await drive_base.arc(900,None,400)
await drive_base.arc(-500,None,250)
helper.set_speed(100,400,300,200)
await drive_base.straight(200)
await helper.multilift_up(1950)
await helper.multilift_down(500)
helper.set_speed(1000,500,300,200)
await drive_base.arc(-1000,None,-900)
await drive_base.stop
if __name__ == "__main__": # This run this mission stand-alone when not called from bioglow_main.py
run_task(solve_missions())