Comments (11)
Dear @jonathanrobichaud4
sry for the long answer delay, holiday time here :-).
We can support you as much as possible, but we do need some more infos.
- You can change the name of the ESP32 via the
$NAME xxx
command? - You can pair with the ESP32?
- How do you send the mouse/keyboard commands (other uC; terminal program;....)?
If the commands are processed ($NAME
, $ID
,...), the serial interface works as expected,
so should the HID commands.
Sending HID commands is done in this format:
https://github.com/asterics/esp32_mouse_keyboard#hid-input
But not in ASCII command format, but binary.
from esp32_mouse_keyboard.
The commands do work and I can pair with the esp just fine. Right now I am using a program named serial which is for Mac devices. I put it into the hex mode and tried to use it with the start bit and everything. "fd 00 00 73" kind of like that. I tried with the 0x in front of each as well. If you need anything else please let me know! I am writing this on my phone so it's a bit sparse sorry.
from esp32_mouse_keyboard.
Dear @jonathanrobichaud4
OK, thx for the infos. What about:
- What is the BT central device (PC/Notebook or mobile; which host OS)
- In many serial terminal programs, a
\r
or\n
are sent as well. This should be switched off in your program - What serial interface of the ESP32 is used (UART0 with the debug output or UART2)?
from esp32_mouse_keyboard.
It's an android device and I'm not sure what uart is in use. And I will check later today if my program sends the \r or \n.
from esp32_mouse_keyboard.
what program do you recommend for communication? Putty or some other windows specific one? I have a windows pc I can fire up as well. How can I tell what uart interface I am using. Right now I'm communicating through usb but can do the commands like $NAME as well as the demo ones
from esp32_mouse_keyboard.
Hi,
OK, Android devices should work without problem.
Regarding the UART: I think this is the source of your problem:
- We have 2 functions for parsing UART data:
and
esp32_mouse_keyboard/main/ble_hidd_demo_main.c
Line 1059 in 77103b7
uart_console_task
processes the data received from the UART0, which is the programming and debugging UART (connected via USB; normally used withidf.py flash/monitor
uart_external_task
processes the data from the second UART (pin 16/17 for RX&TX)- The console task does NOT implement the RAW HID commands. We just used this task for testing mouse/keyboard via the keys
w,a,s,d,c
for mouse andq
for keyboard.
Unfortunately, we didn't need the RAW HID for the UART0 (console_task), so it is not implemented.
A fast solution would be:
esp32_mouse_keyboard/main/ble_hidd_demo_main.c
Line 1077 in 77103b7
After this line, add
uart_parse_command(character,&commands);
And break the while(1) loop directly afterwards.
from esp32_mouse_keyboard.
I tried that out but it didn't help. when I tried sending commands I got a freertos error and the esp reset
from esp32_mouse_keyboard.
it says :
FreeRTOS: FreeRTOS Task "console" should not return, Aborting now!
from esp32_mouse_keyboard.
- Have you tried it without modification and sending w,s,a,d keystrokes to the ESP32? Does the mouse move accordingly?
- Did you use
break;
,return;
orcontinue;
after uart_parse_command?
from esp32_mouse_keyboard.
I tried a few different things but I just ended up using a different project that worked for what I needed it to do! Thanks for the help though!
from esp32_mouse_keyboard.
Dear @jonathanrobichaud4
I'm glad you find something that worked for you!
Anyway it would be nice if you give our project a star 👍
Good luck with your project,
greetings
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
- 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.