This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Tool/software:
Hi,
I am trying to flash a "blinking-led" program via CAN into my LaunchPad F2800157. I have followed the steps given in the document: "CAN Flash Programming of C2000 Microcontrollers", but the program is not being flashed. I have followed the following steps:
1. Setting the correct Boot Mode by setting GPIO32 (DOWN)-> 0 and GPIO24 (UP) ->1
2. Setting S4 DOWN to XCVR.
3. Connected HI / LO pins of the transceiver at J14 of the LaunchPad to Channel 1 of PCAN-USB Pro.
4. Importing the "flash_kernel_ex5_dcan_flash_kernel.c" project and adding a Predefined Symbol "_LAUNCHXL_F2800157" in C2000 Compiler Properties.
5. Adding "${CG_TOOL_HEX}" "${BuildArtifactFileName}" -boot -sci8 -a -o "${BuildArtifactFileBaseName}.txt" to the "flash_kernel_ex5_dcan_flash_kernel.c" project.
6. Enabling the C2000 Hex Utility and adding the flags: --diag_wrap=off --boot --sci8 --ascii in the "flash_kernel_ex5_dcan_flash_kernel.c" project.
7. Adding the "${CG_TOOL_HEX}" "${BuildArtifactFileName}" -boot -sci8 -a -o "${BuildArtifactFileBaseName}.txt" to the blinking-led project.
8. Enabling the C2000 Hex Utility and adding the flags: --diag_wrap=off --boot --sci8 --ascii in the blinking-led project.
9. Copying the generated two txt files to the "dcan_flash_programmer" directory and running the command: dcan_flash_programmer.exe -d f280015x -k dcan_flash_kernel.txt -a application_firmware.txt -v
10. The cmd window shows "Kernel Loaded" and "Application Load Completed" messages but the led application is not being loaded.
For troubleshooting and checking the hardware connections:
1. I tried the "can_ex5_transmit_receive" example in both the receiving mode as well as the transmitting mode. The connections between the Peak-USB Pro and LaunchPad were the same as described above. I could see the messages in PCAN-View when using LaunchPad in the transmitting mode.
2. I could see the messages received in the CCS WATCH window when using the LaunchPad in the receiving mode and sending messages from the PCAN-View Software.
3. I compared the PIN configurations and decided to make the following changes in the DCAN_Boot.c:
Hi Anand,
Thank you very much for your reply. My aim is to flash a program (I have chosen a blinking LED program for now) using the DCAN utility. I have followed the steps as I outlined in my query. Could you provide some more information on what you mean by DCAN or flash programming? because as I understand it, I want to program the flash but using DCAN.
I am not fully sure if this is a DCAN communication issue (e.g., pin mapping, baud rate, etc.) or if it’s a flash programming/bootloader issue (e.g., the code isn’t being written to the correct flash sectors, or the device doesn’t boot from flash afterward). Could you clarify what aspects specifically point to a DCAN problem versus a flash programming problem in this context?
regards,
Taif
Hi,
Can you put breakpoint in the main() function and are able to execute up to the breakpoint?
regards,
Anand
Hi Anand,
Thanks for your reply. Could you please clarify, which main() function are you referring to, as we are working with multiple files. Also should this be done after running the command for the dcan_flash_programmer.exe?
I look forward to your reply.
Best regards,
Taif
Hi Anand, if you could please provide some guidance on my last query, it would be much appreciated. Thanks!
Hi Taif,
The example that you flashed will have an entry function, can you place breakpoint and observe if you are hitting it?
This is to ensure that example is flashed properly.
regards,
Anand
Hi,
This issue has been resolved by the following:
e2e.ti.com/.../launchxl-f2800157-can-flash-programming-issues---bitrate-sleep_time-and-entryaddr-configuration---peak-pcan-usb-pro-error-status-red-led