Do you have a question about the AVR675 and is the answer not in the manual?
Questions and answers
Subscribe to Our Youtube Channel
Summary of Contents for Atmel AVR675
Page 1
APPLICATION NOTE Atmel AVR675: Configurable Three Phase BLDC Fan 8-bit AVR Microcontrollers Features • 3-phase BLDC fan application • Sensorless back EMF control algorithm • ® For Atmel ATtiny461A or Atmel ATtiny861A • Reference Design Hardware and Firmware • PC based Atmel Motor Control Configuration Utility •...
Stand Alone Fan Operation .............. 28 4. Conclusion ..................29 Appendix A. Schematics ..............30 Appendix B. Kit Parts List ..............32 Appendix C. Revision History ............33 Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
Motor Control Configuration Utility The Atmel Motor Control Configuration Utility is software running on a PC provided as a tool for configuring and tuning the fan application through setting parameters that are stored in the ATtiny’s EEPROM without the need to modify the firmware.
Three motor leads brought out for connection to the Configurable BLDC Fan Board. The fan shown in Figure 2-2 is rated for 12VDC input and 1.2A at 23,000rpm. Figure 2-2. Three phase BLDC Fan. Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
The USB to UART bridge cable provides communication between a PC and the Configurable BLDC Fan board. This cable is a standard product from FTDI. Part numbers are listed in Appendix Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
Figure 2-5. Universal Power Adapter with international plug options. Firmware The firmware was designed to run on the Atmel ATtiny461A or Atmel ATtiny861A to demonstrate a configurable motor control application for driving 3-phase BLDC fans. The sensorless control algorithm provides high speed operation above 50,000rpm for a 4-pole motor. The PLL is always enabled for robust operation that provides automatic recovery of the motor speed after a stall condition.
The PWM ISR serves three functions: timing for the main loop, reading the PWM speed command, and timing for UART communication. Because of the UART function, the PWM period is set to 19,200Hz to conform to standard PC UART speeds. Figure 2-7 shows the PWM ISR flow. Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
Page 8
DC bus voltage reference. Figure 2-8. ADC ISR. The relationship between the PWM ISR, the ADC ISR, and the up/down count sequence of timer 1 is depicted in Figure 2-9. Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
Page 9
Commutation ISR forms an asynchronous interrupt relative to the PWM ISR and ADC ISR. This is illustrated in Figure 2-11. Figure 2-10. Commutation ISR. Commutation ISR Update Commutation or Sample Back EMF Update TACH (when not in UART mode) RETURN Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
2-13. These conventions are used to be consistent with the markings typically found on a USB to UART Bridge. Figure 2-13. Configuration and tuning. Configurable BLDC UART Fan Board Bridge Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
A variable plot that allows watching a single variable in a scope like plotting window for performance testing. An oscillator test to compare and adjust the Atmel ATtiny461A internal oscillator against the UART clock. Simple file functions: A file load and save function for saving EEPROM values and a file save function to store plot data.
EEPROM “Program” button must be pressed. 2.3.5 File functions Additional file functions are there for configuring the utility, loading and saving parameters values, and saving variable plot data. Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
There are provisions for ISP downloads of firmware and fuse settings through the standard six pin header, P1 using many of the common programming tools and the latest version of Atmel Studio. Firmware can be installed using the following steps: Download the AVR Configurable 3-phase BLDC fan project.
Page 14
Bring up latest version of Atmel Studio, example is shown with Atmel Studio 6 at the time of this writing. If you are using a newer version of Atmel studio, start a new C project using the GCC compiler option and select the Atmel ATtiny461A.
The blue LED should blink as an indicator that the firmware is ready to use. Motor Control Configuration Utility Once the hardware is set up and the firmware is present in the Atmel ATtiny461A flash you are ready to run the Motor Control Configuration Utility.
USB Serial Port (COMx), where x is the port number. After selecting the COM port, the application configuration should be selected for AVR675. This presented the proper variable and parameter list labels in the Motor Control Configuration Utility.
Page 17
11. This can be used to freeze data on the plot area, to read variables, and for capturing data to be saved to a file. Figure 3-11. Data updates. When selecting a variable for plotting the selected variable location in the list, name and description are displayed in the Variable information window, Figure 3-12. Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
Variable select Current button value 3.3.3 Motor parameters The motor parameters are EEPROM values copied into RAM on power up of the Atmel ATtiny461A. Figure 3-14 shows the list of parameters. Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
Page 19
EEPROM until program button is pressed. The copy all buttons shown in Figure 3-15 provides a quick method to transfer all the variables between the Motor Control Configuration Utility and the ATtiny461A. Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
Page 20
3-18. The command can be directly modified using the input box on the right and then pressing the arrow key in the middle. Note: This only transfers the value to the RAM of the Atmel ATtiny461A and the program button still needs to be pressed to commit the RAM values to EEPROM. Figure 3-18. input_cmd direct input.
3-21. The internal oscillator is compared with the USB to UART cable oscillator which has an oscillator accuracy of better than 0.2%. See ATtiny461A Data Sheet for further details about oscillator calibration. Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
The first step in tuning the back EMF sensing PLL is to disable the speed control loop and use open loop PWM duty cycle control by setting mode to seven, Figure 3-25. Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
= timer software prescaler = 2 x speed_scale timer_period = 0xFFFF speed_count = numeric speed value = 0 to 255 timer_periods = 12 timer periods per electrical cycle (2 periods per state x 6 states) Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
Figure 3-27 shows the speed_count_min for the example fan, the value is usually in the range of 1 to 10. Figure 3-27. Minimum speed count. Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
Page 25
DC input voltage has reached the threshold. In the example of Figure 3-30 the start up voltage is set to approximately v_bus = 10V x 2k / (2k + 15k) /5V * 256 = 60 Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
An example of nonlinear mapping is shown in Figure 3-35. For linear mapping simple set command_0 = speed_cmd_0 = 0 and command_1 = speed_cmd_1 = 255 and set all remaining values to 255. Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
The EEPROM is now programmed. Next time the power is cycled the fan will power up with these settings. As long as power is supplied by the 12V input, serial communication will not be established and the Atmel ATtiny461 only accepts a PWM command.
This application note described the implementation and use of a configurable three-phase brushless DC (BLDC) fan using the Atmel ATtiny461A microcontroller implementing sensorless control. The complete hardware system includes a 12V three-phase BLDC fan, an Configurable BLDC Fan board, a USB to UART bridge cable, an AC power adapter, the firmware running on the ATtiny461A, and a PC based Motor Control Configuration Utility for customizing the fan for the application.
Revision History Appendix C. Doc. Rev. Date Comments 42016B 12/2012 Revision history added and some other updates/corrections have been performed 42016A 07/2012 Initial document release Atmel AVR675: Configurable Three Phase BLDC Fan [APPLICATION NOTE] 42016B−AVR−12/2012...
Page 34
Disclaimer: The information in this document is provided in connection with Atmel products. No license, express or implied, by estoppel or otherwise, to any intellectual property right is granted by this document or in connection with the sale of Atmel products. EXCEPT AS SET FORTH IN THE ATMEL TERMS AND CONDITIONS OF SALES LOCATED ON THE ATMEL WEBSITE, ATMEL ASSUMES NO LIABILITY WHATSOEVER AND DISCLAIMS ANY EXPRESS, IMPLIED OR STATUTORY WARRANTY RELATING TO ITS PRODUCTS INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT.
Need help?
Do you have a question about the AVR675 and is the answer not in the manual?
Questions and answers