We detect you are using an unsupported browser. For the best experience, please visit the site using Chrome, Firefox, Safari, or Edge. X

Embedded Software Development Framework for 32-bit Microcontrollers and Microprocessors


MPLAB® Harmony v3 is a fully integrated embedded software development framework that provides flexible and interoperable software modules to simplify the development of value-added features and reduce your product’s time to market.

To easily find the documentation and resources that you need to begin your application development, click on the icons in the diagram below:

Key Benefits of MPLAB Harmony v3


  • Core-agnostic implementation which supports both MIPS® and Arm® Cortex® core architectures
  • Code portability with consistent APIs that can be used across different device families
  • Easily configurable using MPLAB Harmony Configurator’s (MHC’s) Graphical User Interface (GUI)
  • Layered, self-contained and MIRSA-C:2012 Mandatory Standards-compliant* framework includes:
    • Peripheral libraries – Hardware Abstraction Layer
    • Drivers and services
    • Reusable middleware
  • Offers 1000+ demo/application examples
  • Validated across 32-bit PIC® (MIPS-based) and SAM (Arm Cortex-based) MCU and MPU device families
  • Fully Integrated with third-party solutions like FreeRTOS and Micrium® and able to import projects created in IAR Embedded Workbench 

*Please contact your local Microchip Sales Office to obtain the MISRA-C report.

Enhancements in MPLAB Harmony v3


  • Added support for SAM families of Arm Cortex-M based devices, including a free software development environment
  • Easy device and library setup using the graphical configuration features provided by MHC’s GUI
  • Optimized peripheral libraries to simplify device setup and peripheral usage
  • Modular software downloads and updates available through GitHub for better installation and configuration management
  • Default integration with FreeRTOS and capable of supporting other Real-Time Operating Systems (RTOSs)
  • Offers same great middleware as MPLAB Harmony v2
  • Supports multiple development models with application examples and demos
  • Graphics libraries support has been extended to multiple families of microcontrollers

Key Benefits for Arm Cortex-M Based SAM Device Families


  • Configuration of device and embedded software libraries using MHC, a GUI-based configurator integrated into MPLAB X IDE, provides a unified interface to all the features of the embedded software framework
  • Version control for software components
  • Simplified APIs that make it easy to integrate Peripheral Libraries (PLIBs) into any application
  • Provides comprehensive middleware library stacks and example software to support a wide variety of applications
    • Graphics libraries to drive OLED to WVGA+ displays
    • Free-to-use TCP/IP stack, no need for third-party software stack or support
    • Cloud connectivity available
    • Enhanced crypto support with wolfSSL, wolfSSH, wolfMQTT now available for free
    • Complete support for Bluetooth® libraries
    • Extensive motor control applications demo examples of sensored and sensorless control of Brushless DC (BDC) motors, Permanent Magnet Synchronous Motor (PMSMs) and AC Induction Motors (ACIMs)
  • Supports multiple RTOSs

Leveraging MPLAB Harmony v3 for SAM MPUs


  • MPLAB X IDE and MPLAB Harmony now support SAM MPUs
  • FreeRTOS support available
  • Seamless migration of your MCU-based application to a SAM MPU
  • Compile and configure MPU applications for free with MPLAB Harmony software development framework
  • Ability to import projects into other software development environments
  • Smaller code size

Port your Existing Applications from MPLAB Harmony v2.xx to MPLAB Harmony v3


Since MPLAB Harmony v3 contains the same middleware, driver and service interfaces or provides adapters for them, the code you created in MPLAB Harmony v2.xx should work without requiring that you make any changes. However, there may be some exceptions depending on the level of customization or direct use of peripheral libraries for your project. Here are some guidelines:

  • No porting effort should be necessary if interface abstractions were not violated and only common features were used
  • Drivers and services were re-implemented to support SAM devices:
    • Updates may be required to take advantage of additional features of SAM devices
    • Updates may be required for code using features not supported on SAM devices
  • Code using MPLAB Harmony v2 PLIBs directly will have to be re-implemented:
    • PLIB interfaces may not be identical from version-to-version or from device-to-device
    • Only drivers and services (or higher-level libraries) provide interface consistency across different devices (if the feature used is supported) and across minor releases
    • Interface changes may occur in driver, service, and middleware libraries if a major release’s version number changes, but ease of migration will be a priority
    • For maximum portability and reusability, the MPLAB Harmony team recommends using the library with the highest level of abstraction that provides the needed capabilities

Getting Started with MPLAB Harmony v3


Repository

Description


Audio

Audio Library: This repository contains a variety of audio drivers, encoders, decoders, and firmware projects that demonstrate the capabilities of the MPLAB Harmony v3 audio offerings. Each example application project describes its hardware setup, block diagram, requirements, hardware compatibility and operation.

Bluetooth®

Bluetooth Library: This repository contains the MPLAB Harmony v3 Bluetooth Package (bt). It supports a fast-to-market Bluetooth development environment for 32-bit SAM and PIC microcontrollers.

Cryptography

Cryptography Library: The Cryptographic library includes functions to perform encryption, decryption, hashing, authentication and compression within an embedded application. Random Number Generation (RNG) functions are also provided.

