fushi

startingdefinitions.py

Dec 3rd, 2025 (edited)
2,781
0
Never
1
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.84 KB | None | 0 0
  1. #!/usr/bin/env pybricks-micropython
  2. from pybricks.hubs import EV3Brick
  3. from pybricks.ev3devices import (Motor, TouchSensor, ColorSensor,
  4.                                  InfraredSensor, UltrasonicSensor, GyroSensor)
  5. from pybricks.parameters import Port, Stop, Direction, Button, Color
  6. from pybricks.tools import wait, StopWatch, DataLog
  7. from pybricks.robotics import DriveBase
  8. from pybricks.media.ev3dev import SoundFile, ImageFile
  9. from pybricks.media.ev3dev import Font
  10.  
  11. ev3 = EV3Brick()
  12. left_thing_that_runs = Motor(Port.C)
  13. right_motor = Motor(Port.B)
  14. sacrifice = Motor(Port.A) # Third evil motor that does usually nothing
  15. creek4win = DriveBase(left_thing_that_runs, right_motor, wheel_diameter=57.15, axle_track=88.9)
  16.  
  17. # This file entirely exists because the presets stay the same basically all the time. It's only useful for new programs.
Advertisement
Comments
  • User was banned
Add Comment
Please, Sign In to add comment