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.

Register value shows opposite value

Hi,

This is the C5515 DSP MCU.

I'm currently reading and running through a code... The code seems right and follows the datasheet rules. However, I noticed a strange phenomenon with the EN bit as shown in figure 1. 

Figure 1. 

The datasheet states the following for this bit[15], as shown below.

The CCS debugger displays the opposite Disable/Enable status next to the bit number... 

Its pretty much misleading, the meaning of 0 and 1 for the EN bit. How could I fix this?

  • Alvaro Garay said:
    How could I fix this?

    The CCS debugger reads device XML files for the register definitions.

    Looking at a CCS 6.1.2 installation shows the the <CCS_install_root>\ccsv6\ccs_base\common\targetdb\Modules\C5515\cslr_dma_001.xml file with the following incorrect encoding for the EN bit in the the DMACH0TCR2 register:

         <register id="DMACH0TCR2" acronym="DMACH0TCR2" page="2" offset="0X0005" width="16" description="Controls the transfer context for the DMA channel.">
    <bitfield id="EN" width="1" begin="15" end="15" resetval="0" description="Channel enable bit. Use EN to enable or disable transfers in the channel. The DMA controller clears EN once a block transfer in the channel is complete." range="" rwaccess="RW">
    <bitenum id="ENABLE" value="0" token="ENABLE" description="The channel is disabled. The channel cannot be serviced by the DMA controller. If DMA burst transfer is ongoing in the channel, the DMA controller allows the burst transfer to complete.   Note: When you write a 0 to this bit, you must also write a 0 to the SYNCMODE bit."/>
    <bitenum id="DISABLE" value="1" token="DISABLE" description="The channel is enabled. The channel can be serviced by the DMA in the next available time slot."/>
    </bitfield>
    

    You should be able to edit cslr_dma_001.xml file to correct the register encoding displayed by the CCS debugger.

    [The register definitions are cached, so you may need to restart CCS to cause it pick up the changed files]

  • thanks, it works!