abcminiuser / lufa

LUFA - the Lightweight USB Framework for AVRs.
http://www.lufa-lib.org
1.04k stars 325 forks source link

AVR8: Add option to keep 3.3V regulator enabled #16

Closed hansmi closed 10 years ago

hansmi commented 10 years ago

The documentation contains sample code on how to restart into the bootloader. In the process of preparing for the reset, USB is disabled using “USB_Disable()”. For hardware making use of the AVR8's internal 3.3V regulator that call would also disable the regulator, resetting the processor immediately rather than setting the boot key and letting the watchdog reset the processor.

This patch adds a new flag to be given to “USB_Init()” or to be defined in “USE_STATIC_OPTIONS” telling “USB_Disable()” to keep the regulator enabled.

On November 1st, 2013 this issue was already mentioned on the mailing list, but no fix came from that discussion.

abcminiuser commented 10 years ago

Very nice, thanks! Can I have a name please for the changelog?

abcminiuser commented 10 years ago

Never mind - found it on your site. Thanks again!