This extension is designed to programme and drive the NeZha micro:bit expansion board, You can get NeZha from the Elecfreaks store
input.onButtonPressed(Button.A, function () {
neZha.setMotorSpeed(neZha.MotorList.M1, 100)
neZha.setMotorSpeed(neZha.MotorList.M2, 100)
neZha.setMotorSpeed(neZha.MotorList.M3, 100)
neZha.setMotorSpeed(neZha.MotorList.M4, 100)
})
input.onButtonPressed(Button.B, function () {
neZha.setServoAngel(neZha.ServoList.S1, 119)
neZha.setServoSpeed(neZha.ServoList.S2, -58)
})
input.onButtonPressed(Button.AB, function () {
neZha.stopAllMotor()
})
basic.forever(function () {
})
- for PXT/microbit
MIT