cancel
Showing results for 
Search instead for 
Did you mean: 

ModusToolbox General

HaEl_4692376
New Contributor II

I have made my own BSP based on the documentation, and all worked well.

I find myself having to update the MCU in it and the wireless product.

Is there a way I can re-generate the BSP to just update the MCU and Wi-Fi combo chip? I want everything else to remain the same.

0 Likes
Reply
1 Solution
DheerajK_81
Moderator
Moderator

You can update the MCU device and the wireless device easily by opening the design.modus file inside your Custom BSP and going to File > Change Devices. You will find the following prompt:

pastedImage_1.png

Note that doing this will preserve the configurations as long as the device you choose has the same hardware capabilities. For example, if you move from a PSoC63 BLE device to PSoC62, then the BLE peripheral which was configured will no longer be available and the device configurator promptly tells you the same.

notice list.PNG

Hope this helps

Regards,

Dheeraj

View solution in original post

0 Likes
Reply
9 Replies
DheerajK_81
Moderator
Moderator

You can update the MCU device and the wireless device easily by opening the design.modus file inside your Custom BSP and going to File > Change Devices. You will find the following prompt:

pastedImage_1.png

Note that doing this will preserve the configurations as long as the device you choose has the same hardware capabilities. For example, if you move from a PSoC63 BLE device to PSoC62, then the BLE peripheral which was configured will no longer be available and the device configurator promptly tells you the same.

notice list.PNG

Hope this helps

Regards,

Dheeraj

View solution in original post

0 Likes
Reply
HaEl_4692376
New Contributor II

Dheeraj, thanks for the fast response.

Your answer worked to get my MPNs changed. It did it and it worked, as far as process.

I then found out none of my programs flash or erase, etc.

The issue I debugged is down to the build. I did a clean, a rebuild, refresh files, etc...My build still builds the older products, and therefore, when it comes to programming, I am unable to program into my product.

How can I update the build script?

My HW works if I start from a kit which has the parts I have (4343W Wi-Fi-BT kit). But not from my BSP (which was based on the 43012 + 2M PSoC6). So I am moving my BSP to the 4343W and 1M PSoC6.

the changes were made in the design.modus and no conflict of resources were found.

0 Likes
Reply
DheerajK_81
Moderator
Moderator

Yes, this is because the launch configs aren't updated. They are still picking up the hex file from the BSP you started with. When you update the TARGET variable in the Makefile to point to your custom BSP, it builds your application and creates the hex file in the path: "<app_name>/build/" folder.

But the launch configs in the Quick Panel still point to the hex file of the initial BSP. To update them and point to the new hex file, you need to click "Generate Launches" as highlighted below.

quick.PNG

You should now be able to program and observe the output

Regards,

Dheeraj

0 Likes
Reply
HaEl_4692376
New Contributor II

Yes, I did that originally.

I just did it again for sanity. But the issue persists.

For some reason, it is not building for the right target based on the output.

Here is my design.modus

pastedImage_1.png

Here is the output when I build. Look at the MPN

Calculating memory consumption: CY8C624ABZI-D44 GCC_ARM -Og

   ----------------------------------------------------

  | Section Name         |  Address      |  Size       |

   ----------------------------------------------------

  | .cy_m0p_image        |  0x10000000   |  5972       |

  | .text                |  0x10002000   |  80952      |

  | .ARM.exidx           |  0x10015c38   |  8          |

  | .copy.table          |  0x10015c40   |  24         |

  | .zero.table          |  0x10015c58   |  8          |

  | .data                |  0x080022e0   |  1400       |

  | .cy_sharedmem        |  0x08002858   |  8          |

  | .noinit              |  0x08002860   |  148        |

  | .bss                 |  0x080028f4   |  986680     |

  | .heap                |  0x080f3730   |  45264      |

   ----------------------------------------------------

  Total Internal Flash (Available)          2097152   

  Total Internal Flash (Utilized)           90600     

  Total Internal SRAM (Available)           1046528   

  Total Internal SRAM (Utilized)            1033500   

The compiling message refer to the -DCY8C624ABZI_D44 -DCY_TARGET_DEVICE=CY8C624ABZI_D44

0 Likes
Reply
DheerajK_81
Moderator
Moderator

It looks like when the device is changed in the design.modus file, the Makefile doesn't get updated to reflect the new device. Please open the <CUSTOM_BSP>.mk file present inside your custom BSP directory. The directory will be named in the following format: TARGET_<CUSTOM_BSP>.

Set the value of the DEVICE variable to the device you selected in the design.modus file.

# MCU device selection

DEVICE:=CY8C6247BZI-D54

It should now work

Regards,
Dheeraj

0 Likes
Reply
HaEl_4692376
New Contributor II

Program no longer compiles

libs/psoc6make/make/recipe/recipe.mk:45: *** The specified linker script could not be found at ./TARGET_CUSTOM_BSP/linker/TOOLCHAIN_GCC_ARM/cy8c6xx7_cm4_dual.ld.  Stop.

and now I lost all Tools in the Quick Panel

0 Likes
Reply
HaEl_4692376
New Contributor II

I reverted my changes to the old MPNs and it compiles again and my Tools are still not there, except for the Library Manager

0 Likes
Reply
DheerajK_81
Moderator
Moderator

In the steps mentioned to create your own BSP in the Section Creating a BSP for your Board in the ModusToolbox User Guide, one of the steps is to update the TARGET variable in the Makefile. Since there are multiple documentations, I would like to ensure you are following this, this is the latest.

Edit the Makefile in the application directory to pick your custom BSP using the TARGET variable:

# Target board/hardware

TARGET=CUSTOM_BSP

Please note: Even though the custom BSP you created is called "TARGET_CUSTOM_BSP", you drop the prefix TARGET_ while passing the value.

When you build your application you should be seeing this in the console:

Initializing build: mtb-example-psoc6-empty-app Debug CUSTOM_BSP GCC_ARM

If you obtain this in the console and are still seeing errors, please attach your project so that I can have a look at what might be going wrong.

Regards,

Dheeraj

0 Likes
Reply
HaEl_4692376
New Contributor II

I went ahead and created a stanard kit project and copied the CM0 and CM4 folder from the standard BSP to my BSP and fixed the issue.

Thanks for the help