Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pygatt does not connect to Raspberry Pi 4 BLE peripherals #349

Open
ojazdowski opened this issue Jun 18, 2024 · 0 comments
Open

pygatt does not connect to Raspberry Pi 4 BLE peripherals #349

ojazdowski opened this issue Jun 18, 2024 · 0 comments

Comments

@ojazdowski
Copy link

ojazdowski commented Jun 18, 2024

'patterns': [r'Connection successful.*\[LE\]>']

pygatt can not connect to Raspberry Pi 4 BLE peripheral on account of a connected callback string compare error in gattool.py

If you change the callback string in gattool.py

From THIS:

'connect': {
	                'patterns': [r'Connection successful.*\[LE\]>']
	            },

To THIS:

	'connect': {
	                'patterns': [r'Connection successful']
	            },

.... it will work.

( if pip installed you can edit the installed file rather than the source library to test: ~lib/python3.9/site-packages/pygatt/backends/gatttool/gatttool.py )

$ cat /sys/firmware/devicetree/base/model
Raspberry Pi 4 Model B Rev 1.5

$ cat /etc/os-release
PRETTY_NAME="Debian GNU/Linux 11 (bullseye)"
NAME="Debian GNU/Linux"
VERSION_ID="11"
VERSION="11 (bullseye)"
VERSION_CODENAME=bullseye
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant