Hi!
I cannot find a way how to fetch the data of button events. This is
the Java code I want to write in F#.
int event = Button.waitForAnyEvent();
switch (event)
{
case UP_Press:
forward(pen);
break;
case DOWN_Press:
reverse(pen);
break;
case UP_Release:
case DOWN_Release:
stop(pen);
break;
case RIGHT_Press:
forward(assembly);
break;
case LEFT_Press:
reverse(assembly);
break;
case RIGHT_Release:
case LEFT_Release:
stop(assembly);
break;
case CENTER_Press:
flag = false;
}
let event = MonoBrickFirmware.UserInput.ButtonEvents()
how should I find the same data in monobrick library?
Follow