Creating bootloader.DLL file and UART Bootloader Host application with Security Key.

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
PAB
Level 2
Level 2
First like given Welcome!

Hello All

Need to add Security Key option in my Custom UART boot loader HOST application, so for that i had to generate BootLoader_Utils.dll file.

As per this link https://community.cypress.com/docs/DOC-10591 i tried to generate .DLL file but this throw too many errors. Project file of Visual Studio Attached.

i also tried changing built configuration for x86 and x64 but didn't work.

After generating .dll file i had to add a feature add security key in application.

pastedImage_2.png

Please Check the link and review the Project.

thanks & regards

Paras Brahmbhatt

0 Likes
1 Solution
DheerajK_81
Moderator
Moderator
Moderator
First comment on KBA First comment on blog 5 questions asked

The only change I did to the files you attached was use the Platform Toolset which comes with Visual Studio 2017 (i.e v141) and provide the bootloader util files.

pastedImage_1.png

I think you can either download the Platform Toolset for VS2017 and then add it to this option highlighted above or download VS2017 itself.

Regards,

Dheeraj

View solution in original post

0 Likes
7 Replies
DheerajK_81
Moderator
Moderator
Moderator
First comment on KBA First comment on blog 5 questions asked

Can you tell me what kind of errors you encountered? I do not see any errors, probably because I'm using the Visual Studio 2017 edition and you are using Visual Studio 2010.

I was able to compile and run the application successfully without any problems. Screenshot attached below:

pastedImage_0.png

If possible download the latest version of Visual Studio and check if it compiles successfully.

Regards,

Dheeraj

0 Likes

This software i attached for ref. i had to add security key in this software so i had to built bootloader_utils.dll .

0 Likes

The toolset error looks like it means that it's targeting a different version of Visual Studio. See:

https://stackoverflow.com/questions/56901371/how-to-install-v142-build-tools-in-visual-studio

You may be able to get past it by going to Project->Properties->General->Platform Toolset and selecting the version you currently have installed with your version of VS.

0 Likes

Do need V142 built tool to compile dll File. i am using Visual Studio 2010.

Thanks

Paras

0 Likes
DheerajK_81
Moderator
Moderator
Moderator
First comment on KBA First comment on blog 5 questions asked

The only change I did to the files you attached was use the Platform Toolset which comes with Visual Studio 2017 (i.e v141) and provide the bootloader util files.

pastedImage_1.png

I think you can either download the Platform Toolset for VS2017 and then add it to this option highlighted above or download VS2017 itself.

Regards,

Dheeraj

0 Likes
KyTr_1955226
Level 6
Level 6
250 sign-ins 10 likes given 50 solutions authored

What kind of errors are you getting when attempting to build bootloader_utils?

The project you posted for bootloader_utils does not contain any of the source files.

As soon as I copied them to the project directory and added them to the project, I had no problems building BootLoader_Utils.dll

I don't believe you need to make any custom code changes to the bootloader_utils library to use the security key feature.  It is a byte array parameter that is passed into CyBtldr_Program() and is sent to the PSoC alongside the "Enter Bootloader" command and is validated against your programmed key by the bootloader on the PSoC.  It will only enter the bootloader if the key matches.

0 Likes

I don't want to modify bootloader utils files. i just need to generate .dll file. i tried to generate it throw errors.

pastedImage_0.png

I think the Problem is with my Visual Studio 2010.

I Run and built your Code but it throw also throw error.

pastedImage_1.png

Is it because of Built Configuration.

0 Likes