Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
tballmsft committed Sep 27, 2023
2 parents 249f332 + 496c3e9 commit eb6ed09
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 36 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/makecode.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,5 @@ jobs:
run: |
cd robot
makecode
makecode -c mkc-cutebot.json
makecode -c mkc-yahboomtinybit.json
18 changes: 0 additions & 18 deletions robot/main.ts

This file was deleted.

1 change: 1 addition & 0 deletions robot/maincutebot.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
microcode.elecfreaksCuteBot.start()
1 change: 1 addition & 0 deletions robot/mainyahboomtinybit.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
microcode.yahboomTinyBit.start()
5 changes: 5 additions & 0 deletions robot/mkc-cutebot.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"overrides": {
"testFiles": ["maincutebot.ts"]
}
}
5 changes: 5 additions & 0 deletions robot/mkc-yahboomtinybit.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"overrides": {
"testFiles": ["mainyahboomtinybit.ts"]
}
}
27 changes: 9 additions & 18 deletions robot/test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,25 +3,16 @@ microcode.elecfreaksCuteBot.start()
//microcode.keyStudioMiniSmartRobot.start()
microcode.setMotorDrift(6)

const robotDriver = microcode.robotDriver
robotDriver.motorRun(60)
/*
basic.forever(() => {
robotDriver.motorRun(100)
pause(1500)
robotDriver.motorRun(-100)
pause(1500)
})
*/
/*
const dist = robotDriver.ultrasonicDistance()
if (dist > 5)
robotDriver.motorRun(100)
const dist = microcode.robotDriver.ultrasonicDistance()
if (dist > 10) microcode.robotDriver.motorRun(100)
else {
robotDriver.motorRun(-50)
microcode.robotDriver.motorStop()
microcode.robotDriver.motorRun(-50)
pause(400)
robotDriver.motorTurn(50)
pause(800)
microcode.robotDriver.motorStop()
microcode.robotDriver.motorTurn(50)
pause(400)
microcode.robotDriver.motorStop()
}
*/
})

0 comments on commit eb6ed09

Please sign in to comment.