Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Add function to manage low power mode status #327

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

Open
leonardocavagnis wants to merge 5 commits into arduino-libraries:master
base: master
Choose a base branch
Loading
from leonardocavagnis:ble_local_lp_mode

Conversation

Copy link
Contributor

@leonardocavagnis leonardocavagnis commented Oct 11, 2023
edited
Loading

Adding the function BLE.setLowPowerMode(bool) to manage the lower power mode status of the BLE chip.

The function BLE.setLowPowerMode(bool)(true: to enable, false: to disable) must be called before executing the BLE.begin() function. Using this function after the BLE stack initialization will not have any effect.
The function does not directly control the entry and exit from low power mode but enables or disables the chip's feature.

Low power mode is enabled by default.

@sebromero Check it out if function name sounds good. Another proposal could be using two different functions: enableLowPowerMode() and disableLowPowerMode().

This PR is based on the arduino/mbed-os PR #32.

Copy link
Contributor

@sebromero sebromero left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR! I'd recommend naming the user facing function setLowPowerModeEnabled or as discussed disableLowPowerMode() if re-enabling it makes no sense. For the other functions I suggest avoiding abbreviations that leave room for ambiguity.

leonardocavagnis reacted with thumbs up emoji
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@sebromero sebromero sebromero requested changes

@facchinm facchinm Awaiting requested review from facchinm

Assignees
No one assigned
Labels
topic: code Related to content of the project itself type: enhancement Proposed improvement
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

PMC freeze when using ArduinoBLE with Arduino_MachineControl included.

AltStyle によって変換されたページ (->オリジナル) /