Migration Guide
$$$$$$$$$$$$$$$

Updating from previous SDKs
===========================

.. _sec-porting-guides:

Porting Guides
--------------
Porting guides are for incremental changes from previous SDKs.

.. toctree::
    :titlesonly:
                                                                                                                                                                                                                                                 
    cc26xx_to_cc23xx.rst
    cc2340r5_to_cc2340r22.rst
    cc2340r5_to_cc2340r53.rst

Migration Guides
----------------
Migration guides are used to migrate major changes, e.g. from one device or
configuration to another.

.. toctree::
    :titlesonly:

    /cc23xx/gpio-porting-guide-cc23xx.rst
    /cc23xx/uart_to_uart2.rst
    /cc23xx/software-on-cc2755R10.rst
    /sysconfig/zigbee-migration.rst

.. note:: 
    The F3 SDK 8.40 introduces the RNG Health Check functionality: the RNG 
    driver random number generation APIs will now perform an entropy check and not 
    generate any output if the entropy is not within acceptable ranges; in such case 
    random number generation should be re-attempted. This could cause existing 
    implementations of RNG to not work as expected.

.. code-block:: 
    :caption: Code snippet for checking RNG
    
    for(int i = 0; i < n; i++) //n should be set to at least 5 or 10
    {
        rclStatus = RCL_AdcNoise_get_samples_blocking(localNoiseInput, RNGLPF3RF_noiseInputWordLen);
        
        // Initialize the RNG driver noise input pointer with global noise input array from user //
        rclStatus = RNGLPF3RF_conditionNoiseToGenerateSeed(localNoiseInput);

        if(rclStatus = 0)
        {
        //RNG driver has succeeded generating a number
        break;
        }

        else if(i == (n-1))
        {
        //error handling, report error here
        }
    }
