Skip to content

Commit 1e80f4f

Browse files
authored
Comment out ping block
Block isn't working so we are removing it for the approval
1 parent e742f89 commit 1e80f4f

File tree

1 file changed

+15
-15
lines changed

1 file changed

+15
-15
lines changed

cbcore.ts

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -344,21 +344,21 @@ namespace cyberbot {
344344
return read_r();
345345
}
346346

347-
/**
348-
* Sends a signal to the PING))) which sends out an ultrasonic sound wave and records the time it takes in microseconds for the signal to return then outputs either the time it takes or the distance depending on the units you choose
349-
* @param pin The cyberbot pin connected to the PING))), eg: ServoPin.Pin16
350-
* @param unit The units used for the distance measured
351-
*/
352-
//% blockId="cyberbot_ping" block="send ping on pin %pin measured in %unit"
353-
//% group="Sensors"
354-
//% weight=348
355-
export function ping(pin: ServoPin, unit: Units) {
356-
sendCommand(pin, null, PING_ECHO, 0, null, null);
357-
let d = read_r();
358-
if (unit == 1) { return d }
359-
else if (unit == 2) { return d / 148 }
360-
else { return d / 58 }
361-
}
347+
// /**
348+
// * Sends a signal to the PING))) which sends out an ultrasonic sound wave and records the time it takes in microseconds for the signal to return then outputs either the time it takes or the distance depending on the units you choose
349+
// * @param pin The cyberbot pin connected to the PING))), eg: ServoPin.Pin16
350+
// * @param unit The units used for the distance measured
351+
// */
352+
// //% blockId="cyberbot_ping" block="send ping on pin %pin measured in %unit"
353+
// //% group="Sensors"
354+
// //% weight=348
355+
// export function ping(pin: ServoPin, unit: Units) {
356+
// sendCommand(pin, null, PING_ECHO, 0, null, null);
357+
// let d = read_r();
358+
// if (unit == 1) { return d }
359+
// else if (unit == 2) { return d / 148 }
360+
// else { return d / 58 }
361+
// }
362362

363363
/**
364364
* Reads signals from an IR remote and returns a value equivalent of the button you pressed.

0 commit comments

Comments
 (0)