AVR® Insights - Episode 9 - AVR MCU Memory Buffer Register: Double Buffered Registers | Videos
AVR® Insights - Episode 9 - AVR MCU Memory Buffer Register: Double Buffered Registers
https://github.com/MicrochipTech/avr_insights
Is your microcontroller PWM signal missing compare values and creating the wrong PWM output? Is the duty cycle randomly changing to 0 or 100%? You may need to use a Memory Buffer register, called Double buffered registers on AVR MCUs. These registers allow for safe change of the compare output in terms of period and duty cycle. This video includes an example that shows the accuracy of changing a pwm signal with and without the timing of the double buffered registers on AVR. Check out the example code below! These registers allow for safe change of the compare output in terms of period and duty cycle.
Documentation references
--------------------------------------------------------------
Atmel Tools Documentation:
https://mchp.us/2Jk2Wqy
AVR Libc reference manual:
https://mchp.us/2Q1gBTH
ATmega324PB datasheet:
http://ww1.microchip.com/downloads/en/DeviceDoc/40001908A.pdf#page=139
ATmega 324PB Xplained Pro User Guide:
http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-42633-ATmega324PB-Xplained-Pro_User-Guide.pdf