CY8CPROTO-062-4343W BSP
ModusToolbox™ Board Support Package (BSP) Overview

Introduction

A Board Support Package (BSP) provides a standard interface to a board's features and capabilities. The API is consistent across PSoC™ kits. Other software (such as middleware or the user's application) can use the BSP to configure and control the hardware. BSPs have the following characteristics:

  • BSPs initialize device resources, such as clocks and power supplies to set up the device to run firmware.
  • BSPs contain linker scripts and startup code so you can customize them for your board.
  • BSPs contain the hardware configuration (structures and macros) for both device peripherals and board peripherals.
  • BSPs provide abstraction to the board by providing common aliases or names to refer to the board peripherals, such as buttons and LEDs.
  • BSPs include the libraries for the default capabilities on the board. For example, the BSP for a kit with CAPSENSE™ capabilities includes the CAPSENSE™ library.

For a complete description of what the BSP provides and how it is used within ModusToolbox™, see the ModusToolbox™ User Guide

Quick Start with BSPs

This section provides a high-level view for using BSPs. You should be familiar with creating an application using both the ModusToolbox™ IDE and command-line environments. To use a BSP for a kit you need to perform the following steps:

  1. Get a BSP using one of the following methods:
    • Create an application with the Project Creation tool included with the ModusToolbox™ software installer (< ModusToolbox™ install>/tools_2.x/project-creator). This tool can also be launched from the Eclipse IDE for ModusToolbox™. The tool fetches the BSP for the kit that you selected, and places it in the libs directory.
    • In an existing application, use the Library Manager tool to fetch the required BSP. This tool is located in < ModusToolbox™ install >/tools_2.x/library-manager. You can also launch it from within the ModusToolbox™ IDE.
    • In an existing application, create a .lib file specifying the BSP and version (commit, tag, or branch). Then run make getlibs to fetch the BSP and any associated libraries. The .lib file typically goes in the deps directory.
    • In an existing application, clone the BSP GitHub repository using the git clone command. For example: git clone [https://github.com/infineon/TARGET_CY8CPROTO-062-4343W/#latest-v1.X] A BSP includes other libraries. To fetch all the libraries, use the make getlibs command from a command shell in the top directory of the application.
  2. Add #include "cybsp.h" to your main.c file.
  3. Add cybsp_init() at the start of main().
  4. Refer to the API documentation available inside that BSP docs directory to learn more.

References