.. _sysconfig-board-files:

Configure The Board Files with SysConfig
----------------------------------------

The board view shows you what pins are available on your board, and what
peripherals are assigned to what pins. Hover over each pin for more information.

.. figure:: resources/board_view_cc23xx.png
    :align: center

Enabled and configured peripherals are displayed with a green symbols. To add a
new peripheral, press the plus sign next to the peripheral type. The ``USE CUSTOM BOARD``
button give you the freedom to pick any compatible device pin according to your custom
board without warning. Follow the `custom hardware <../cc23xx/custom-hardware-cc23xx.html>`_
section for more information. 

.. _sysconfig-reserve-peripherals:

Reserve Peripheral(s)
---------------------

Certain use cases may require preventing SysConfig from generating
the configuration of specific peripherals.

Examples of use cases requiring to reserve peripherals are:

* dynamic re-configuration of a peripheral
* leveraging the Sensor Controller (on devices enabling it)
* already handling certain peripherals configuration
* with hardware constraints preventing to use certain peripherals 
  (typically GPIOs)
* peripherals reserved for future use

Below are the steps required to utilize the Reserve Peripherals feature.

1. Open the ``.syscfg`` file using the SysConfig GUI

2. Open the panel "Reserve Peripherals"

   .. figure:: resources/syscfg-reserve-peripheral-pannel_cc23xx.png

3. Reserve the resources

   .. figure:: resources/syscfg-reserve-gpio_cc23xx.png

      Reserve a peripheral using SysConfig. This image shows how to reserve DIO 19.

SysConfig ensures no resource conflict occurs. In case no solution
can be found, an error is raised.

.. _sec-sysconfig-migrate-device:

Hardware View
-------------

The Hardware view may be used to add software modules for supporting hardware
resources on EVMs or LaunchPads. The same capability could be done in the
Software view by adding a hardware. However the Hardware view provides a
hardware-first perspective to show which software could be used with hardware
resources.

    .. figure:: /sysconfig/resources/syscfg_hardware_view_cc23xx.png
        :align: center

        Sysconfig Hardware View

|SLA| also contains a SysConfig training module for most of the platform SDKs
in the Tools folder.

.. Uncomment the migrating once we have another cc23xx board variant avaible
    Migrating Board Variant
    -----------------------

    Sysconfig may also be used to migrate a given project from one board to another
    compatible board.

    .. attention::

        Not all migration targets are currently enabled or fully supported, and may
        require additional steps. In particular, note that PHY and radio settings
        are not common across all devices. A migration may result in the loss of
        current PHY and radio configurations and/or require the user to update
        settings such as RF commands and high PA setup. For more migration
        information please refer to the guidelines shown in step 3.

    Here are the steps:

    1. Check the current device variant, by right-clicking on the project, then
    select ``Properties``.
    Now, you can see the device variant as shown here:

        .. figure:: /sysconfig/resources/board_migration/check_orig_variant_cc23xx.png
            :align: center

            Original Device Variant

    2. Open the project's .syscfg file, navigate to Device view (third icon in the top right hand corner), then click
    ``SWITCH``.

        .. figure:: /sysconfig/resources/board_migration/open_device_view_cc23xx.png
            :align: center

            Sysconfig Device View

    3. The guidelines for migration on your specific project will be shown, and may
    differ from the screenshot. Please consider the guidelines while using this
    migration feature.
    Now, select a compatible device for migration, click ``CONFIRM``, and ctrl-s to
    save the .syscfg file.

        .. figure:: /sysconfig/resources/board_migration/select_migrate_target_cc23xx.png
            :align: center

            Select Migration Target

    4. The device variant for the project should now be switched!
    This switch selects the board's respective target configuration file,
    chooses which driver libraries are used, and updates files to be generated by
    SysConfig. Like always, you can preview the changes to SysConfig-generated
    files (see :ref:`sysconfig-board-files`).
    Note that this switch leaves most of the project unaffected, such as project
    name and application files.

        .. figure:: /sysconfig/resources/board_migration/new_variant.PNG
            :align: center

            Verify Changed Device Variant