Skip to content

Conversation

aaronjamt
Copy link

@aaronjamt aaronjamt commented Jul 1, 2025

What's new

  • While booting, the Flipper Zero firmware resets the BQ25896 registers, disabling 3.3V output to any connected GPIO board. This PR enables the OTG register after the reset if it was enabled before, preventing the connected board from losing power and rebooting.

Verification

  • Reboot the Flipper Zero (hold Left and Back buttons) while a GPIO board (such as the WiFi Devboard) is connected. Without this commit, the Devboard will light the LED blue as it starts back up after losing power. With this commit, the Devboard does not react to the reboot.

Checklist (For Reviewer)

  • PR has description of feature/bug or link to Confluence/Jira task
  • Description contains actions to verify feature/bugfix
  • I've built this code, uploaded it to the device and verified feature/bugfix

@aaronjamt
Copy link
Author

aaronjamt commented Jul 1, 2025

Currently, this will always enable 3.3V during boot, whether it was previously enabled or not. I tried storing the value of the register before resetting and only enabling it if it was enabled before, but it was very inconsistent. If anyone has ideas for a better way to make it work, I'd greatly appreciate some help!
Edit: I've since figured this out and updated the PR accordingly. It will now only enable the OTG output during boot if it was already enabled.
Edit 2: I've also realized this applies to the 3.3V output, not the 5V output. Either way, this allows the WiFi devboard to be used wirelessly without losing connection when the Flipper reboots.

@Biggie420-D
Copy link

@aaronjamt aaronjamt changed the title Enable 5V output on boot Re-enable 5V output on reboot Jul 2, 2025
@aaronjamt aaronjamt changed the title Re-enable 5V output on reboot Re-enable 3.3V GPIO output on reboot Jul 3, 2025
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.

2 participants