Brown-out detection – Pololu A-Star 32U4 User Manual

Page 25

Advertising
background image

The startup logic for the A-Star 32U4 bootloader.

Brown-out detection

Unlike many other ATmega32U4 boards, the A-Stars have brown-out detection enabled. The brown-out threshold is
4.3 V, and if the voltage on VCC goes below this then the AVR will reset. The bootloader was designed so that the
user program can detect brown-out resets. To do so, check to see if the BORF bit in the MCUSR register is set, and
then clear it later. Here is some example code you could put in your

setup

function for detecting brown-out resets:

Pololu A-Star 32U4 User’s Guide

© 2001–2014 Pololu Corporation

7. The A-Star 32U4 Bootloader

Page 25 of 30

Advertising