( function() {  var mapping = [{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_INTRODUCTION", "path":"GUID-1E4C7D61-B6A2-4B1F-B87D-832997E64CBF.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_ADCHS_DMA", "path":"GUID-BA9624B6-6AAE-4FEF-9952-0A7F6E918625.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_ADCHS_INTERRUPT", "path":"GUID-3D9238C5-CA18-4901-A36C-C74F87870CBC.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_ADCHS_POLLING", "path":"GUID-EC1C3E56-835C-4CD5-956A-D2F89BDD77A2.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_CACHE_MAINTENANCE_OPERATIONS", "path":"GUID-C8A6BFBC-FFEE-4076-B5ED-00944E69A289.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_CMP_CONFIGURABLE_REFERENCE", "path":"GUID-C8C906D5-5DE2-4F7C-8391-51515DD885C8.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_CORETIMER_PERIODIC_INTERRUPT", "path":"GUID-3593E090-BE0A-45BB-BF62-94B6B99853F0.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_DMAC_MEMORY_TRANSFER", "path":"GUID-D921C1FC-6E0D-4F1F-B776-F6A062155250.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_DMAC_USART_ECHO", "path":"GUID-D7AB161A-F988-41F9-9FF3-92A872522435.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_DMT_TIMEOUT", "path":"GUID-8CFD257E-5B42-4761-81FC-6771312BF198.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_GPIO_INTERRUPT", "path":"GUID-ECA50179-DAF1-472C-82E1-4F246196B2A0.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_GPIO_POLLING", "path":"GUID-0F81FBBE-C079-421B-B7C2-9A32F704A783.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_I2C_EEPROM_READ_WRITE", "path":"GUID-BD4A0E69-2366-410A-8A7F-7205FF7ED073.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_ICAP_CAPTURE_MODE", "path":"GUID-6F8B4C3D-FD02-4DBD-8BAB-BB8160B4B373.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_NVM_FLASH_READ_WRITE", "path":"GUID-D9C9ACA9-7E7A-4E20-8407-E69F32F4723B.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_OCMP_COMPARE_MODE", "path":"GUID-F89164AE-FE58-470E-84F8-879F55EB6D6A.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_RNG_RANDOM_NUMBER", "path":"GUID-B99EADAD-54F3-4C8D-B862-14B1E8D10A91.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_RTCC_ALARM_INTERRUPT", "path":"GUID-38CC1464-3A67-4A75-9186-4E73EAFA5FB4.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_SPI_BLOCKING", "path":"GUID-C9BD6D1E-32B8-4D78-9363-384682F7D510.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_SPI_INTERRUPT", "path":"GUID-42364210-9FF0-4526-B3FA-62FD3E634280.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_SQI_FLASH_READ_WRITE", "path":"GUID-25C1DA43-34BE-465B-BD03-1526B6975DC1.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_TMR_PERIODIC_INTERRUPT", "path":"GUID-F9ECAC5A-B6CD-4BFD-A211-337229795E45.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_TMR1_PERIODIC_INTERRUPT", "path":"GUID-3535C076-E618-4A5D-BEBE-8FC24970D18E.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_UART_ECHO_BLOCKING", "path":"GUID-6BB76404-282F-45BC-AC7B-325F3B65E1FA.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_UART_ECHO_INTERRUPT", "path":"GUID-6030EF00-226A-466A-83DD-74616C02399A.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_UART_RING_BUFFER", "path":"GUID-1619D356-AEBF-45FE-99DC-68977ECBB3CD.html"},{"appname":"", "appid":"CSP_APPS_PIC32MZ_DA_WDT_TIMEOUT", "path":"GUID-D150D137-0184-43AF-82AC-5BDCEC5DA296.html"}];
            var mchp = (function (mchp) {
                var mchp = mchp || {};
                var mapping = [];
        
                mchp.utils = {};
        
                mchp.utils.getQueryParam = function (name, url = window.location.href) {
                  name = name.replace(/[\[\]]/g, "\\$&");
                  var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"),
                    results = regex.exec(url);
                  if (!results) return null;
                  if (!results[2]) return "";
                  return decodeURIComponent(results[2].replace(/\+/g, " "));
                };

                mchp.utils.isFirefox = typeof InstallTrigger !== 'undefined';
        
                mchp.init = function (options) {
                  mchp.mapping = options.mapping || [];
                  mchp.bindEvents();
                };
        
                mchp.bindEvents = function () {
                    if (mchp.utils.isFirefox) {
                      window.onload = mchp.checkRedirect;
                    } else {
                      document.onreadystatechange = mchp.checkRedirect;
                    }
                };

                mchp.checkRedirect = function() {
                  var contextId = mchp.utils.getQueryParam("contextId") || "";
                  if (contextId && contextId != undefined) {
                    var record = mchp.mapping.find(function(x){
                      return x.appid && x.appid.toLowerCase() == contextId.toLowerCase();
                    });
                    if (record && record.path) {
                      window.stop();
                      window.location = record.path;
                    }
                  }
                };
        
                return {
                  init: mchp.init,
                };
              })();
        
              mchp.init({
                mapping: mapping
              });

        })();