Comments (5)
Dear Sandric,
asking is never a crime :-).
A small clarification:
This project is used to trigger mouse and keyboard actions on a paired device. These mouse/keyboard actions are input to the ESP32 via the second serial interface (not the programming/debugging interface, which you used via 'make flash' or 'make monitor').
Just for basic testing, we also implemented following characters, which can be typed in via the 'make monitor' console (which is UART0 of the ESP32):
- 'w'/'a'/'s'/'d': move the mouse cursor
- 'l' click left
- 'r' click right
- 'q' type in keycode for "Y"
Note: these are just for testing, if you want to try full functionality, you have to attach something to UART1, using pins 16/17 (see config.h line 14/15). UART config is done in https://github.com/asterics/esp32_mouse_keyboard/blob/master/main/ble_hidd_demo_main.cpp#L599
and set to: 8N1 @ 9600baud
from esp32_mouse_keyboard.
Regarding an example:
This project sends mouse/keyboard action immediately after you put a struct into following queues (FreeRTOS related stuff, if this is new, please read their docs before proceeding):
- mouse_q for mouse actions
- keyboard_q for mouse actions
from esp32_mouse_keyboard.
For your example use case:
uint8_t output[] = "quick brown fox";
uint8_t i = 0;
while(output[i])
{
sendKey(output[i], PRESS_RELEASE);
//second option:
//sendKey(output[i], PRESS); //send a key press event (hold it until release is sent)
//sendKey(output[i], RELEASE); //release the key
i++;
}
from esp32_mouse_keyboard.
wow, thanks a lot, I reread main readme and realized second UART example, thanks a lot for your last example also, trying new things can be challenging at times but interesting.
from esp32_mouse_keyboard.
Don't worry, glad to help ;-)
I had my troubles too getting started with BLE/HOG/GAP/GATT/.......
from esp32_mouse_keyboard.
Related Issues (20)
- Enable / disable pairing+bonding HOT 2
- BLE - GATT transmission rate limiting HOT 2
- Enable notifications for LED reports HOT 2
- GATT_INSUF_AUTHENTICATION problem HOT 15
- Switch between devices/hosts HOT 4
- Deinit missing hidd_le_env.enabled = false; HOT 1
- Can't pair with Apple TV (4th generation) or iPhone 11 Pro Max -- esp32 doesn't even appear in list HOT 2
- How do you send key commands HOT 11
- iPhone 12 Pro iOS 14.7.1 - no devices in the list HOT 14
- help with HID braille for open source devices for people with disabilities HOT 5
- Compilation issue. HOT 3
- Connection indication LED does not work correctly HOT 1
- Automatic Firmware update not working HOT 1
- Pairing problems on Win8.1 HOT 2
- Replacement parts HOT 1
- How to swipe HOT 1
- How to get or set mouse position? HOT 2
- iOS 17 compatibility HOT 3
- Not showing on HID device in Windows 10 HOT 7
- ESP32-S3 support
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from esp32_mouse_keyboard.