Microchip logo
  • All
  • Products
  • Documents
  • Applications Notes

8-Bit MCUs

Custom Logic on PIC® and AVR® Microcontrollers

What is a CCL or CLC?

Through logic gates, systems can make decisions based on criteria without Central Processing Unit (CPU) intervention.  Traditionally, these logic gates are manually implemented as external components, however the AVR® and PIC® microcontrollers (MCUs) offer this as a built in functionality to save cost and application space. 

The on-chip Configurable Logic Cell (CLC) peripheral on PIC® MCUs and Configurable Custom Logic (CCL) peripheral on AVR® MCUs eliminates the need for external components and complicated design work. With these on-chip peripherals, you can apply customized logic without physically expanding your application’s size.

If your design changes during the development process, your logic can be easily reconfigured with MPLAB Code Configurator or Atmel START.

How does my design benefit from the CCL and CLC?

With custom logic peripherals, you can apply combinatorial and sequential logic to both internal and external signals. This bypasses the CPU through hardware-based logic, and also automates task handling within your system.

How are they used?

Configurable Logic Cell on PIC MCUs

The CLC has a variety of basic gates as well as sequential logic options that can be customized to create the logic specific to your application. Through these logic gates, the CLC gives you the ability to combine signals to make a new custom signal without running code to execute it. This peripheral can also be used for routing pins on the microcontroller. For instance, you can easily configure the CLC peripheral to route the incoming RX signal of a connected Bluetooth® module to the virtual TX pin of your development board.

Configurable Custom Logic on AVR MCUs

The CCL on AVR microcontrollers has the ability to function as a simple logic gate, flip flop, delay element, filter or latch. You can also build your own custom gates through the lookup table. The lookup table behaves like a programmable truth table and features the ability to set the output of your gate based on entered values or an entered expression such as (!a * b + c). The results of the CCL can be used to trigger other peripherals as well without any CPU intervention.