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

[HELP] BLE Connector random address type #334

Closed
zwells opened this issue Jun 30, 2020 · 2 comments
Closed

[HELP] BLE Connector random address type #334

zwells opened this issue Jun 30, 2020 · 2 comments
Assignees

Comments

@zwells
Copy link

zwells commented Jun 30, 2020

Describe the issue
Configuring the ble connector, how do you set the addrType as random in the ble.json? Is there a .py file that needs to be modified?

I can't connect to my devices through bluepy unless specified as random address type.

Connector name (If you need help with some connector/converter):

  • BLE Connector

Versions (please complete the following information):

  • OS: [e.g. Ubuntu 18.04]
  • Thingsboard IoT Gateway version [e.g. 2.2.4]
  • Python version[e.g. 3.7]
@zwells
Copy link
Author

zwells commented Jun 30, 2020

I think I'll just need to manually insert it as a parameter like peripheral = Peripheral(MAC, "random") in the __get_services_and_chars(self): function in ble_connector.py

Will test and close if it resolves the issue.

@imbeacon
Copy link
Member

imbeacon commented Jul 1, 2020

Hi @zwells,

Thank you for your investigations. You are right, there was no addrType parameter. But I added it in commit bcb9b87 .
You can put parameter "addrType" into device configuration, near the MACAddress and the gateway will use it instead of public address type.

@imbeacon imbeacon closed this as completed Jul 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants