cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 6

Amar_Hiremath
New Contributor II

I am working with a PSOC6 bootloader all compilation goes without errors.

when I try to update the user application from PC cysmart I am getting the below error please do guide what is the cause for this error and how can I over come.

"The bootloader reported error 'Packet length invalid: the packet's length does not conform to the required packet format"

Untitled212332.png

0 Likes
1 Solution
Amar_Hiremath
New Contributor II

this was solved after updating the main_cm0.c

Cy_SysEnableCM4(CY_CORTEX_M4_APPL_ADDR);  this has to replaced by Cy_SysEnableCM4((uint32_t)(&__cy_app_core1_start_addr));

now with bootloadle app If i try to access the sflash memory the device stops booting and hangs up, how to solve this...?

View solution in original post

0 Likes
14 Replies
VenkataD_41
Moderator
Moderator

Hi Amar,

Please try with the attached projects with CYBLE-416045-02.

First program the App0 project into the module and then bootload the App1 over the air using CySmart application. This code example I am attaching is present in PSoC Creator also.

Thanks

Ganesh

0 Likes
Amar_Hiremath
New Contributor II

with the above code example I didn't found the device with name BLE DFU Device in cysmart.

0 Likes
Amar_Hiremath
New Contributor II

Hi Ganesh,

Post modifying the dl files the above error gone but I am getting the error as below Image.

Untitled212332.png

and While compilation of the user app it gives the following error message:

.\CortexM4\ARM_GCC_541\Release\CYBLE_416045_02.elf.tmp: ERROR: A digital signature request was made, but the .cy_app_signature ELF section does not exist

Is this causing the above checksum error.

0 Likes
Amar_Hiremath
New Contributor II

after adding this line in user(app1) application compilation issue solved and I am able download the Image to board.

CY_SECTION(".cy_app_signature") __USED static const uint32_t cy_bootload_appSignature[1];

Post that:

the App1 is not running after downloading. how to check what is the issue with app1..? below is the image which shows the error .

Untitled212332.png

0 Likes
Amar_Hiremath
New Contributor II

this was solved after updating the main_cm0.c

Cy_SysEnableCM4(CY_CORTEX_M4_APPL_ADDR);  this has to replaced by Cy_SysEnableCM4((uint32_t)(&__cy_app_core1_start_addr));

now with bootloadle app If i try to access the sflash memory the device stops booting and hangs up, how to solve this...?

View solution in original post

0 Likes
Amar_Hiremath
New Contributor II

how to murge app0 and app1 to create one hex file for production..?

0 Likes
Amar_Hiremath
New Contributor II

@VenkataD_41  can i get the help on the above to create one hex combined with app0&app1..?

0 Likes
VenkataD_41
Moderator
Moderator

Hi,

You can create the combined hex file for app0 and app1 using the cymcuelftool which is already installed in your PC when you installed Modus Toolbox. Please open the following path 

1. Open the path C:\Users\"your frive"\ModusToolbox\tools_2.3\cymcuelftool-1.0\bin 

2. Copy the .elf files of App0 and App1 to the above location

3. Run the following command after opening the command prompt from the above path

>>cymcuelftool.exe --merge app0.elf app1.elf --output final.elf --hex final.hex

This will generate the "final.hex" which is the combination of app1 and app2. For more information, please refer the following application note:

https://www.cypress.com/file/385706/download

Thanks and regards

Ganesh

 

0 Likes
Amar_Hiremath
New Contributor II

@VenkataD_41 I am using psoc creator 4.3 is this can be used..?

0 Likes
Amar_Hiremath
New Contributor II

by doing this below coping only Bootloader.elf  can you please check on this..?

cymcuelftool.exe --merge Bootloader.elf CYBLE_416045_02.elf --hex CortexM4\ARM_GCC_541\Release\CYBLE_416045_02.hex

0 Likes
VenkataD_41
Moderator
Moderator

Hi,

Yes. You can use Cymcuelftool even if you use PSoC Creator 4.3. There will not be any problem because the Cymcuelftool is a separate thing.

Regarding the command, you missed the --output part. Please give it as following:

C:\Users\Ganesh.Dosapati2@infineon.com\ModusToolbox\tools_2.3\cymcuelftool-1.0\bin>cymcuelftool.exe --merge LOADER.elf APPLICATION_1.elf --output final.elf --hex final.hex

Thanks

Ganesh

Ganesh

0 Likes
Amar_Hiremath
New Contributor II

@VenkataD_41 please check with attached image with previous post and attaching the same blow i am using as said

%CY_MCU_ELF_TOOL% --merge ..\IR_COP_CYBLE_416045_02-Bootloader.cydsn\CortexM4\ARM_GCC_541\Release\IR_COP_CYBLE_416045_02-Bootloader.elf CortexM4\ARM_GCC_541\Release\IR_COP_CYBLE_416045_02.elf --output CortexM4\ARM_GCC_541\Release\IR_COP_CYBLE_416045_02.elf --hex CortexM4\ARM_GCC_541\Release\IR_COP_CYBLE_416045_02.hex

0 Likes
Amar_Hiremath
New Contributor II

any update on this.? by using pdl3.1.3 also it didn't worked.

0 Likes
VenkataD_41
Moderator
Moderator

Hi @Amar_Hiremath 

The problem is maybe with PSoC Creator Project itself or with the PSoC Creator settings combined with windows OS.

Please do the following steps to confirm which side the issue is:

1. Use the project I sent you before and get the print statements working properly. For that, you can just program the App0 first and see the print statement as "Inside Bootloader". Once this works, you can bootload the App1 using CySmart app and then see the print statement "Hello World-Inside Bootloadable". If this also works then try the process of merging App0 and App1 and then see if it is working or not.

2. If the above step works, it means the project you are using has some issue. Please attach your PSoC Creator project so that we can test it on our side.

3. After step 1 if you still see the issue with our project, please try to use _signed.elf files for both App0 and App1 instead of .elf directly. You can also try uninstalling the PSOC Creator and re-installing it and check once.

Please note that App0 means Bootloader and App1 means the actual application.

Thanks and regards

Ganesh

0 Likes
Top labels