Skip to content

Conversation

h2zero
Copy link
Owner

@h2zero h2zero commented Nov 1, 2024

  • General code cleanup
  • NimBLEDevice::getInitialized renamed to NimBLEDevice::isInitialized.
  • NimBLEDevice::setPower no longer takes the esp_power_level_t and esp_ble_power_type_t, instead only an integer value in dbm units is accepted.
  • NimBLEDevice::setPower now returns a bool value, true = success.
  • NimBLEDevice::setMTU now returns a bool value, true = success.
  • NimBLEDevice::injectConfirmPIN renamed to NimBLEDevice::injectConfirmPasskey to use Bluetooth naming.
  • Fixes crash if NimBLEDevice::deinit is called when the stack has not been initialized.
  • Reverts 2db4756 as it would cause a crash when the NimBLEServer instance has a connection.
  • NimBLEDevice::getAddress will now return the address currently in use.
  • NimBLEDevice::init now returns a bool with true indicating success.
  • NimBLEDevice::deinit now returns a bool with true inidicating success.
  • NimBLEDevice::setDeviceName now returns a bool with true indicating success.
  • NimBLEDevice::setCustomGapHandler now returns a bool with true indicating success.
  • NimBLEDevice::setOwnAddrType now returns a bool with true indicating success.
  • NimBLEDevice::setOwnAddrType will now correctly apply the provided address type for all devices.
  • NimBLEDevice::setOwnAddrType no longer takes a bool nrpa parameter.

Fixes #724

@h2zero h2zero force-pushed the refactor-nimbledevice branch 5 times, most recently from cd3534e to aee31fb Compare November 1, 2024 21:05
* General code cleanup
* `NimBLEDevice::getInitialized` renamed to `NimBLEDevice::isInitialized`.
* `NimBLEDevice::setPower` no longer takes the `esp_power_level_t` and `esp_ble_power_type_t`, instead only an integer value in dbm units is accepted.
* `NimBLEDevice::setPower` now returns a bool value, true = success.
* `NimBLEDevice::setMTU` now returns a bool value, true = success.
* `NimBLEDevice::injectConfirmPIN` renamed to `NimBLEDevice::injectConfirmPasskey` to use Bluetooth naming.
* Fixes crash if `NimBLEDevice::deinit` is called when the stack has not been initialized.
* Reverts 2db4756 as it would cause a crash when the NimBLEServer instance has a connection.
* `NimBLEDevice::getAddress` will now return the address currently in use.
* `NimBLEDevice::init` now returns a bool with `true` indicating success.
* `NimBLEDevice::deinit` now returns a bool with `true` inidicating success.
* `NimBLEDevice::setDeviceName` now returns a bool with `true` indicating success.
* `NimBLEDevice::setCustomGapHandler` now returns a bool with `true` indicating success.
* `NimBLEDevice::setOwnAddrType` now returns a bool with `true` indicating success.
* `NimBLEDevice::setOwnAddrType` will now correctly apply the provided address type for all devices.
* `NimBLEDevice::setOwnAddrType` no longer takes a `bool nrpa` parameter.
@h2zero h2zero force-pushed the refactor-nimbledevice branch from aee31fb to d836b2c Compare November 1, 2024 21:41
Adds a utility to generate random BLE addresses and set the address used.
@h2zero h2zero merged commit 68b9e26 into master Nov 3, 2024
62 checks passed
@h2zero h2zero deleted the refactor-nimbledevice branch November 3, 2024 00:45
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

Successfully merging this pull request may close these issues.

Crash deinit(true)

1 participant