Atmel | START Project Overview in Atmel Studio

This section will provide a walk-through of the Atmel | START project generated in Atmel | START Project Creation. The generated project contains peripheral driver functions and files, as well as main() function that initializes all drivers included in the project.

Figure 1. Project Overview
Info: The main window, as seen in Figure 1, shows the generated code for the main.c file. On the right side is the Solution Explorer window, which contains the folders and files generated by Atmel | START:
Todo: Get to know the structure of the Atmel | START project.
  1. Open the main.c file, by double-clicking it from the Solution Explorer window.
  2. Go to the implementation of atmel_start_init() by
    1. Hover over atmel_start_init().
    2. Right-click → Goto Implementation
      Info: A menu, showing the different locations, will appear.
    3. Jump to where the function is implemented by selecting the first option from the menu.
    4. right-clicking → Goto Implementation
  3. Go to the implementation of system_init() by
    1. Hover over system_init().
    2. Right-click → Goto Implementation
      Info: A menu, showing the different locations, will appear.
    3. Jump to where the function is implemented by selecting the first option from the menu.
      Info: The implementation of system_init(), as shown in Figure 2, should now be visible in Atmel Studio's editor window.
    Figure 2. system_init() Function
    Info:
    • The function mcu_init() enables the internal pull-up resistor on all pins to reduce power consumption.
    • All driver initialization functions are called from the system_init() function.
    • All the module initialization functions can be right-clicked in the same way as described above to see how each module is initialized. For example, ADC_0_initialization() and USART_0_initialization() configures the pins and initializes the registers for the ADC and USART module respectively.
  4. Go to the implementation of USART_0_initialization() by
    1. Hover over USART_0_initialization().
    2. Right-click → Goto Implementation
      Info: A menu, showing the different locations, will appear.
    3. Jump to where the function is implemented by selecting the first option from the menu.
      Info: The implementation of USART_0_initialization(), as shown in Figure 3, should now be visible in the Atmel Studio editor window.
    Figure 3. USART_0_initialization() Function
    Figure 3 shows the initialization code for the USART module, where the PB2 and PB3 pins are configured for the TX and RX transmission.
    Note: In this training, only TX transmission is used.
Result: The Atmel | START project overview is completed.