-
Notifications
You must be signed in to change notification settings - Fork 108
reliable indicator for out of range? #28
Comments
no, i found out that i not get those error messages that often, when i already get lost the control of my toy, if i increade the delay value slightly in the main loop. so i try to see if i can look at the lastPacket if there is something like a timestamp that will change periodically. if it does not change anymore, then i am out of range and can ingage an emergency stop in my toy. |
@beta-tester can you share your source code? |
at the moment it is just the example code of PS4SendData.ino. i just changed the delay from 10 to 20 to 50 and with 50 didn't got the error messages that early as with a delay of 10 or 20, even i already lost the control and the rumble of the controller didn't followed the triggers L2 & R2 anymore until i steped closer to the ESP32 again.
|
hi,
at first, thank you for the great library!
i want to use this to remote control a toy car or robot.
i just tried out the example
PS4SendData.ino
and noticed, when i reach the maximum range of the bluetooth communication, i receive on the log the following message each time thePS4.sendToController()
method fails:then i realized that
PS4.isConnected()
is not a good indicator to see that i am just out of range with my PS4 controller, because it still givestrue
in that situation.using this error message would be mutch better as an indicator when i am just out of range.
unfortunately
PS4.sendToController()
isn't giving any return value/error code. would it be possible to pass through the error value so that it is possible to react to an error?or is there another better way to see when the PS4 controler is just out of range?
The text was updated successfully, but these errors were encountered: