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.

Reading I2C Registers from View->Memory->I/O



Recently I transferred my project from CCS 2.21 to CCS4.2 (TI5502), I able to view all the I2C Register via View->Memory->I/O  when running on my CCS 2.21 platform.  However, when I transitioned to the CCS 4.2 platform, I am having I2C issues.  I tried to view I2C Registers via the same method, but all registers are indicating a value of 0.  I know this is incorrect, because I added lines in my code to read these registsers and they contain non-zero value similar to the value read when running CCS 2.21.  Any ideas when these registers are not viewable in I/O space?

  • Bob, This is most likely a problem with the register definition files for C5505. We had another case where they were missing the page specifier so CCS was reading addresses on the program page instead of the IO page. I think there were some corrected files attached to the thread. I will see if I can find it. Regards, John
  • Here is a link to the thread I was thinking of.  It has a zip with a better set of register files.

    http://e2e.ti.com/support/development_tools/code_composer_studio/f/81/t/70033.aspx#254006

  • John - I followed the link and placed the new .XML files into the correct directory, but I still have the same problem.

  • Follow on to my response about it not fixing the problem.  I observed this with both sets of XML files, so I don't think it is related to the files.

    Once I hit my break point and look at the memory location 0x3C00 thru 0x3C0C, via View->Memory->I/O, like I explained before I don't see the I2C registers values.  Again, they are all 0.  However when I select 'debug active project' to re-run my debug session, values do show up in the memory range I specified above.  The problem is I can't see these values during a debug session, when I am stepping through the code.

  • Bob,

    You are correct that the xml files will not impact the memory view.

    This is really odd.  So the values are there when you connect, load & run to main (debug active project), but not later on during debug?  If CCS couldn't read those locations properly I would expect them to always be zero.  If you hit reset CPU do they change?

    John

  • I see the exact same problem with CCS 4.1 and C5505 USBstick v2.

    register view, uses program memory content when displaying registers instead  of I/O memory

    ie.

    I2S2.I2SSCTRL  0x1052

    indicating that the I2S2 channel is not enabled - which it is for sure.

    contents of program memory address 0x2A00 is 10H,52H.

    contents of I/O memory address 0x2A00 is 8082H which is the correct value.

     

  • Michael Steen Jensen said:
    register view, uses program memory content when displaying registers instead  of I/O memory

    The updated register xml files from this post should fix the issue with the register view. Did you give this a try already?

  • Hi Aarti

    No , since Bob wrote that it did not help and JohnS that it would not, I have not tried it.

    Instead I updated CCS to 4.2.3.0004 , but that did not fix the problem.

    Btw, in my previous CCS , bundled with USB stick v1, the register view did not show any peripheral registers at all - only the CPU registers. I did uninstall CCS before installing the one bundled with USB stick v2 but maybe this previous version has something to do with the problem - a CCS uninstall that did work completely ?.

    I will give the updated XML files a try later on..

    /MSJ

     

     

     

     

     

  • Michael Steen Jensen said:

    No , since Bob wrote that it did not help and JohnS that it would not, I have not tried it.


    I think they were talking about it not fixing an issue with the memory view. I would expect the updated xml files to display the I2C registers correctly in the register view though. Note that CCS 4.2.3 does not have these updated xml files so that version will not fix the issue. Please give those updated xml files a try when you get a chance and let us know if it helps.

     

  • it worked, thanks!

    one thing, having overwritten the XML files,  CCS started crashing (exit code 1)  every time a debug session was attempted.

    fix - delete the  workspace cache.