Comments (10)
@apoll2000 good finding. It seems to be an async functions, so I need listen to the RSSI event, and then update the value internally, so that Arduino can read it.
Not a trivial change, but I'll think what's the best way to integrrate it into BP32
from bluepad32.
could you be more specific ? which platform ? use case ? etc ( https://tinyurl.com/bluepad32-help )
from bluepad32.
I'm using an ESP32 Dev kit and an Android TV Game controller.
BTstack can get the RSSI value, but how do I get the RSSI value when using Bluepad32?
I would like to check the Bluetooth signal quality by checking the Received Signal Strength Indicator.
from bluepad32.
I guess are you using Arduino, correct ?
I guess I can put that info in uni_bt_conn
... and you should be able to get that info.
But I'd like to understand the use case a bit more.... what do you plan to do with the RSSI ? close the connection if not strong enough ? inform the user ?... the more details you add, easier for me to implement a feature that would be useful for you
from bluepad32.
I would like to record the rssi when input lag is measured.
from bluepad32.
Hi, this feature would also be really helpful for me. I am using a PS5 controller as a remote controller with an ESP32 running the bluepad32 arduino library, and reading out the RSSI would be useful as a safety feature so that a drop in signal strength can be detected.
Is it possible to access the RSSI somehow? Thank you very much in advance!
from bluepad32.
@apoll2000 as a safety measure you can do something similar to what I described here:
#45 (comment)
Regarding RSSI, the entire BTstack API is avaiable for Arduino users... you can call any API.
Wondering what is the API that returns the RSSI... I know the RSSI appears for BR/EDR connections when they advertise...
Not sure how to get it runtime... but if BTstack has that API, then you should be able to call it.
You might need the connection handle
, which is not available to the Arduino API, but I can expose it so you can use.... if you can tell me which BTstack API you need to call, I can provide the needed arguments for that API
from bluepad32.
Thank you very much for your quick response, I had to read into everything a bit to understand.
The RSSI readout is implemented in the BTStack GAP API, with the function int gap_read_rssi(hci_con_handle_t con_handle)
, and it indeed requires the connection handle (function listed here in the documentation).
It would be great if you could help me access that from within Arduino.
Also just wanted to say thank you for this great library, it's already helping me a lot!
from bluepad32.
I've just added some changes so that this issue can be mitigated:
BP32.update()
returns whether data has been received in any of the controllers.Controller.hasData()
returns whether data has been received sinceBP32.update()
was called.
Sketch updated:
https://github.com/ricardoquesada/esp-idf-arduino-bluepad32-template/blob/develop/main/sketch.cpp#L274
from bluepad32.
Thank you for this, the update()
method seems to solve exactly the issue I was having when data did not come through.
from bluepad32.
Related Issues (20)
- ESP32 Pico D4 support HOT 2
- bluepad32 arduino library should be open source HOT 3
- Dualsense PS5 controller bluetooth range? HOT 3
- Add setFlash option for Dualsense RGB LED HOT 2
- Timeout selection need for disconnected controller HOT 2
- PS4 esp32 HOT 3
- Add improved Rumble API: weak / strong magnitude, delayed start, and duration in ms HOT 1
- Arduino Nano ESP32 / Lolin S3 mini: Serial output not working HOT 3
- [Bug]: 8bitdo controllers go into constant rumble with new play_dual_rumble API HOT 25
- [Bug]: Pico SIGTRAP in Switch IMU parsing
- Filter gamepad connection HOT 2
- [Bug]: erro ao baixar pacote de placas HOT 7
- [Bug]: Failed to disconnect HIDS client for hids_cid=0, status=2 HOT 1
- [Bug]: 4.0.2 reports weird 99.99.99 version after flashing HOT 6
- [Bug]: More than three Xboxone handles will cause problems HOT 15
- [Bug]: Xbox One controller hangs on pairing HOT 8
- [Bug]: Warning message when Gamesir T3s connects HOT 1
- ESP32-C3 does not found Switch / 8Bitdo Controller but XBOX Wireless Controller HOT 3
- SDK Config Parameter for Analog->Digital presses HOT 1
- SDK parameter to control button remapping by position or lettering HOT 1
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 bluepad32.