5.2 Configuration

The ATmega328PB Xplained Mini board contains an on-chip mEDBG debugger(ATmega32U4) which provides 16MHz clock to the target ATmega328PB device. The target device prescales it by 2 to generate 8MHz device clock.

Figure 5-3. Clock Configuration
The modules used by this demo application are:
  • Timer0: Used to generate Software PWM output on GPIO to control LED brightness.
  • Timer2: Used to time the QTouch Library.
  • PTC: Used to scan capacitive touch sensors.