diff options
Diffstat (limited to '.pio/libdeps/esp32-s3-n16r8/ESP32 BLE Mouse/examples/MouseButtons')
| -rw-r--r-- | .pio/libdeps/esp32-s3-n16r8/ESP32 BLE Mouse/examples/MouseButtons/MouseButtons.ino | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/.pio/libdeps/esp32-s3-n16r8/ESP32 BLE Mouse/examples/MouseButtons/MouseButtons.ino b/.pio/libdeps/esp32-s3-n16r8/ESP32 BLE Mouse/examples/MouseButtons/MouseButtons.ino new file mode 100644 index 0000000..2859377 --- /dev/null +++ b/.pio/libdeps/esp32-s3-n16r8/ESP32 BLE Mouse/examples/MouseButtons/MouseButtons.ino @@ -0,0 +1,45 @@ +/** + * This example turns the ESP32 into a Bluetooth LE mouse that continuously moves the mouse. + */ +#include <BleMouse.h> + +BleMouse bleMouse; + +void setup() { + Serial.begin(115200); + Serial.println("Starting BLE work!"); + bleMouse.begin(); +} + +void loop() { + if(bleMouse.isConnected()) { + Serial.println("Left click"); + bleMouse.click(MOUSE_LEFT); + delay(500); + + Serial.println("Right click"); + bleMouse.click(MOUSE_RIGHT); + delay(500); + + Serial.println("Scroll wheel click"); + bleMouse.click(MOUSE_MIDDLE); + delay(500); + + Serial.println("Back button click"); + bleMouse.click(MOUSE_BACK); + delay(500); + + Serial.println("Forward button click"); + bleMouse.click(MOUSE_FORWARD); + delay(500); + + Serial.println("Click left+right mouse button at the same time"); + bleMouse.click(MOUSE_LEFT | MOUSE_RIGHT); + delay(500); + + Serial.println("Click left+right mouse button and scroll wheel at the same time"); + bleMouse.click(MOUSE_LEFT | MOUSE_RIGHT | MOUSE_MIDDLE); + delay(500); + + } +}
\ No newline at end of file |