Graphics

Graphics Library: The graphics repository contains the files for MPLAB Harmony Graphics Suite quick-start applications, drivers, tools, libraries and templates.

Graphics Apps

Graphics Apps Library: The graphics apps repository contains the graphics application package (GFX Apps). This is a more extensive set of highly integrated, stand-alone applications that demonstrate some of the capabilities of graphics in MPLAB Harmony v3 for 32-bit PIC and SAM microcontrollers..

Motor Control

Motor Control Library: This module contains motor control demonstrations implemented on 32-bit microcontrollers.

 

Touch

Touch Library: Use this software library for developing touch applications on 32-bit microcontrollers with a Peripheral Touch Controller. The library supports both self-capacitance and mutual-capacitance acquisition methods.

Networking (TCP/IP)

Networking (TCP/IP) Library: This repository provides a fast-to-market TCP/IP stack for 32-bit PIC and SAM microcontrollers. It contains multiple applications that demonstrate communication over TCP/IP using well-known protocols like TCP, UDP, HTTP, SMTP, etc.

USB

USB Library: The USB module provides USB controller drivers for 32-bit PIC and SAM devices, as well as Host and Device middleware with support for common device classes..

Repository

Description


Core

The core module components provide the simple-to-use abstractions of 32-bit SAM and PIC device peripherals and shared resources on which the MPLAB Harmony 3 middleware is based, including drivers, services and the Operating System Abstraction Layer (OSAL).

 

Chip Support Package (CSP)

The CSP module contains independent, low-level Peripheral Libraries (PLIBs) that are simple functions to initialize and control peripherals and basic device features on which MPLAB Harmony 3 drivers and services are based. The CSP supports initialization of 32-bit devices and development of simple applications that directly control peripheral hardware with minimal external dependencies.

 

Board Support Package (BSP)

The BSP module provides initial configuration settings for PIC and SAM Xplained development boards.

 

MPLAB Harmony  Configurator (MHC)

The MHC repository contains the implementation of MPLAB Harmony Configurator (MHC), a Graphical User Interface (GUI) based configuration utility that accelerates the development of embedded applications using 32-bit SAM and PIC devices.

 

Bootloader

The bootloader module components provide a framework to develop bootloaders for SAM microcontrollers. The Bootloader Library can be used to upgrade firmware on a target device without requiring an external programmer or debugger.

 

Repository

Description


The wolfSSL embedded SSL library (formerly CyaSSL) is a free-to-use, lightweight SSL/TLS library written in ANSI C and targeted at embedded, RTOS and resource-constrained environments. It supports TLS 1.3.

 

wolfMQTT is an implementation of the MQTT Client written in C for embedded use and that supports SSL/TLS via the wolfSSL library. This free-to-use library was built from the ground up to be multi-platform, space conscious and extensible. It integrates with wolfSSL to provide TLS support.

 

wolfSSL's Embeddable SSH Server is a free-to-use, lightweight Secure Shell library that provides server-side support for SSH v2.0 capabilities. It is dependent on wolfCrypt.

 

The Micrium OS-III repository contains µCOS-III port files and demonstrations implemented on 32-bit PIC and SAM microcontrollers.

 

FreeRTOS, an industry-leading, open-source, real-time operating system is enabled by default with Harmony v3 drivers, middleware and system services. It is accessed directly from the CMSIS FreeRTOS repository. This enables you to schedule tasks in your application quickly. If bare-metal development (without RTOS support) or use of another supported real time operating system is desired, simply select the desired option from the available RTOS configuration.

Getting Started and Tutorials

Documentation


Title Download
Creating a "Hello World" Application Using the MHC Download
How to Build an Application by Adding a New PLIB, Driver, or Middleware to an Existing MPLAB Harmony v3 Project Download
How to Create Non-Cacheable Memory Region on Cortex-M7 (SAME70) MCU Using MPLAB Harmony v3 Download
The Difference Between MPLAB Harmony v3 Synchronous and Asynchronous Drivers and When to Use Them Download
Creating a Hello World Application on PIC32 Microcontrollers Using the MPLAB Harmony v3s MPLAB Harmony Configurator Download
How to Use Harmony v3 Debug System Service Download
AN3475 - File Transfer Protocol Using MPLAB Harmony v3 TCP/IP Stack Application Note Download
AN3443 - Execute-In-Place (XIP) with QSPI on Cortex-M7 MCUs Using MPLAB Harmony v3 Download
AN3466 - Using XDMAC with QSPI on Arm Cortex-M7 MCUs Using MPLAB Harmony v3 Application Note Download
AN3508 - Dual Bank Bootloader on SAM E54 Microcontroller (MCU) Using MPLAB Harmony v3 Download
Creating a "Hello World" Application on SAM Microcontrollers Using MPLAB Harmony v3 with MPLAB Harmony Configurator (MHC) Download
How to Setup MPLAB Harmony v3 Software Development Framework Tech Brief Download
AN_3342 - SleepWalking with Event System Using the SAM E54 AN Download

MPLAB Harmony v3 Videos