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.

F28M35 Dual boot with debugger issue where M3 stops after C28 is started

Using F28M35H52C1 with latest code composer studio 5.

I had designed my own board and am using the Spectrum Digital XDS100V2 to program/debug my module.

I have written a failrly large program for the M3, to the point where I can't debug it using RAM loads, as I believe the debugger sucks up resources my program needs.  OK, so I program the M3 Flash and use the debugger.

I have written a program for the C28 (and use FLASH) that receives information from the M3 master and works off that information.

I program the M3, then program the C28 and all would be fine, I could debug the C28 with the data produced by the M3 section.  This had been working for a long time.

I had an issue with flashing, so I changed some setting in the debugger to try to make it work.  Then I realized that I could eliminate some buffers in memory used while prototyping, and was able to flash the M3 and debug the M3 solo again.

Then I flashed the C28, and when the C28 started, the M3 stopped.

So after going back and forth trying switch settings, I programmed the demo programs setup_M3 to RAM and blinky_dc_C28 to flash, and that worked.

So then I flashed my program to the M3 as standalone flash, and then flashed my C28 as flash, and after removing the spectrum digital XDS 100 V2 cable from the module, and powering down and up my module, my programs with both CPUs worked.  However, I had no capability to debug my C28.

Went back to flash my M3 (not in standalone mode) with C28, and the M3 stops.

From this, I can determine that the hardware is not the problem, but I believe I may have inadvertently changed a setting for flashing the M3 or C28 in some way.

Is there a writeup somewhere that covers all the debug settings?    Please do not point me to the basic setup, as written above I can get things to work.

