4.17. Creating a concatenated register

The example used in this procedure creates a concatenated register C_R8_R9_concat for the RVISS Debug Configuration as follows:

The example uses the blank BCD file created in Creating a BCD file to use as a template.

If you want to use an enumeration to set the values of your concatenated register, then you must create it before you create the register.

To create a concatenated register:

  1. Select Target → Connect to Target... from the Code window main menu to open the Connect to Target window.

  2. Locate the RVISS_1 Debug Configuration:

    1. Select Configuration from the Grouped By list.

    2. Expand the required Debug Interface. For this example, expand RealView Instruction Set Simulator (RVISS).

    3. Expand the RVISS Debug Configuration.

    4. Make sure that the ARM926EJ-S target is disconnected on the Debug Configuration.

  3. Right-click on the RVISS_1 Debug Configuration to display the context menu.

  4. Select Properties... from the context menu to open the Connection Properties dialog box.

  5. Click the Advanced button to open the Connection Properties window. The settings group for the Debug Configuration is selected (in this example, CONNECTION=RVISS_1).

    Note

    If you have followed the examples in previous sections, then you might already have the MP3 BoardChip definition assigned. If so, then skip the next step.

  6. Assign the required BoardChip definition to the connection:

    1. Right-click on the BoardChip_name setting in the right pane to display the context menu.

    2. Select MP3 from the context menu.

  7. Locate the board/chip definition where you want to define the custom memory mapped registers:

    1. Right-click on the *BoardChip_name MP3 setting in the right pane to display the context menu.

    2. Select Jump to Definition from the context menu.

      The BOARD=MP3 group is selected in the BCD file.

  8. Expand the following board/chip definition groups in turn:

    1. *BOARD=MP3

    2. *Advanced_Information

    3. *ARM (or the corresponding name specified in your board/chip definition)

    4. Concat_Register

  9. Create the concatenated register as follows:

    1. Rename the Default block to C_R8_R9_concat.

      Note

      This specifies the concatenated register symbol name, which you can reference using @name. For example, cexpression @C_R8_R9_concat.

    2. Double-click on C_R8_R9_concat in the right pane.

      The settings for the concatenated register are displayed.

    3. Change the C_R8_R9_concat settings to the values shown in Table 4.3. If you enter the Low_mask and High_mask values in decimal, then they are displayed as hexadecimal.

      Table 4.3. C_R8_R9_concat settings

      SettingValue
      Low_nameR8
      Low_shift16
      Low_mask0xFFFF
      High_nameR9
      High_shift

      -16 (left shift)

      High_mask0xFFFF0000
      Gui_nameR8 and R9 combined

      Note

      If you have followed the examples in previous sections, then you might already have the MP3_REGS block in the Register_Window group. If so, then use the MP3_REGS block instead of Default for the next step.

  10. Create the Registers view tab to view the concatenated register:

    1. Double-click on the Register_Window group in the left pane.

    2. Rename the Default block to Concat_regs.

    3. Select Concat_regs to display the related settings.

    4. Right-click on Line to display the context menu.

    5. Select Edit Value... from the context menu.

    6. Enter C_R8_R9_concat. Remember to press Enter to complete the entry.

  11. Select File → Save and Close from the menu to save your changes and close the Connection Properties window.

  12. Click the OK button to close the Connection Properties dialog box.

See also:

Copyright © 2002-2011 ARM. All rights reserved.ARM DUI 0182N
Non-ConfidentialID052111