Article 4ST4Q Need help for bluetooth low energy (on Raspberry and ESP32)

Need help for bluetooth low energy (on Raspberry and ESP32)

by
jhel
from LinuxQuestions.org on (#4ST4Q)
Hi, I've got a Raspberry Pi 3 with Buster and I was trying to keep a BLE connection with my ESP32 (with the script I had before it connected just for the reading and then it disconnected) when I found this thread: https://www.linuxquestions.org/quest...ng-4175615328/.

So I ran this script:

Code:tmux new-session -d -s ServerFault 'sudo bluetoothctl -a |& tee /run/shm/BLUETOOTH_OUTPUT'
tmux send-keys -t ServerFault -l 'pair MAC_OF_MY_ESP32'
tmux send-keys -t ServerFault Enterbut after doing so, my ESP32's BLE characteristic for getting the data I need is now empty. I can't connect to the ESP32 neither by my phone (I used Serial Bluetooth Terminal, but now it shows "write descriptor failed" error when trying to connect) and I don't know how to come back to when it worked.

I tried to do
Code:tmux kill-server
tmux kill-session
tmux kill-session -t ServerFault
pkill -f tmuxbut it seems that no tmux session is open.
(the output is "no server running on /tmp/tmux-1000/default")

I don't know how could that command change something on ESP32, but the only commands I remember I ran other than that one are just those:

Code:sudo hciconfig hci0 reset
sudo invoke-rc.d bluetooth restart
hciconfig
hcitool scanCan you please help me?latest?d=yIl2AUoC8zA latest?i=tECSN97Bc-w:KspBy3tL2AQ:F7zBnMy latest?i=tECSN97Bc-w:KspBy3tL2AQ:V_sGLiP latest?d=qj6IDK7rITs latest?i=tECSN97Bc-w:KspBy3tL2AQ:gIN9vFwtECSN97Bc-w
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments