Example

Description

PSOC Edge ADC

This code example demonstrates the use of the ADC PDL driver to perform voltage measurements using Arm® Cortex® M33 CPU on PSOC™ Edge MCU. In this example, the driver is configured to sample the input voltage periodically and display the sampled voltage on the UART terminal. By default, the ADC is configured to use one channel in single-ended mode.For more details, see the

README on GitHub

.

PSOC Edge Basic Read and Write on NVM

This code example demonstrates the basic read and write operations performed by the PSOC™ Edge MCU's CM33 CPU on the user NVM and OTP memory regions of internal Resistive Random Access Memory (RRAM)For more details, see the

README on GitHub

.

PSOC Edge CANFD

Controller area network flexible data-rate (CAN FD) is a communication protocol typically used for broadcasting sensor data and control information on two wire interconnections between NODEs. This example demonstrates how to use CAN FD in Infineon's PSOC™ Edge MCU devices. In this example, the CAN FD Node-1 sends a CAN FD frame to CAN FD-Node-2 on pressing the user button and vice versa. Both the CAN FD NODEs log the received data over UART serial terminal. Each time a CAN FD frame is received, the user LED toggles.For more details, see the

README on GitHub

.

PSOC Edge Core Benchmarking

This code example demonstrates how to run core benchmarking on the PSOC™ Edge MCU. The PSOC™ Edge MCU core benchmarking is based upon the EEMBC CoreMark® benchmarking software. CoreMark® is a registered trademark of EEMBC. The CoreMark® benchmarking software has been modified by porting the software to run on the PSOC™ Edge MCU. For information about this benchmarking, see this website. Note that the scores generated in this code example were not reviewed by the EEMBC, therefore is not an official CoreMark® score.For more details, see the

README on GitHub

.

PSOC Edge DSP Convolution

This code example demonstrates the convolution theorem with the use of the Complex FFT, Complex-by-Complex Multiplication, and Support Functions which are part of CMSIS-DSP library. This code example leverages the DSP and Helium extension of Arm® Cortex® M55 CPU.For more details, see the

README on GitHub

.

PSOC Edge emFile filesystem

This code example demonstrates the implementation of an emFile filesystem on Arm® Cortex® M33 CPU using PSOC™ Edge MCU. The CM33 CPU formats the storage device, reads a file and prints its content to the UART terminal. It overwrites the file with a message and deletes the file if requested through a user button press. The storage device can be an SD card or the onboard external NOR flash device.For more details, see the

README on GitHub

.

PSOC Edge Emulated EEPROM

This code example demonstrates Electrically Erasable Programmable Read-Only Memory (EEPROM) emulation in user Non-Volatile Memory (NVM) of PSOC™ Edge MCU using emeeprom middleware.For more details, see the

README on GitHub

.

PSOC Edge emUSB-Device Audio Recorder

This example demonstrates how to implement an audio recorder application by setting up the USB block of PSOC™ Edge MCU as a USB audio class device using the Segger's emUSB-Device middleware.For more details, see the

README on GitHub

.

PSOC Edge emUSB-device CDC Echo

This example shows how to use the Segger emUSB Device middleware to set up the USB block in PSOC™ MCU for the Communication Device Class (CDC). Once configured for CDC, the PSOC™ MCU device gets enumerated as a virtual COM port, which can be read and written by a terminal emulator program on a PC.For more details, see the

README on GitHub

.

PSOC Edge emUSB-device File system FreeRTOS

This example demonstrates the usage of Segger's emUSB-Device middleware to set up the USB block of PSOC™ Edge MCU as a Mass Storage Class (MSC) device and run the (FatFs) file system through an external memory (microSD). This example is based on FreeRTOS.For more details, see the

README on GitHub

.

PSOC Edge emUSB-device HID Generic

This code example demonstrates the usage of the emUSB device middleware stack to configure the USB block in PSOC™ Edge MCU as a generic Human Interface Device (HID). It takes help from an external HID software tool to send in the generic HID inputs which it then relays back.For more details, see the

README on GitHub

.

PSOC Edge emUSB-device HID Mouse

This example shows how to use Segger's emUSB-Device middleware to set up the USB block in PSOC™ Edge MCU for the Human Interface Device (HID) class. Once configured for HID, the MCU device gets enumerated as a 3-button mouse.After the device enumerates, the firmware moves the mouse cursor on your computer from the right to the left, and vice-versa.For more details, see the

README on GitHub

.

PSOC Edge emUSB-Device Suspend and Resume

This example demonstrates how an PSOC™ Edge MCU detects a USB suspend condition, enters a low-power state, and restores normal operation when USB activity resumes.For more details, see the

README on GitHub

.

PSOC Edge emUSB-Host CDC Echo

This code example shows how to set up the USB block in PSOC™ Edge MCU as a communication device class (CDC) Host using the emUSB-Host middleware. It implements echo functionality from the host side and requires a USB device configured to echo the CDC signals back to the host.For more details, see the

README on GitHub

.

PSOC Edge Ethernet MQTT Client

This code example demonstrates the implementation of an MQTT client over Ethernet with PSOC™ Edge MCU. In this example, the MQTT client establishes a connection with the configured MQTT broker and publishes messages on a topic upon button press, and subscribes to the same topic to control an LED. For more details, see the

README on GitHub

. License Disclaimer: This code example makes use of the lwIP open-source TCP/IP stack. Creating a project from this template will cause lwIP to be downloaded on your computer. It is your responsibility to understand and accept the lwIP license. Creating a project from this template will cause Mbed TLS to be downloaded on your computer. It is your responsibility to understand and accept the Mbed TLS license and regional use restrictions (including abiding by all applicable export control laws).

PSOC Edge Ethernet Secure TCP Client

This code example demonstrates implementation of a secure TCP client with PSOC™ Edge MCU. In this example, a TCP client establishes a secure connection with a TCP server through an SSL handshake. Once the SSL handshake completes successfully, the TCP client turns ON or OFF the user LED based on the command received from the TCP server. For more details, see the

README on GitHub

. License Disclaimer: This code example makes use of the lwIP open-source TCP/IP stack. Creating a project from this template will cause lwIP to be downloaded on your computer. It is your responsibility to understand and accept the lwIP license. Creating a project from this template will cause Mbed TLS to be downloaded on your computer. It is your responsibility to understand and accept the Mbed TLS license and regional use restrictions (including abiding by all applicable export control laws).

PSOC Edge Ethernet Secure TCP Server

This code example demonstrates implementation of a secure TCP Server with PSOC™ Edge MCU. In this example, the TCP server establishes a secure connection with a TCP client through SSL handshake. Once the SSL handshake completes successfully, the server allows the user to send LED ON/OFF command to the TCP client; the client responds by sending an acknowledgement message to the server. For more details, see the

README on GitHub

. License Disclaimer: This code example makes use of the lwIP open-source TCP/IP stack. Creating a project from this template will cause lwIP to be downloaded on your computer. It is your responsibility to understand and accept the lwIP license. Creating a project from this template will cause Mbed TLS to be downloaded on your computer. It is your responsibility to understand and accept the Mbed TLS license and regional use restrictions (including abiding by all applicable export control laws).

PSOC Edge FreeRTOS POSIX Demo

This code example demonstrates the usage of FreeRTOS-POSIX library for Infineon MCUs. FreeRTOS-POSIX implements a small subset of the POSIX threading API. This code example shows how to use the FreeRTOS-POSIX API in an RTOS application, making application developers familiar with POSIX APIs. This example demonstrates the usage of the following POSIX components: pthread, pthread_mutex, timer, mqueueFor more details, see the

README on GitHub

.

PSOC Edge Frequency Measurement using TCPWM

This code example demonstrates how to measure the frequency of a periodic digital signal using the TCPWM peripheral in PSOC™ Edge MCU. The example initialises the TCPWM resources from Arm® Cortex® M33 core of PSOC™ Edge MCU.For more details, see the

README on GitHub

.

PSOC Edge GPIO Interrupt

This code example demonstrates the use of a GPIO configured as an input pin to generate interrupts on PSOC™ Edge MCU. The GPIO signal interrupts the CPU and executes a user-defined interrupt service routine (ISR). The GPIO interrupt acts as a wakeup source to wake the CPU from deepsleep.For more details, see the

README on GitHub

.

PSOC Edge I2C Controller EzI2C Target

This code example demonstrates the use of the I2C controller with an EzI2C target on Arm® Cortex® M33 CPU on PSOC™ Edge MCU. The I2C master is configured to send command packets to control a user LED on the slave. Both the slave and the master can be configured on the same kit.For more details, see the

README on GitHub

.

PSOC Edge I2S Audio

This example demonstrates how to use the Inter-IC Sound (I2S) hardware block PSOC™ Edge MCU to interface with an audio codec. The I2S hardware block is configured to Arm® Cortex® M33 CPU.For more details, see the

README on GitHub

.

PSOC Edge I3C Controller

This code example demonstrates the use of the I3C resource in controller mode using Arm® Cortex® M33 CPU on PSOC™ Edge MCU. The I3C controller is configured to send command packets to the target.For more details, see the

README on GitHub

.

PSOC Edge I3C Target

This code example demonstrates the use of the I3C resource in target mode using Arm® Cortex® M33 CPU on PSOC™ Edge MCU. The I3C target is configured to receive command packets from the controller.For more details, see the

README on GitHub

.

PSOC Edge IPC pipes

This example demonstrates how to use the inter-processor communication (IPC) driver to implement message pipes in PSOC™ Edge MCU. The IPC pipes are used to send messages between CPUs.For more details, see the

README on GitHub

.

PSOC Edge IPC Semaphore

This code example demonstrates how to use the inter-processor communication (IPC) PDL (Peripheral Driver Library) driver to implement a semaphore in PSOC™ Edge MCU. The semaphore is used as a lock to control access to a resource shared by the CPUs and synchronize the initialization instructions.For more details, see the

README on GitHub

.

PSOC Edge LittleFS filesystem

This code example demonstrates a littlefs filesystem on Arm® Cortex® M33 CPU using PSOC™ Edge MCU. The CM33 CPU mounts the filesystem on the storage device, reads a 32-bit value from a file, increments the value, writes the value back to the file, and finally prints the value to the UART terminal. You will see the value incrementing after every reset. This code example supports an SD card as storage device.For more details, see the

README on GitHub

.

PSOC Edge Multi-Counter Watchdog timer

This code example explains how to set up a multi-counter watchdog timer (MCWDT) using the MCWDT PDL resource to measure the timing between events in free-running mode on PSOC™ Edge MCU. The application configures a 32-bit free-running counter using two 16-bit counters of the MCWDT. Many applications require measuring the time gap between different events in a system for timekeeping or debugging. In this example, the time gap between successive user button press events is measured in seconds and displayed on a UART terminal.For more details, see the

README on GitHub

.

PSOC Edge PDM to I2S

This code example demonstrates how to route pulse-density modulation (PDM) audio data to the inter-IC sound (I2S) interface in PSOC™ Edge MCU. The PDM-PCM and I2S hardware block is configured to Arm® Cortex® M33 CPU.For more details, see the

README on GitHub

.

PSOC Edge PDM to PCM

This example demonstrates how to use the pulse-density modulation (PDM)/pulse-code modulation (PCM) hardware block of PSOC™ Edge MCU with a digital microphone. The PDM-PCM hardware block is configured to Arm® Cortex® M33 CPU.For more details, see the

README on GitHub

.

PSOC Edge Power Measurements

This code example shows how to achieve selected power modes listed as SIDs in the PSOC™ Edge E84 MCU datasheet for different configurations. You can select a desired configuration in the specs.h file including custom configurations. This example will configure the PSOC™ E84 MCU's clock frequencies and power modes as defined for the specified configuration. Once the built application binary has been loaded onto the PSOC™ E84 MCU, you can measure the current consumption of the PSOC™ E84 MCU and compare it against the values specified in the datasheet.For more details, see the

README on GitHub

.

PSOC Edge PSRAM Read and Write in XIP mode

This code example demonstrates interfacing with an external PSRAM in Octal-SPI DDR mode, using the serial memory interface (SMIF) PDL in PSOC™ Edge MCU. The application code is located in the proj_cm33_ns (CM33 non-secure project). You can move it to other projects depending on your application design.For more details, see the

README on GitHub

.

PSOC Edge PWM Dead Time

This code example shows TCPWM dead-time mode function. PWM line and PWM COMPL pins output the 1-kHz frequency wave and 1-kHz frequency wave with PWM leftalign 250 us in PWM dead-time mode.For more details, see the

README on GitHub

.

PSOC Edge PWM Square Wave

This code example generates a square wave using the PWM driver. An LED connected to the PWM output pin blinks at 2 Hz.For more details, see the

README on GitHub

.

PSOC Edge PWM Timer

This code example generates an interrupt every second with the TIMER driver, and toggles the user LED when a timer interrupt is generated.For more details, see the

README on GitHub

.

PSOC Edge Ramping LED using smart IO

