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

Reset source detection #6702

Closed
wants to merge 2 commits into from
Closed

Conversation

Duckle29
Copy link
Contributor

@Duckle29 Duckle29 commented Sep 8, 2019

Description

This PR adds an option to allow the keyboard to use a bootloader that checks if the reset source was by pulling the reset pin low, or if it wasn't. This allows the use of PE2 as a normal GPIO pin, as it doesn't have to be pulled low to enter bootloader.

Currently HWBE fuse bit is required. The HWBE fuse bit makes the ATMega32U4 enter the bootloader section if a reset occurs, and PE2 is low. Instead, with this change, one can use PE2 and then set the BOOTRST fuse bit, which makes the ATMega32U4 always boot into the bootloader, and then allowing the bootloader to check the source of the reset, and decide if it should jump straight to the main application, or if it should run the bootloader.

This shouldn't be merged before qmk/lufa#5, as it relies on that.

Types of Changes

  • Core
  • Bugfix
  • New feature
  • Enhancement/optimization
  • Keyboard (addition or update)
  • Keymap/layout/userspace (addition or update)
  • Documentation

Checklist

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • I have tested the changes and verified that they work and don't break anything (as well as I can manage).

Copy link
Contributor

@yanfali yanfali left a comment

Choose a reason for hiding this comment

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

Awesome detective work. LGTM

@drashna drashna self-requested a review September 21, 2019 18:25
@drashna drashna requested a review from a team September 21, 2019 18:25
@fauxpark
Copy link
Member

As discussed in qmk/lufa#5 I think this new define may not actually be necessary. I would also like to hear back from Dean in abcminiuser/lufa#150 about how the detection is supposed to work first.

@stale
Copy link

stale bot commented Nov 20, 2019

Thank you for your contribution!
This pull request has been automatically marked as stale because it has not had activity in the last 45 days. It will be closed in 30 days if no further activity occurs. Please feel free to give a status update now, or re-open when it's ready.

@drashna
Copy link
Member

drashna commented Oct 27, 2021

merge conflicts

@tzarc tzarc changed the base branch from master to develop June 17, 2022 22:46
@zvecr
Copy link
Member

zvecr commented Aug 29, 2022

This issue has been automatically closed because it has not had any recent activity.
If this issue is still valid, re-open the issue and let us know.

@zvecr zvecr closed this Aug 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants