Auto Bluetooth Accept

A few years later, I did this on Raspberry Pi 4B, maybe this can help someone.

Steps: 1.Make Pi's Bluetooth discoverable and pairable. Create a bluetooth-pair.sh file with content as below at /home/pi/AutoStart

sudo bluetoothctl <<EOF

discoverable on

pairable on

exit


2.Correct the Bluetooth spec file to make time limit to nolimit.

sudo nano /etc/bluetooth/main.conf


set timelimit to 0

DiscoverableTimeout = 0

PairableTimeout = 0


3.Let the bluetooth-pair.sh file to be run automatically when Pi starts. Correct /etc/rc.local Add

sudo sh /home/pi/AutoStart/bluetooth-pair.sh


before

exit 0


This works on Pi 4B normally.


https://raspberrypi.stackexchange.com/questions/47200/automatically-accepting-bluetooth-connections-on-a-pi-3