Interface LCD with SAM L22 MCU Tutorial: Step 2

Step 2.1: Add SLCD, RTC and DMA drivers


Under Advanced Software Framework (ASF) Wizard, select 'saml22_slcd_lab' from the 'Project' drop-down menu. This shows the available and the default selected ASF modules.

Click image to enlarge.


Select 'Drivers' from the 'Show' drop-down list. select and add 'SLCD - Segment Liquid Crystal Display controller(driver)'.


The SLCD Module enables to access the drivers for segment LCD.


Similarly select and add 'RTC - Real Time Counter Driver (driver)' and 'DMAC - Direct Memory Access Controller(driver)'.
Configure RTC in 'count_callback' mode and SLCD in 'polling' mode.

  • RTC module is enabled to maintain the time instance between sleep and wakeup mode.
  • DMAC enables data transfer from source memory to the LCD peripheral and used in this training for scrolling feature.

Step 2.2: Add Delay routines services

Select 'Services' from the 'Show' drop-down list.

Select and add 'Delay routines (service)'.


The delay system service is used for performing delay operations.

Step 2.3: Verify that the board specific modules are added automatically

The PORT, Generic board support and System drivers will be automatically added to the project based on the selected board (in this case SAML22 Xplained Pro Evaluation Kit).


Verify whether the board specific modules are added or not.


Board support package, Clocks and GPIO's are configured based on the selected Evaluation board.


Click Apply to add the selected ASF modules to the project.


While the added modules are being applied to the project, if an information dialog box prompts, indicating the modules added, click on the OK button.


Instead of selecting the ASF modules from the drop down list, you may also find and add the required module by typing the name in the search text box.


Step 2.4: Verify the added modules

On the right pane, click on the 'Solution Explorer' and observe that the source files for the selected modules are added to the project.


Next Step >

© 2024 Microchip Technology, Inc.
Notice: ARM and Cortex are the registered trademarks of ARM Limited in the EU and other countries.
Information contained on this site regarding device applications and the like is provided only for your convenience and may be superseded by updates. It is your responsibility to ensure that your application meets with your specifications. MICROCHIP MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND WHETHER EXPRESS OR IMPLIED, WRITTEN OR ORAL, STATUTORY OR OTHERWISE, RELATED TO THE INFORMATION, INCLUDING BUT NOT LIMITED TO ITS CONDITION, QUALITY, PERFORMANCE, MERCHANTABILITY OR FITNESS FOR PURPOSE. Microchip disclaims all liability arising from this information and its use. Use of Microchip devices in life support and/or safety applications is entirely at the buyer's risk, and the buyer agrees to defend, indemnify and hold harmless Microchip from any and all damages, claims, suits, or expenses resulting from such use. No licenses are conveyed, implicitly or otherwise, under any Microchip intellectual property rights.