This example uses a PWM resource and smart I/O to implement a ramping LED, where an LED gradually cycles through increasing and decreasing brightness levels. There is no CPU usage except for the initialization of PWM and smart I/O on Arm® Cortex® M33 core.For more details, see the

README on GitHub

.

PSOC Edge Real-Time Clock basics

This example demonstrates the usage of the real-time clock (RTC) in Infineon MCU. It shows how to get and set the time in the RTC using the RTC PDL API. The example also supports the daylight saving time (DST) feature. A UART interface is used to input the time and configure the RTC.For more details, see the

README on GitHub

.

PSOC Edge RTC periodic wakeup

This code example demonstrates the process of entering into DeepSleep and Hibernate modes, as well as the means to awaken from them using the RTC alarm.For more details, see the

README on GitHub

.

PSOC Edge Serial Flash Read and Write and XIP

This code example demonstrates how to interface an external NOR flash memory with the PSOC™ Edge MCU using the serial flash library. Specifically, it illustrates how the SMIF (Serial Memory Interface) block in the PSOC™ Edge E84 MCU can be initialized from the Arm® Cortex® M33 core's Secure project to access an external flash memory device. The code also demonstrates how to jump to a non-secure application after enabling Execute-in-Place (XiP) mode.For more details, see the

README on GitHub

.

PSOC Edge SmartIO I2S Controller

This code example uses a SPI resource and smart I/O in PSOC™ Edge MCU to implement the Inter-IC Sound (I2S) Controller interface (Tx only). The initialization is done on Arm® Cortex® M33 core.For more details, see the

README on GitHub

.

PSOC Edge SmartIO SGPIO target

This code example uses a SPI resource and Smart I/O in PSOC™ Edge MCU to implement the serial general purpose input/output (SGPIO) target interface, which is a four-signal bus defined in the SFF-8485 standard. Another SPI resource is used to implement the SGPIO initiator, which drives the clock on the SGPIO bus.For more details, see the

README on GitHub

.

PSOC Edge SPI with DMA

This code example demonstrates how to utilize the Serial Peripheral Interface (SPI) in controller and target modes with Direct Memory Access (DMA) on PSOC™ Edge E84 MCU. The SPI controller is configured to send command packets to control a user LED on the target. Both the controller and target can be on the same device or on different devices. The core logic is implemented in the project for CM33 Non-secure Processing Environment (NSPE).For more details, see the

README on GitHub

.

PSOC Edge Switching Power Modes

This example demonstrates how to transition PSOC™ Edge E84 MCU to the following system power modes: System High Performance (HP), System Low Power (LP), System Ultra Low Power (ULP) and System Deep Sleep.For more details, see the

README on GitHub

.

PSOC Edge TCPWM in PWM mode with dual compare

This code example demonstrates the generation of asymmetric PWM signals using two compare registers available in the TCPWM block of the PSOC™ Edge MCU devices. In comparison to the asymmetric PWM generated with only one compare function, this method employs two separate buffered compare values. This reduces the load on the CPU, as the CPU now only needs to update the compare value once per PWM cycle. The document discusses above mentioned advantages in the field-oriented control (FOC) application.For more details, see the

README on GitHub

.

PSOC Edge UART transmit and receive with DMA

This code example demonstrates the UART transmit and receive operation in PSOC™ Edge MCU using DMA. The application uses a serial terminal to read data and echoes what is received. UART is configured to perform both transmit and receive operations.For more details, see the

README on GitHub

.

PSOC Edge USB Device Audio Playback

This code example demonstrates how to setup the USB block of PSOC™ Edge MCU using Segger's emUSB-device middleware. In this code example PSOC™ Edge MCU enumerates as a USB audio class device with HID consumer control over the USB interface. This code example uses FreeRTOS.For more details, see the

README on GitHub

.

PSOC Edge Wakeup from Hibernate using a LPCOMP

This code example demonstrates the functionality of wakeup from hibernate mode using a low-power comparator (LPComp). It uses a dedicated GPIO input to compare the input voltage to an internal reference voltage to wake the PSOC™ Edge MCU from hibernate. User LED1 indicates the current power mode.For more details, see the

README on GitHub

.

PSOC Edge Watchdog Timer

This example explains how to set up a Watchdog Timer (WDT) using the WDT PDL drivers. The WDT resets the device if it is not serviced or "kicked" within the configured timeout interval. This helps in recovering the program from an unintended lock up.For more details, see the

README on GitHub

.