element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Members
    Members
    • Benefits of Membership
    • Achievement Levels
    • Members Area
    • Personal Blogs
    • Feedback and Support
    • What's New on element14
  • Learn
    Learn
    • Learning Center
    • eBooks
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Dev Tools
    • Manufacturers
    • Raspberry Pi
    • RoadTests & Reviews
    • Avnet Boards Community
    • Product Groups
  • Store
    Store
    • Visit Your Store
    • Choose Another Store
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
Embedded and Microcontrollers
  • Technologies
  • More
Embedded and Microcontrollers
Blog PSoC 6 and ModusToolbox: Create a Project with its own Board- and Module configurations
  • Blog
  • Forum
  • Documents
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Embedded and Microcontrollers requires membership for participation - click to join
Blog Post Actions
  • Subscribe by email
  • More
  • Cancel
  • Share
  • Subscribe by email
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: Jan Cumps
  • Date Created: 19 Feb 2021 12:07 PM Date Created
  • Views 1882 views
  • Likes 7 likes
  • Comments 5 comments
  • mtb
  • infineon
  • modustoolbox
  • psoc 6
  • psoc6
  • cypress
  • psoc
Related
Recommended

PSoC 6 and ModusToolbox: Create a Project with its own Board- and Module configurations

Jan Cumps
Jan Cumps
19 Feb 2021

By default, projects in a workspace in the Cypress ModusToolbox IDE (mtb) share board and device configuration files.

There are several good reasons to do this, but it's not always what you need.

If you want to build designs with a different configuration, there are a few options.

The two easy ones are: multiple workspaces and - what I test here - a project with fully contained configurations.

image

 

The procedure is explained in the ModusToolbox User Guide, 5.4 Modifying the BSP Configuration for a Single Application.

If you have the IDE installed, the user guide is also available from the Help menu.

 

Summary of the goal: create a project in an active workspace that is isolated.

Board or device changes made to the project do not impact other projects.

Changes made to other projects do not impact this project.

 

Step 1: create a project for your board

 

In the IDE, create a new project. File -> New -> ModusToolbox Application

image

 

I'm using a PSoC 6 WiFi and Bluetooth prototype kit (I got this from balearicdynamics!).

image

I use the "empty" project for this board as the base. I name it Standalone_e14_blog.

Then click Create.

image

 

The result is a new project in the IDE.

image

It uses the shared configuration in the mtb_shared folder. If I reconfigure a device or the board file in my project now, my other project SCB_UART_Trans... would get the modification too.

Now let's start to isolate our configurations.

 

Step 2: set up local configuration structure

 

Create a directory named COMPONENT_CUSTOM_DESIGN_MODUS in the root of the new project.

Right click on Project -> New -> Folder

image

Enter COMPONENT_CUSTOM_DESIGN_MODUS and click Finish.

image

In that folder, create a subfolder with the structure . In my case TARGET_CY8CPROTO-062-4343W.

image

If you don't know what the name for your board should be, check the mtb_shared project. It will have a folder with the correct name for your board.

Then, I copy the necessary files into the new folder.

Copy everything from the mtb_shared / TARGET_XXXXXXXX_ / latest-vXXXX / COMPONENT_BSP_DESIGN_MODUS, except the GeneratedSource subfolder.

 

image

I paste the files in the custom folder structure of my freshly generated project:

image

Step 3: adapt the makefile

 

You need to add two lines to the makefile. It will tell the builder to look for our local configurations.

These two lines need to be added.

 

COMPONENTS += CUSTOM_DESIGN_MODUS
DISABLE_COMPONENTS += BSP_DESIGN_MODUS

 

image

 

Save the file.

 

Last step: Refresh the Quick Panel

 

In the Quick Panel, click the Refresh Quick Panel hyperlink.

image

 

This is it. All tools will now use your local project configuration.

image

 

I have attached the project to this blog post as a zip file. You can import it in your IDE if you don't want to do all the steps.

 

PSoC 6 series
Create a Project with its own Board- and Module configurations
Low Power Management - prepare the board for current measurements
Power consumption without WiFi or Bluetooth
Create a FreeRTOS 10.3 Project
UART receiver with FreeRTOS
FreeRTOS message queue
UART receiver with FreeRTOS - Deep Sleep support
Attachments:
Standalone_e14_blog.zip
  • Sign in to reply

Top Comments

  • Jan Cumps
    Jan Cumps over 2 years ago +1
    A little trick I use often in Eclipse to get fast access to documentation. I create a lightweight Eclipse project to collect common documentation. In this case: Controller and evelopment kit docs. In that…
  • Jan Cumps
    Jan Cumps over 1 year ago in reply to skruglewicz

    You will want a non-shared project, if you are going to use the configuration tools to use peripherals different than the default config in the shared project.

     

    Other option is to use a different workspace for each project. In that case it doesn't matter if you share or don't.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • skruglewicz
    skruglewicz over 1 year ago
    • I tried this out and was confused at first because the Shared directory (mtb_shared / TARGET_XXXXXXXX_ / latest-vXXXX / COMPONENT_BSP_DESIGN_MODUS) for the BSP device was not listed as described in Step 2.
    • What I had to do was make the device  shared in the Library manager. It was unchecked by default. When I checked it and selected "Update", the directory was created. Now, I can follow along to the rest of the steps.
    • I don't recall setting this checkbox when opening any projects, but I'm just learning ModusTB now and just wanted to not this point.
    • This a neat feature, but since I'm only using the the CY8CKIT, I'm not sure if I'll be using this configuration. I don't plan on changing the BSP at this stage of my development.

    image

    Kind regards

    Steve K

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • Jan Cumps
    Jan Cumps over 2 years ago

    This is slowly turning into a series

     

    PSoC 6 and ModusToolbox: Create a Project with its own Board- and Module configurationsPSoC 6: Low Power Management - Power consumption without WiFi or BluetoothPSoC 6 and ModusToolbox: Create a FreeRTOS 10.3 ProjectPSoC 6 and ModusToolbox: UART receiver with FreeRTOSPSoC 6 and ModusToolbox: FreeRTOS message queue
    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • Jan Cumps
    Jan Cumps over 2 years ago

    Note to self: when creating a project and adding FreeRTOS 10.3, update Makefile with this:

    COMPONENTS=FREERTOS

     

    Else there are compile errors in the abstraction-rtos build.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • Jan Cumps
    Jan Cumps over 2 years ago

    A little trick I use often in Eclipse to get fast access to documentation.

     

    I create a lightweight Eclipse project to collect common documentation. In this case: Controller and evelopment kit docs.

    In that project I create a virtual folder, named Documentation. It's not a real file location, but it acts a s one in Eclipse.

    Then I drag and drop any PDF that I want to have accessible while developing on that folder. This creates a link to the documents.

    All of this takes very little disk space. There are no files copied or duplicated.

     

    When opening the first one, I do that by right-clicking on it, open with other -> internal web browser,

    and click use it for all pdf files.

    The files then open as an Eclipse window just like source files.

     

    image

     

    Often, the PDF files have odd names that do not tell what the content is.

    You can rename them in Eclipse. It does not change the actual file name of the document, only how it shows in Eclipse.

     

    For documents that are project specific, like datasheets of ICs used in a particular project, I create a similar virtual folder in the project itself, and drop the datasheets in it...

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • More
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2023 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • Facebook
  • Twitter
  • linkedin
  • YouTube