Does anyone know what I did wrong so I can complete my debug of the C28?

 

 

 

  • Donald,

    Could you try the below steps and see if that works?

    (1) Make sure Auto ECC Generation option is enabled in the On-chip Flash Plugin GUI for both M3 and C28x.  

    (2) Load code on M3 Flash but do not execute yet 

    (3) Load code on C28x Flash with the CCS On-chip Flash Plugin GUI option "Backup/Restore clock register settings during Flash operations" enabled.

    (4) Execute M3 code

    (5) Execute C28x code

    Hope you checked for the updates in CCS and installed any Debug server updates.  This is to make sure you have the latest Flash Plugin files.

    Thanks and regards,

    Vamsi

  • I was able to update CCS, did not need to, but did it.

     1) verified switches were on.  

    2) OK

    3)  I do not understand this step?  Could you clarify in a step by step how to do?

  • I repeated steps above, except for #3, and the M3 processor did not start.  The C28 will run, but wihtout the M3 processor running, I do not get the data passed from the M3 that I need.

    When loading code on C28x Flash

    How do you set -----  "the CCS On-chip Flash Plugin GUI option "Backup/Restore clock register settings during Flash operations" to enabled."

     

     

     

  • Donald,

    In the CCS Debug window menu, click on Tools -> On-Chip Flash.

    Attached snapshot highlights the "Backup/Restore clock register settings during Flash operations" check box.

    Thanks and regards,

    Vamsi

     

  • Nope, I do not have that setting.

    I have  

    Code Composer Studio

    Version: 5.3.0.00090

    and that is after having checked for the latest updates, and having installed them.

    What do I do now?

  • Donald,

    The option that Vamsi pointed out is only in the latest CCS versions. Are you able to download and use the latest version of CCS?

    The latest version is CCS6.0.1. But note that this version will need a v6 license. If you are only using the free license, it will be fine, but if you are using a full license, you will need to upgrade your license for v6.

    Thanks,

    Ricky

  • I already own a license of CCS V5, why do I want Version CCS 6.01?  That version seems to be for the MPS 430?  I am using an M3  along with a CX28 processor.  I also am not in a position to spend any more money on this project til I achieve some results.

    Also, I prefer to go to a dentist and get my teeth drilled for no reason than to upgrade to version 5.5 for the sake of versionitis. 

    I would be afraid to update to version 5.5, If I could figure out how to, as it looks like so many people have had issues with it.  I do not have the bandwidth to download new code to my PC.

    Is it a guarantee that upgrading to get this new "switch" will work, if it was an issue with previous versions that you fixed, I would do the upgrade, but I feel that I would spend a week or two getting the new version to work.  Can you guarantee that this is not the case?  The TI down load sites are pretty slow.

    Can you explain what this switch does, to see if it would really solve the issue?

    My current setup works except for the detail of the M3 shutting off when I load the flash for the CX28.  There should be a way to fix this in my current version, unless it is a bug, then just come right out and say so.
      
    I have gotten dc_blinky_m3 and C28 to work by Flashing, is it possible that my program is so huge for both processors that the debugger would not work?
    Does the debugger require a lot of RAM space, as I have found that after my program used some of the shared RAM, I could not download program to RAM anymore.
     
    It did work til the week before last, programs do load in flash, just that the m3 section will not start in debug mode after downloading the C28 program, no matter what I do.
     
    I was about to make a big breakthrough, to take my board to a higher level system for testing, but this put the brakes on that.
    I will anxiously wait your reply.  I will focus on it today, hoping that  I do not have to wait days for replies on this e2e community forum.

     

    What do I do now?

  • Donald,

    Let me explain why I asked you to use "the Backup and Restore PLL" option.  When Flash Plugin is initiated for Flash erase/program sequence, Plugin reads the PLL configurations from the Plugin GUI and initializes the PLL accordingly.  When you first load M3 code and then load C28x code, C28x Plugin will modify PLL configuration as per C28x Plugin GUI.  This may not be the PLL config that your M3 application wants and hence it might act different in terms of timings for interrupts etc.  "Backup and Restore PLL" option will restore the PLL configuration as it was before using the Plugin.  However, according to your latest post, you are saying that M3 application is not executing at all.  So, let me try this in a different way.

    1) When you programmed the C28x Flash, what is M3 doing?  Is it executing it's application?  OR is it not programmed and not connected to debugger?  OR it is programmed and connected to debugger but not executing?  Reason I am asking this is because if M3 is not programmed and is not connected to the debugger, then if the boot option is selected for boot from Flash, then M3 might start fetching illegal opcodes from Flash and the device will reset continuously.  If this is the case, then before programming C28x, connect to M3 and then do C28x Flash operations.

    If the above does not help, then proceed to step 2 below:

    2) Do you have any code mapped to RAM directly in your linker command file?  Please map that code to Flash instead and copy it to RAM at run time for execution.  Flash Plugin loads code to Flash but it may ignore loading the code to RAM (Plugin code and your application code both when mapped to same RAM locations, Plugin may not restore the RAM correctly).  Plugin is designed for fully embedded applications where all the code is mapped to Flash at compile time and necessary code portions are copied to RAM at run time before execution.

    If the above does not help, then proceed to step 3 below: 

    3) Since you may not be able to move to next version of CCS easily, I am attaching the latest version of F28M35x Flash Plugin target file here (It has fixes for the bugs that we found after releasing the initial version).  Rename it as "f021_c28x.nfl" and replace it at ccsv5\ccs_base\c2000\nowFlash\libraries and give it a try.  

    Let me know how it goes.  

    Thanks and regards,
    Vamsi5481.f021_c28x.nfl

     

  • 1)  When I load the M3 flash, and execute, it works standalone.  I have included the Blinky LED in my programs for each of the M3 and CX28 to show a sign of life with out a connection to debug.

    When I load the M3 flash, and not execute, then flash the CX28, the M3 program starts (evidenced by flashing LED),  then stops.  When CX28 is finished flashing,  I get the error message  "No source available for "0x1001566"

    See below:

    With emulator selecting Cortex M3 program I then select the  Run , and LED for M3 section does not flash.

    Trying to run the CX28, CX28 LED does not flash indicating it is not running.

    2)   I do not have any RAM mapped to linker.  I do not have any look up tables nor do I use shadow RAM.

    3)  I down loaded and placed in specified directory, will need to reboot as I have an issue with the Spectrum Digital XDS 100 V2 emulator, as the design engineers there had not heard of digitally isolating the module from the target module, as was done very well on the Concerto Control card.  If it works, I will post a reply, if I do not post, assume it did not work (this should only take a few minutes).

  • I posted a reply, said it saved, and it went to a black hole.

    so again...

    I implemented the Blinky LEDs on both processors so I could use hardware to trace operation of CPUs. (i.e. sign of life).

    1) 

    When I flash M3, I do not execute.

    When I flash CX28, the M3 will start (indicated by flashing LED), then stops.  I get some error message.

    Try to execute M3, get error message.  CX28 will run though.

    M3 was programmed.

    2)  No, I do not use RAM for look up tables or shadow RAM functions.

    3) Downloaded file, placed in directory, no, it did not help.

  • I installed CCS V5.5, the download was relatively quick compared to the past, I am happy about this.

    The installation occurred with no issue, I am happy about this.  I did have to rebuild all after installation.

    I still can't run my M3 program from RAM, I need to use Flash.

     

    I set the switch as indicated, and when I could download, the "idea" did not work.  I get the same results as before.

  • I downloaded the latest Control Suite and re-read sections on “getting started” with using CCS, those slides did not match the current version…

    However, after a lot of fiddling around,  decided that trying to download flash using the debugger for each of the M3 and CX28 processors was wasting my time…

    So,

    I borrowed from the methods in the Control suite that I could grasp and

    then I ended up “launching the target”,

    then “connected to the targets”,

    then “loaded” the programs for each processor respectively

    then “ran” the M3

    then “ran” the CX28 processor,

     then all worked fine.  I can now start and stop both processors with breakpoints.

     Yes, I realize it is pretty much what I was told to do ( I am slow, but I get there), but I was using the green bug to load flash for each processor (i.e. “Debug As Code Composer Studio”), worked that way for a long time , but then stopped working last week.


    That was the detail as to what I was doing wrong.  As the code from the Cx28 processor was flashed, it knocked out the operation of the M3 processor.
     

    No more “Green bug” or “Debug As Code Composer Studio” for me.

  • I understand that by using the check box "Backup/Restore clock register settings during Flash operations" we can restore the clock settings after flashing the C28x CPU.

    I would like to know how can use this feature if we are using Debug server (DSS.bat) for download?

    Is this information is saved in CCXML file?

    Thanks,

    Sumith

  • Sumith,

    The Flash options can be accessed in DSS using the DebugSession class. The option ID of the option you are referring to is FlashBackupClock.

    For example,

    debugSession.flash.options.setBoolean("FlashBackupClock",true);

    Please try it out and let me know if you have additional questions.

    Thanks,

    Ricky

  • Thanks Ricky for your quick response. This works fine for me.

    Thanks,

    Sumith

  • All is working very well now.

    Perhaps a better user's guide with more detail on loading and running the debugger.

    The F28M35H52C1  is an awesome chip.  I intend on usign the M36 for my next design, I just need to get support for installing the BGA on my design.