text: <?xml version="1.0" encoding="utf-8"?>
  
  
  <!--****************************************************************************
  * \file smartio.cypersonality
  * \version 1.0.1
  *
  * \brief
  * Smart I/O personality description file.
  *
  ********************************************************************************
  * \copyright
  * Copyright 2018-2020 Cypress Semiconductor Corporation
  * SPDX-License-Identifier: Apache-2.0
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  * You may obtain a copy of the License at
  *
  *     http://www.apache.org/licenses/LICENSE-2.0
  *
  * Unless required by applicable law or agreed to in writing, software
  * distributed under the License is distributed on an "AS IS" BASIS,
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
  *****************************************************************************-->
  
  <Personality id="mxs40smartio" name="Smart I/O" version="1.0" path="Port" xmlns="http://cypress.com/xsd/cyhwpersonality_v1">
    <Dependencies>
      <IpBlock name="mxs40ioss" />
      <Resource name="ioss\.port\.smartio" used="true" />
    </Dependencies>
    <ExposedMembers />
    <Parameters>
      <!-- PDL documentation -->
      <ParamDoc id="pdlDoc" name="Configuration Help" group="Peripheral Documentation" default="file:///`${cy_libs_path()}`/docs/pdl_api_reference_manual/html/group__group__smartio.html" linkText="Open SmartIO Documentation" visible="true" desc="Opens the Peripheral Driver Library Documentation" />
    
      <!-- External tools -->
      <ParamCustom id="SmartIOConfigurator" name="Smart I/O Configurator" group="External Tools" default="0" path="`${cy_tools_path(&quot;smartio-configurator&quot;) . &quot;/smartio-configurator&quot;}`" modal="true" visible="true" editable="true" desc="Launch Smart I/O Configurator">
          <Arg value="`${&quot;--design=&quot; . cy_design_file()}`" />
          <Arg value="`${&quot;--resource=ioss[0].port[&quot; . getInstNumber(&quot;port&quot;) . &quot;].smartio[0]&quot;}`" />
      </ParamCustom>
  
      <!-- Debug Enable -->
      <ParamBool id="debug" name="Debug Flag" group="General" default="false" visible="false" editable="false" desc="Set this to true to expose all parameters" />
      
      <!--General-->
      <ParamChoice id="clkSrc" name="Clock Source" group="General" default="CY_SMARTIO_CLK_ASYNC" visible="`${(debug eq true)}`" editable="true" desc="Smart I/O instance clock source" >
        <Entry name="Signal on I/O terminal 0" value="CY_SMARTIO_CLK_IO0" visible="true" />
        <Entry name="Signal on I/O terminal 1" value="CY_SMARTIO_CLK_IO1" visible="true" />
        <Entry name="Signal on I/O terminal 2" value="CY_SMARTIO_CLK_IO2" visible="true" />
        <Entry name="Signal on I/O terminal 3" value="CY_SMARTIO_CLK_IO3" visible="true" />
        <Entry name="Signal on I/O terminal 4" value="CY_SMARTIO_CLK_IO4" visible="true" />
        <Entry name="Signal on I/O terminal 5" value="CY_SMARTIO_CLK_IO5" visible="true" />
        <Entry name="Signal on I/O terminal 6" value="CY_SMARTIO_CLK_IO6" visible="true" />
        <Entry name="Signal on I/O terminal 7" value="CY_SMARTIO_CLK_IO7" visible="true" />
        <Entry name="Signal on Chip terminal 0" value="CY_SMARTIO_CLK_CHIP0" visible="true" />
        <Entry name="Signal on Chip terminal 1" value="CY_SMARTIO_CLK_CHIP1" visible="true" />
        <Entry name="Signal on Chip terminal 2" value="CY_SMARTIO_CLK_CHIP2" visible="true" />
        <Entry name="Signal on Chip terminal 3" value="CY_SMARTIO_CLK_CHIP3" visible="true" />
        <Entry name="Signal on Chip terminal 4" value="CY_SMARTIO_CLK_CHIP4" visible="true" />
        <Entry name="Signal on Chip terminal 5" value="CY_SMARTIO_CLK_CHIP5" visible="true" />
        <Entry name="Signal on Chip terminal 6" value="CY_SMARTIO_CLK_CHIP6" visible="true" />
        <Entry name="Signal on Chip terminal 7" value="CY_SMARTIO_CLK_CHIP7" visible="true" />
        <Entry name="Peripheral clock divider (Active)" value="CY_SMARTIO_CLK_DIVACT" visible="true" />
        <Entry name="Peripheral clock divider (Deep-Sleep)" value="CY_SMARTIO_CLK_DIVDS" visible="true" />
        <Entry name="Peripheral clock divider (Hibernate)" value="CY_SMARTIO_CLK_DIVHIB" visible="true" />
        <Entry name="Low-Frequency Clock (Clk_LF)" value="CY_SMARTIO_CLK_LFCLK" visible="true" />
        <Entry name="Asynchronous" value="CY_SMARTIO_CLK_ASYNC" visible="true" />
      </ParamChoice>
  
      <ParamSignal port="clock[0]" name="Clock Divider" group="General" visible="`${(clkSrc eq CY_SMARTIO_CLK_DIVACT) || (clkSrc eq CY_SMARTIO_CLK_DIVDS) || (clkSrc eq CY_SMARTIO_CLK_DIVHIB)}`" desc="Peripheral clock divider to assign to the Smart I/O instance." canBeEmpty="`${!((clkSrc eq CY_SMARTIO_CLK_DIVACT) || (clkSrc eq CY_SMARTIO_CLK_DIVDS) || (clkSrc eq CY_SMARTIO_CLK_DIVHIB))}`" />
      <Repeat count="8">
        <ParamBool id="lutEn$idx"  name="LUT$idx Enable" group="General" default="false" visible="`${(debug eq true)}`" editable="true" desc="Enable/Disable LUT$idx configuration" />
      </Repeat>
      <ParamBool id="duEn"    name="DU Enable"   group="General" default="false" visible="`${(debug eq true)}`" editable="true" desc="Enable/Disable DU configuration" />
      <ParamBool id="hldOvr"  name="Hold Override" group="General" default="false" visible="true" editable="true" desc="Enable/Disable hold override (Deep-Sleep functionality)" />
  
      <!--I/O Terminal -->
      <Repeat count="8">
        <ParamBool id="hasIoIn$idx" group="Internal" name="has IO in signal" visible="false" editable="false" default="`${hasVisibleOption(&quot;io_in[$idx]&quot;)}`" desc="IO in signal available" />
        <ParamBool id="hasIoOut$idx" group="Internal" name="has IO out signal" visible="false" editable="false" default="`${hasVisibleOption(&quot;io_out[$idx]&quot;)}`" desc="IO out signal available" />
        <ParamBool id="hasAnyIo$idx" group="Internal" name="has any io connection" visible="false" editable="false" default="`${hasIoIn$idx || hasIoOut$idx}`" desc="any io connection available"/>
        <ParamChoice id="ioMode$idx" name="I/O terminal $idx mode" group="I/O Terminal" default="`${hasAnyIo$idx ? CY_SMARTIO_BYPASS : CY_SMARTIO_NONE}`" visible="`${(debug eq true)}`" editable="`${hasAnyIo$idx}`" desc="I/O terminal $idx signal mode/direction" >
          <Entry name="Bypass" value="CY_SMARTIO_BYPASS" visible="`${hasAnyIo$idx}`" />
          <Entry name="Input(Sync)" value="CY_SMARTIO_SYNC_INPUT" visible="`${(clkSrc ne CY_SMARTIO_CLK_ASYNC) &amp;&amp; hasIoIn$idx}`" />
          <Entry name="Input(Async)" value="CY_SMARTIO_ASYNC_INPUT" visible="`${hasIoIn$idx}`" />
          <Entry name="Output" value="CY_SMARTIO_OUTPUT" visible="`${hasIoOut$idx}`" />
          <Entry name="None" value="CY_SMARTIO_NONE" visible="true" />
        </ParamChoice>
        <ParamSignal port="io_in[$idx]" name="I/O terminal $idx input" group="I/O Terminal" visible="`${(ioMode$idx eq CY_SMARTIO_SYNC_INPUT) || (ioMode$idx eq CY_SMARTIO_ASYNC_INPUT)}`" desc="I/O terminal $idx input signal source" canBeEmpty="`${!((ioMode$idx eq CY_SMARTIO_SYNC_INPUT) || (ioMode$idx eq CY_SMARTIO_ASYNC_INPUT))}`" />
        <ParamSignal port="io_out[$idx]" name="I/O terminal $idx output" group="I/O Terminal" visible="`${(ioMode$idx eq CY_SMARTIO_OUTPUT)}`" desc="I/O terminal $idx output signal source" canBeEmpty="`${!((ioMode$idx eq CY_SMARTIO_OUTPUT))}`" />
      </Repeat>
  
      <!--Chip Terminal -->
      <Repeat count="8">
        <ParamBool id="chipInConnected$idx" group="Internal" name="chip in connected"  visible="false" editable="false" default="`${hasConnection(&quot;chip_in&quot;, $idx)}`" desc="chip in connected" />
        <ParamBool id="chipOutConnected$idx" group="Internal" name="chip out connected"  visible="false" editable="false" default="`${hasConnection(&quot;chip_out&quot;, $idx)}`" desc="chip out connected" />
        <ParamBool id="chipInoutConnected$idx" group="Internal" name="chip inout connected"  visible="false" editable="false" default="`${hasConnection(&quot;chip_inout&quot;, $idx)}`" desc="chip inout connected" />
        <ParamBool id="hasChipOut$idx" group="Internal" name="has chip out connection" visible="false" editable="false" default="`${hasVisibleOption(&quot;chip_out[$idx]&quot;)}`"  desc="chip out connection available" />
        <ParamBool id="hasChipIn$idx" group="Internal" name="has chip in connection" visible="false" editable="false" default="`${hasVisibleOption(&quot;chip_in[$idx]&quot;)}`" desc="chip in connection available" />
        <ParamBool id="hasChipInout$idx" group="Internal" name="has chip inout connection" visible="false" editable="false" default="`${hasVisibleOption(&quot;chip_inout[$idx]&quot;)}`" desc="chip inout connection available"/>
        <ParamBool id="hasAnyChip$idx" group="Internal" name="has any chip connection" visible="false" editable="false" default="`${hasChipIn$idx || hasChipOut$idx || hasChipInout$idx}`" desc="any chip connection available"/>
        
        <!-- Chip_in and chip_out's visibility expressions appear reversed. They are not. The in/out are with respect to the chip -->
        <ParamChoice id="chipMode$idx" name="Chip terminal $idx mode" group="Chip Terminal" default="`${hasAnyChip$idx &amp;&amp; hasAnyIo$idx ? CY_SMARTIO_BYPASS : CY_SMARTIO_NONE}`" visible="`${(debug eq true)}`" editable="`${hasAnyChip$idx}`" desc="Chip terminal $idx signal mode/direction" >
          <Entry name="Bypass" value="CY_SMARTIO_BYPASS" visible="`${hasAnyChip$idx &amp;&amp; hasAnyIo$idx}`" />
          <Entry name="Input(Sync)" value="CY_SMARTIO_SYNC_INPUT" visible="`${(clkSrc ne CY_SMARTIO_CLK_ASYNC) &amp;&amp; (hasChipOut$idx || hasChipInout$idx)}`" />
          <Entry name="Input(Async)" value="CY_SMARTIO_ASYNC_INPUT" visible="`${hasChipOut$idx || hasChipInout$idx}`" />
          <Entry name="Output" value="CY_SMARTIO_OUTPUT" visible="`${hasChipIn$idx || hasChipInout$idx}`" />
          <Entry name="None" value="CY_SMARTIO_NONE" visible="true" />
        </ParamChoice>
        <ParamSignal port="chip_in[$idx]" name="Chip terminal $idx output" group="Chip Terminal" visible="`${(chipMode$idx eq CY_SMARTIO_OUTPUT)}`" desc="Chip terminal $idx output signal source" canBeEmpty="`${!(chipMode$idx eq CY_SMARTIO_OUTPUT) || chipInoutConnected$idx}`" />
        <ParamSignal port="chip_out[$idx]" name="Chip terminal $idx input" group="Chip Terminal" visible="`${(chipMode$idx eq CY_SMARTIO_SYNC_INPUT) || (chipMode$idx eq CY_SMARTIO_ASYNC_INPUT)}`" desc="Chip terminal $idx input signal source" canBeEmpty="`${!((chipMode$idx eq CY_SMARTIO_SYNC_INPUT) || (chipMode$idx eq CY_SMARTIO_ASYNC_INPUT)) || chipInoutConnected$idx}`" />
        <ParamSignal port="chip_inout[$idx]" name="Chip terminal $idx inout" group="Chip Terminal" visible="`${(chipMode$idx eq CY_SMARTIO_OUTPUT) || (chipMode$idx eq CY_SMARTIO_SYNC_INPUT) || (chipMode$idx eq CY_SMARTIO_ASYNC_INPUT)}`" desc="Chip terminal $idx inout signal source" canBeEmpty="`${!((chipMode$idx eq CY_SMARTIO_OUTPUT) || (chipMode$idx eq CY_SMARTIO_SYNC_INPUT) || (chipMode$idx eq CY_SMARTIO_ASYNC_INPUT)) || chipInConnected$idx || chipOutConnected$idx}`" />
      </Repeat>
  
      <!--LUTs -->
      <Repeat count="8">
        <ParamChoice id="lut$idxOpcode" name="Op-code" group="LUT$idx" default="CY_SMARTIO_LUTOPC_COMB" visible="`${(debug eq true)}`" editable="true" desc="LUT$idx opcode" >
          <Entry name="Combinatorial output" value="CY_SMARTIO_LUTOPC_COMB" visible="true" />
          <Entry name="TR2 gated, combinatorial output" value="CY_SMARTIO_LUTOPC_GATED_TR2" visible="`${(clkSrc ne CY_SMARTIO_CLK_ASYNC)}`" />
          <Entry name="Sequential (gated) output" value="CY_SMARTIO_LUTOPC_GATED_OUT" visible="`${(clkSrc ne CY_SMARTIO_CLK_ASYNC)}`" />
          <Entry name="Asynchronous Set/Reset mode" value="CY_SMARTIO_LUTOPC_ASYNC_SR" visible="`${(clkSrc ne CY_SMARTIO_CLK_ASYNC)}`" />
        </ParamChoice>
  
        <ParamRange id="lut$idxMap" name="LUT mapping" group="LUT$idx" default="0" min="0" max="`${pow(2, 8)-1}`" resolution="1" visible="`${(debug eq true)}`" editable="true" desc="LUT truth table: LUT out = 3'b{TR2,TR1,TR0}" />
        
        <ParamChoice id="lut$idxTr0" name="Input TR0" group="LUT$idx" default="CY_SMARTIO_LUTTR_INVALID" visible="`${(debug eq true)}`" editable="true" desc="LUT$idx input trigger 0 selection" >
          <Entry name="DU" value="CY_SMARTIO_LUTTR_DU_OUT" visible="true" />
          <Entry name="LUT1" value="CY_SMARTIO_LUTTR_LUT1_OUT" visible="true" />
          <Entry name="LUT2" value="CY_SMARTIO_LUTTR_LUT2_OUT" visible="true" />
          <Entry name="LUT3" value="CY_SMARTIO_LUTTR_LUT3_OUT" visible="true" />
          <Entry name="LUT4" value="CY_SMARTIO_LUTTR_LUT4_OUT" visible="true" />
          <Entry name="LUT5" value="CY_SMARTIO_LUTTR_LUT5_OUT" visible="true" />
          <Entry name="LUT6" value="CY_SMARTIO_LUTTR_LUT6_OUT" visible="true" />
          <Entry name="LUT7" value="CY_SMARTIO_LUTTR_LUT7_OUT" visible="true" />
          <Entry name="Chip 0" value="CY_SMARTIO_LUTTR_CHIP0" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP0)}`" />
          <Entry name="Chip 1" value="CY_SMARTIO_LUTTR_CHIP1" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP1)}`" />
          <Entry name="Chip 2" value="CY_SMARTIO_LUTTR_CHIP2" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP2)}`" />
          <Entry name="Chip 3" value="CY_SMARTIO_LUTTR_CHIP3" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP3)}`" />
          <Entry name="Chip 4" value="CY_SMARTIO_LUTTR_CHIP4" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP4)}`" />
          <Entry name="Chip 5" value="CY_SMARTIO_LUTTR_CHIP5" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP5)}`" />
          <Entry name="Chip 6" value="CY_SMARTIO_LUTTR_CHIP6" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP6)}`" />
          <Entry name="Chip 7" value="CY_SMARTIO_LUTTR_CHIP7" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP7)}`" />
          <Entry name="I/O 0" value="CY_SMARTIO_LUTTR_IO0" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO0)}`" />
          <Entry name="I/O 1" value="CY_SMARTIO_LUTTR_IO1" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO1)}`" />
          <Entry name="I/O 2" value="CY_SMARTIO_LUTTR_IO2" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO2)}`" />
          <Entry name="I/O 3" value="CY_SMARTIO_LUTTR_IO3" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO3)}`" />
          <Entry name="I/O 4" value="CY_SMARTIO_LUTTR_IO4" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO4)}`" />
          <Entry name="I/O 5" value="CY_SMARTIO_LUTTR_IO5" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO5)}`" />
          <Entry name="I/O 6" value="CY_SMARTIO_LUTTR_IO6" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO6)}`" />
          <Entry name="I/O 7" value="CY_SMARTIO_LUTTR_IO7" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO7)}`" />
          <Entry name="None" value="CY_SMARTIO_LUTTR_INVALID" visible="true" />
        </ParamChoice>
  
        <ParamChoice id="lut$idxTr1" name="Input TR1" group="LUT$idx" default="CY_SMARTIO_LUTTR_INVALID" visible="`${(debug eq true)}`" editable="true" desc="LUT$idx input trigger 1 selection" >
          <Entry name="LUT0" value="CY_SMARTIO_LUTTR_LUT0_OUT" visible="true" />
          <Entry name="LUT1" value="CY_SMARTIO_LUTTR_LUT1_OUT" visible="true" />
          <Entry name="LUT2" value="CY_SMARTIO_LUTTR_LUT2_OUT" visible="true" />
          <Entry name="LUT3" value="CY_SMARTIO_LUTTR_LUT3_OUT" visible="true" />
          <Entry name="LUT4" value="CY_SMARTIO_LUTTR_LUT4_OUT" visible="true" />
          <Entry name="LUT5" value="CY_SMARTIO_LUTTR_LUT5_OUT" visible="true" />
          <Entry name="LUT6" value="CY_SMARTIO_LUTTR_LUT6_OUT" visible="true" />
          <Entry name="LUT7" value="CY_SMARTIO_LUTTR_LUT7_OUT" visible="true" />
          <Entry name="Chip 0" value="CY_SMARTIO_LUTTR_CHIP0" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP0)}`" />
          <Entry name="Chip 1" value="CY_SMARTIO_LUTTR_CHIP1" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP1)}`" />
          <Entry name="Chip 2" value="CY_SMARTIO_LUTTR_CHIP2" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP2)}`" />
          <Entry name="Chip 3" value="CY_SMARTIO_LUTTR_CHIP3" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP3)}`" />
          <Entry name="Chip 4" value="CY_SMARTIO_LUTTR_CHIP4" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP4)}`" />
          <Entry name="Chip 5" value="CY_SMARTIO_LUTTR_CHIP5" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP5)}`" />
          <Entry name="Chip 6" value="CY_SMARTIO_LUTTR_CHIP6" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP6)}`" />
          <Entry name="Chip 7" value="CY_SMARTIO_LUTTR_CHIP7" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP7)}`" />
          <Entry name="I/O 0" value="CY_SMARTIO_LUTTR_IO0" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO0)}`" />
          <Entry name="I/O 1" value="CY_SMARTIO_LUTTR_IO1" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO1)}`" />
          <Entry name="I/O 2" value="CY_SMARTIO_LUTTR_IO2" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO2)}`" />
          <Entry name="I/O 3" value="CY_SMARTIO_LUTTR_IO3" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO3)}`" />
          <Entry name="I/O 4" value="CY_SMARTIO_LUTTR_IO4" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO4)}`" />
          <Entry name="I/O 5" value="CY_SMARTIO_LUTTR_IO5" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO5)}`" />
          <Entry name="I/O 6" value="CY_SMARTIO_LUTTR_IO6" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO6)}`" />
          <Entry name="I/O 7" value="CY_SMARTIO_LUTTR_IO7" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO7)}`" />
          <Entry name="None" value="CY_SMARTIO_LUTTR_INVALID" visible="true" />
        </ParamChoice>
  
        <ParamChoice id="lut$idxTr2" name="Input TR2" group="LUT$idx" default="CY_SMARTIO_LUTTR_INVALID" visible="`${(debug eq true)}`" editable="true" desc="LUT$idx input trigger 2 selection" >
          <Entry name="LUT0" value="CY_SMARTIO_LUTTR_LUT0_OUT" visible="true" />
          <Entry name="LUT1" value="CY_SMARTIO_LUTTR_LUT1_OUT" visible="true" />
          <Entry name="LUT2" value="CY_SMARTIO_LUTTR_LUT2_OUT" visible="true" />
          <Entry name="LUT3" value="CY_SMARTIO_LUTTR_LUT3_OUT" visible="true" />
          <Entry name="LUT4" value="CY_SMARTIO_LUTTR_LUT4_OUT" visible="true" />
          <Entry name="LUT5" value="CY_SMARTIO_LUTTR_LUT5_OUT" visible="true" />
          <Entry name="LUT6" value="CY_SMARTIO_LUTTR_LUT6_OUT" visible="true" />
          <Entry name="LUT7" value="CY_SMARTIO_LUTTR_LUT7_OUT" visible="true" />
          <Entry name="Chip 0" value="CY_SMARTIO_LUTTR_CHIP0" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP0)}`" />
          <Entry name="Chip 1" value="CY_SMARTIO_LUTTR_CHIP1" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP1)}`" />
          <Entry name="Chip 2" value="CY_SMARTIO_LUTTR_CHIP2" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP2)}`" />
          <Entry name="Chip 3" value="CY_SMARTIO_LUTTR_CHIP3" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP3)}`" />
          <Entry name="Chip 4" value="CY_SMARTIO_LUTTR_CHIP4" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP4)}`" />
          <Entry name="Chip 5" value="CY_SMARTIO_LUTTR_CHIP5" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP5)}`" />
          <Entry name="Chip 6" value="CY_SMARTIO_LUTTR_CHIP6" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP6)}`" />
          <Entry name="Chip 7" value="CY_SMARTIO_LUTTR_CHIP7" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_CHIP7)}`" />
          <Entry name="I/O 0" value="CY_SMARTIO_LUTTR_IO0" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO0)}`" />
          <Entry name="I/O 1" value="CY_SMARTIO_LUTTR_IO1" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO1)}`" />
          <Entry name="I/O 2" value="CY_SMARTIO_LUTTR_IO2" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO2)}`" />
          <Entry name="I/O 3" value="CY_SMARTIO_LUTTR_IO3" visible="`${($idx lt 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO3)}`" />
          <Entry name="I/O 4" value="CY_SMARTIO_LUTTR_IO4" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO4)}`" />
          <Entry name="I/O 5" value="CY_SMARTIO_LUTTR_IO5" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO5)}`" />
          <Entry name="I/O 6" value="CY_SMARTIO_LUTTR_IO6" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO6)}`" />
          <Entry name="I/O 7" value="CY_SMARTIO_LUTTR_IO7" visible="`${($idx ge 4) &amp;&amp; (clkSrc ne CY_SMARTIO_CLK_IO7)}`" />
          <Entry name="None" value="CY_SMARTIO_LUTTR_INVALID" visible="true" />
        </ParamChoice>
  
      </Repeat>
  
      <!--DU -->
      <ParamChoice id="duOpcode" name="Op-code" group="DU" default="CY_SMARTIO_DUOPC_INCR" visible="`${(debug eq true)}`" editable="true" desc="DU opcode" >
        <Entry name="Increment" value="CY_SMARTIO_DUOPC_INCR" visible="true" />
        <Entry name="Decrement" value="CY_SMARTIO_DUOPC_DECR" visible="true" />
        <Entry name="Increment and wrap" value="CY_SMARTIO_DUOPC_INCR_WRAP" visible="true" />
        <Entry name="Decrement and wrap" value="CY_SMARTIO_DUOPC_DECR_WRAP" visible="true" />
        <Entry name="Increment/Decrement" value="CY_SMARTIO_DUOPC_INCR_DECR" visible="true" />
        <Entry name="Increment/Decrement and wrap" value="CY_SMARTIO_DUOPC_INCR_DECR_WRAP" visible="true" />
        <Entry name="Rotate Right" value="CY_SMARTIO_DUOPC_ROR" visible="true" />
        <Entry name="Shift Right" value="CY_SMARTIO_DUOPC_SHR" visible="true" />
        <Entry name="AND, OR" value="CY_SMARTIO_DUOPC_AND_OR" visible="true" />
        <Entry name="Shift right and Majority 3" value="CY_SMARTIO_DUOPC_SHR_MAJ3" visible="true" />
        <Entry name="Shift right and Compare" value="CY_SMARTIO_DUOPC_SHR_EQL" visible="true" />
      </ParamChoice>
  
      <ParamChoice id="duSize" name="Size" group="DU" default="CY_SMARTIO_DUSIZE_8" visible="`${(debug eq true)}`" editable="true" desc="DU operand size/width" >
        <Entry name="1-bit size/width operand" value="CY_SMARTIO_DUSIZE_1" visible="true" />
        <Entry name="2-bits size/width operand" value="CY_SMARTIO_DUSIZE_2" visible="true" />
        <Entry name="3-bits size/width operand" value="CY_SMARTIO_DUSIZE_3" visible="true" />
        <Entry name="4-bits size/width operand" value="CY_SMARTIO_DUSIZE_4" visible="true" />
        <Entry name="5-bits size/width operand" value="CY_SMARTIO_DUSIZE_5" visible="true" />
        <Entry name="6-bits size/width operand" value="CY_SMARTIO_DUSIZE_6" visible="true" />
        <Entry name="7-bits size/width operand" value="CY_SMARTIO_DUSIZE_7" visible="true" />
        <Entry name="8-bits size/width operand" value="CY_SMARTIO_DUSIZE_8" visible="true" />
      </ParamChoice>
      
      <ParamChoice id="duTr0" name="Input TR0" group="DU" default="CY_SMARTIO_DUTR_ZERO" visible="`${(debug eq true)}`" editable="true" desc="DU input trigger 0 selection" >
        <Entry name="Constant 0" value="CY_SMARTIO_DUTR_ZERO" visible="true" />
        <Entry name="Constant 1" value="CY_SMARTIO_DUTR_ONE" visible="true" />
        <Entry name="DU" value="CY_SMARTIO_DUTR_DU_OUT" visible="true" />
        <Entry name="LUT0" value="CY_SMARTIO_DUTR_LUT0_OUT" visible="true" />
        <Entry name="LUT1" value="CY_SMARTIO_DUTR_LUT1_OUT" visible="true" />
        <Entry name="LUT2" value="CY_SMARTIO_DUTR_LUT2_OUT" visible="true" />
        <Entry name="LUT3" value="CY_SMARTIO_DUTR_LUT3_OUT" visible="true" />
        <Entry name="LUT4" value="CY_SMARTIO_DUTR_LUT4_OUT" visible="true" />
        <Entry name="LUT5" value="CY_SMARTIO_DUTR_LUT5_OUT" visible="true" />
        <Entry name="LUT6" value="CY_SMARTIO_DUTR_LUT6_OUT" visible="true" />
        <Entry name="LUT7" value="CY_SMARTIO_DUTR_LUT7_OUT" visible="true" />
      </ParamChoice>
  
      <ParamChoice id="duTr1" name="Input TR1" group="DU" default="CY_SMARTIO_DUTR_ZERO" visible="`${(debug eq true)}`" editable="true" desc="DU input trigger 1 selection" >
        <Entry name="Constant 0" value="CY_SMARTIO_DUTR_ZERO" visible="true" />
        <Entry name="Constant 1" value="CY_SMARTIO_DUTR_ONE" visible="true" />
        <Entry name="DU" value="CY_SMARTIO_DUTR_DU_OUT" visible="true" />
        <Entry name="LUT0" value="CY_SMARTIO_DUTR_LUT0_OUT" visible="true" />
        <Entry name="LUT1" value="CY_SMARTIO_DUTR_LUT1_OUT" visible="true" />
        <Entry name="LUT2" value="CY_SMARTIO_DUTR_LUT2_OUT" visible="true" />
        <Entry name="LUT3" value="CY_SMARTIO_DUTR_LUT3_OUT" visible="true" />
        <Entry name="LUT4" value="CY_SMARTIO_DUTR_LUT4_OUT" visible="true" />
        <Entry name="LUT5" value="CY_SMARTIO_DUTR_LUT5_OUT" visible="true" />
        <Entry name="LUT6" value="CY_SMARTIO_DUTR_LUT6_OUT" visible="true" />
        <Entry name="LUT7" value="CY_SMARTIO_DUTR_LUT7_OUT" visible="true" />
      </ParamChoice>
  
      <ParamChoice id="duTr2" name="Input TR2" group="DU" default="CY_SMARTIO_DUTR_ZERO" visible="`${(debug eq true)}`" editable="true" desc="DU input trigger 2 selection" >
        <Entry name="Constant 0" value="CY_SMARTIO_DUTR_ZERO" visible="true" />
        <Entry name="Constant 1" value="CY_SMARTIO_DUTR_ONE" visible="true" />
        <Entry name="DU" value="CY_SMARTIO_DUTR_DU_OUT" visible="true" />
        <Entry name="LUT0" value="CY_SMARTIO_DUTR_LUT0_OUT" visible="true" />
        <Entry name="LUT1" value="CY_SMARTIO_DUTR_LUT1_OUT" visible="true" />
        <Entry name="LUT2" value="CY_SMARTIO_DUTR_LUT2_OUT" visible="true" />
        <Entry name="LUT3" value="CY_SMARTIO_DUTR_LUT3_OUT" visible="true" />
        <Entry name="LUT4" value="CY_SMARTIO_DUTR_LUT4_OUT" visible="true" />
        <Entry name="LUT5" value="CY_SMARTIO_DUTR_LUT5_OUT" visible="true" />
        <Entry name="LUT6" value="CY_SMARTIO_DUTR_LUT6_OUT" visible="true" />
        <Entry name="LUT7" value="CY_SMARTIO_DUTR_LUT7_OUT" visible="true" />
      </ParamChoice>
  
       <ParamChoice id="duData0" name="Input DATA0" group="DU" default="CY_SMARTIO_DUDATA_ZERO" visible="`${(debug eq true)}`" editable="true" desc="DU input DATA0 selection" >
        <Entry name="Constant 0" value="CY_SMARTIO_DUDATA_ZERO" visible="true" />
        <Entry name="Chip signal [7:0]" value="CY_SMARTIO_DUDATA_CHIP" visible="true" />
        <Entry name="I/O signal [7:0]" value="CY_SMARTIO_DUDATA_IO" visible="true" />
        <Entry name="DATA Register" value="CY_SMARTIO_DUDATA_DATAREG" visible="true" />
      </ParamChoice>
  
      <ParamChoice id="duData1" name="Input DATA1" group="DU" default="CY_SMARTIO_DUDATA_ZERO" visible="`${(debug eq true)}`" editable="true" desc="DU input DATA1 selection" >
        <Entry name="Constant 0" value="CY_SMARTIO_DUDATA_ZERO" visible="true" />
        <Entry name="Chip signal [7:0]" value="CY_SMARTIO_DUDATA_CHIP" visible="true" />
        <Entry name="I/O signal [7:0]" value="CY_SMARTIO_DUDATA_IO" visible="true" />
        <Entry name="DATA Register" value="CY_SMARTIO_DUDATA_DATAREG" visible="true" />
      </ParamChoice>
  
      <ParamRange id="duDataReg" name="DATA Register" group="DU" default="0" min="0" max="`${pow(2, 8)-1}`" resolution="1" visible="`${(debug eq true)}`" editable="true" desc="DU DATA 8-bit Register value" />
      
      <!--Config-->
      <ParamBool id="inFlash" name="Store Config in Flash" group="Advanced" default="true" visible="true" editable="true" desc="Controls whether the configuration structure is stored in Flash (const, true) or SRAM (not const, false)." />
      
      <!-- Port instance number -->
      <ParamString id="InstNumber" name="InstNumber" group="Internal" default="`${getInstNumber(&quot;port&quot;)}`" visible="false" editable="false" desc="Port Instance name number." />
      
      <!-- Peripheral clock divider connection -->
      <ParamString id="pclk" name="PCLK" group="Internal" default="`${getBlockFromSignal(&quot;clock[0]&quot;)}`" visible="false" editable="false" desc="Connected peripheral clock divider (PCLK)." />
      <ParamBool id="pclkOk" name="PCLK Valid" group="Internal" default="`${hasConnection(&quot;clock&quot;, 0) &amp;&amp; isBlockUsed(pclk)}`" visible="false" editable="false" desc="Checks whether there is a PCLK connected and enabled." />
      <ParamString id="pclkDst" name="PCLK Destination" group="Internal" default="PCLK_SMARTIO`${getInstNumber(&quot;port&quot;)}`_CLOCK" visible="false" editable="false" desc="Generates PCLK connection define." />
    </Parameters>
  
    <DRCs>
      <!--ioMode DRCs-->
      <DRC type="ERROR" text="The complementary chip terminal [$idx] is set to &quot;Bypass&quot; mode. Either set the I/O terminal [$idx] to &quot;Bypass&quot; mode or update the chip terminal [$idx] mode." condition="`${(chipMode$idx eq CY_SMARTIO_BYPASS) &amp;&amp; (ioMode$idx ne CY_SMARTIO_BYPASS)}`" repeatCount="8" />
      <!--chipMode DRCs-->
      <DRC type="ERROR" text="The complementary I/O terminal [$idx] is set to &quot;Bypass&quot; mode. Either set the chip terminal [$idx] to &quot;Bypass&quot; mode or update the I/O terminal [$idx] mode." condition="`${(chipMode$idx ne CY_SMARTIO_BYPASS) &amp;&amp; (ioMode$idx eq CY_SMARTIO_BYPASS)}`" repeatCount="8" />
      <!--LUT chip terminal clock DRCs-->
      <DRC type="ERROR" text="Chip terminal [$idx] cannot simultaneously be used as an input to a LUT$idx input trigger and be used as the Smart I/O block clock source." condition="`${((lut$idxTr0 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut$idxTr1 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut$idxTr2 eq CY_SMARTIO_LUTTR_CHIP$idx)) &amp;&amp; (clkSrc eq CY_SMARTIO_CLK_CHIP$idx)}`" repeatCount="8" />
      <!--LUT I/O terminal clock DRCs-->
      <DRC type="ERROR" text="I/O terminal [$idx] cannot simultaneously be used as an input to a LUT$idx input trigger and be used as the Smart I/O block clock source." condition="`${((lut$idxTr0 eq CY_SMARTIO_LUTTR_IO$idx) || (lut$idxTr1 eq CY_SMARTIO_LUTTR_IO$idx) || (lut$idxTr2 eq CY_SMARTIO_LUTTR_IO$idx)) &amp;&amp; (clkSrc eq CY_SMARTIO_CLK_IO$idx)}`" repeatCount="8" />
      
      <!--LUT TR DRCs-->
      <DRC type="ERROR" text="Invalid LUT connection. All three input trigger terminals of LUT [$idx] must have signal sources." 
      condition="`${((lut$idxTr0 ne CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr1 ne CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr2 eq CY_SMARTIO_LUTTR_INVALID)) 
      || ((lut$idxTr0 ne CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr1 eq CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr2 ne CY_SMARTIO_LUTTR_INVALID)) 
      || ((lut$idxTr0 ne CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr1 eq CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr2 eq CY_SMARTIO_LUTTR_INVALID)) 
      || ((lut$idxTr0 eq CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr1 ne CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr2 ne CY_SMARTIO_LUTTR_INVALID)) 
      || ((lut$idxTr0 eq CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr1 ne CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr2 eq CY_SMARTIO_LUTTR_INVALID)) 
      || ((lut$idxTr0 eq CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr1 eq CY_SMARTIO_LUTTR_INVALID) &amp;&amp; (lut$idxTr2 ne CY_SMARTIO_LUTTR_INVALID))}`" 
      repeatCount="8" />
      
      <!--LUT-DU TR0 DRCs-->
      <DRC type="ERROR" text="Invalid LUT connection. LUT [$idx] TR0 is sourced from DU but the Data Unit is not enabled to drive it." 
      condition="`${(lut$idxTr0 eq CY_SMARTIO_LUTTR_DU_OUT) &amp;&amp; (duEn eq false)}`" repeatCount="8" />
      
      <!--DU-LUT TR0 DRCs-->
      <DRC type="ERROR" text="Invalid DU connection. DU TR0 is sourced from LUT [$idx] but the LUT is not enabled to drive it." 
      condition="`${(duTr0 eq CY_SMARTIO_DUTR_LUT$idx_OUT) &amp;&amp; (lutEn$idx eq false)}`" repeatCount="8" />
      
      <!--DU-LUT TR1 DRCs-->
      <DRC type="ERROR" text="Invalid DU connection. DU TR1 is sourced from LUT [$idx] but the LUT is not enabled to drive it." 
      condition="`${(duTr1 eq CY_SMARTIO_DUTR_LUT$idx_OUT) &amp;&amp; (lutEn$idx eq false)}`" repeatCount="8" />
      
      <!--DU-LUT TR2 DRCs-->
      <DRC type="ERROR" text="Invalid DU connection. DU TR2 is sourced from LUT [$idx] but the LUT is not enabled to drive it." 
      condition="`${(duTr2 eq CY_SMARTIO_DUTR_LUT$idx_OUT) &amp;&amp; (lutEn$idx eq false)}`" repeatCount="8" />
      
      <!--I/O input terminal DRCs-->
      <DRC type="WARNING" text="I/O [$idx] terminal is configured to be an input but it is not used in this design." 
      condition="`${((ioMode$idx eq CY_SMARTIO_SYNC_INPUT) || (ioMode$idx eq CY_SMARTIO_ASYNC_INPUT)) &amp;&amp; 
      (((lut0Tr0 eq CY_SMARTIO_LUTTR_IO$idx) || (lut0Tr1 eq CY_SMARTIO_LUTTR_IO$idx) || (lut0Tr2 eq CY_SMARTIO_LUTTR_IO$idx) ||
       (lut1Tr0 eq CY_SMARTIO_LUTTR_IO$idx) || (lut1Tr1 eq CY_SMARTIO_LUTTR_IO$idx) || (lut1Tr2 eq CY_SMARTIO_LUTTR_IO$idx) ||
       (lut2Tr0 eq CY_SMARTIO_LUTTR_IO$idx) || (lut2Tr1 eq CY_SMARTIO_LUTTR_IO$idx) || (lut2Tr2 eq CY_SMARTIO_LUTTR_IO$idx) ||
       (lut3Tr0 eq CY_SMARTIO_LUTTR_IO$idx) || (lut3Tr1 eq CY_SMARTIO_LUTTR_IO$idx) || (lut3Tr2 eq CY_SMARTIO_LUTTR_IO$idx) ||
       (lut4Tr0 eq CY_SMARTIO_LUTTR_IO$idx) || (lut4Tr1 eq CY_SMARTIO_LUTTR_IO$idx) || (lut4Tr2 eq CY_SMARTIO_LUTTR_IO$idx) ||
       (lut5Tr0 eq CY_SMARTIO_LUTTR_IO$idx) || (lut5Tr1 eq CY_SMARTIO_LUTTR_IO$idx) || (lut5Tr2 eq CY_SMARTIO_LUTTR_IO$idx) ||
       (lut6Tr0 eq CY_SMARTIO_LUTTR_IO$idx) || (lut6Tr1 eq CY_SMARTIO_LUTTR_IO$idx) || (lut6Tr2 eq CY_SMARTIO_LUTTR_IO$idx) ||
       (lut7Tr0 eq CY_SMARTIO_LUTTR_IO$idx) || (lut7Tr1 eq CY_SMARTIO_LUTTR_IO$idx) || (lut7Tr2 eq CY_SMARTIO_LUTTR_IO$idx)) eq false)}`" 
      repeatCount="8" />
      
      <!--I/O output terminal DRCs-->
      <DRC type="WARNING" text="I/O [$idx] terminal is configured to be an output but LUT [$idx] is not enabled to drive it." 
      condition="`${(ioMode$idx eq CY_SMARTIO_OUTPUT) &amp;&amp; (lutEn$idx eq false)}`" repeatCount="8" />
      
      <!--Chip input terminal DRCs-->
      <DRC type="WARNING" text="Chip [$idx] terminal is configured to be an input but it is not used in this design." 
      condition="`${((chipMode$idx eq CY_SMARTIO_SYNC_INPUT) || (chipMode$idx eq CY_SMARTIO_ASYNC_INPUT)) &amp;&amp; 
      (((lut0Tr0 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut0Tr1 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut0Tr2 eq CY_SMARTIO_LUTTR_CHIP$idx) ||
       (lut1Tr0 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut1Tr1 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut1Tr2 eq CY_SMARTIO_LUTTR_CHIP$idx) ||
       (lut2Tr0 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut2Tr1 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut2Tr2 eq CY_SMARTIO_LUTTR_CHIP$idx) ||
       (lut3Tr0 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut3Tr1 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut3Tr2 eq CY_SMARTIO_LUTTR_CHIP$idx) ||
       (lut4Tr0 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut4Tr1 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut4Tr2 eq CY_SMARTIO_LUTTR_CHIP$idx) ||
       (lut5Tr0 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut5Tr1 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut5Tr2 eq CY_SMARTIO_LUTTR_CHIP$idx) ||
       (lut6Tr0 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut6Tr1 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut6Tr2 eq CY_SMARTIO_LUTTR_CHIP$idx) ||
       (lut7Tr0 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut7Tr1 eq CY_SMARTIO_LUTTR_CHIP$idx) || (lut7Tr2 eq CY_SMARTIO_LUTTR_CHIP$idx)) eq false)}`" 
      repeatCount="8" />
      
      <!--Chip output terminal DRCs-->
      <DRC type="WARNING" text="Chip [$idx] terminal is configured to be an output but LUT [$idx] is not enabled to drive it." 
      condition="`${(chipMode$idx eq CY_SMARTIO_OUTPUT) &amp;&amp; (lutEn$idx eq false)}`" repeatCount="8" />
  
      <!-- in/out is deliberately flipped between the condition and the DRC. In/out are with respect to the chip, so we reverse them for text we show to the user -->
      <DRC type="ERROR" text="The chip output terminal $idx cannot be connected when the chip inout terminal $idx is connected." condition="`${hasConnection(&quot;chip_in&quot;, $idx) &amp;&amp; chipInoutConnected$idx}`" paramId="chip_inout[$idx]" repeatCount="8" />
      <DRC type="ERROR" text="The chip input terminal $idx cannot be connected when the chip inout terminal $idx is connected." condition="`${hasConnection(&quot;chip_out&quot;, $idx) &amp;&amp; chipInoutConnected$idx}`" paramId="chip_inout[$idx]" repeatCount="8" />
    </DRCs>
  
    <!--Config Structs-->
    <ConfigFirmware>
      <ConfigInclude value="cy_smartio.h" include="true" />
      <ConfigInclude value="cy_sysclk.h" include="`${pclkOk}`" />
      <ConfigDefine name="`${INST_NAME}`_HW" value="SMARTIO_PRT`${InstNumber}`" public="true" include="true" />
      <ConfigStruct name="`${INST_NAME . &quot;_lutCfg$idx&quot;}`" type="cy_stc_smartio_lutcfg_t" const="`${inFlash}`" public="true" include="`${lutEn$idx}`" repeatCount="8">
        <Member name="tr0" value="`${lut$idxTr0}`" />
        <Member name="tr1" value="`${lut$idxTr1}`" />
        <Member name="tr2" value="`${lut$idxTr2}`" />
        <Member name="opcode" value="`${lut$idxOpcode}`" />
        <Member name="lutMap" value="`${lut$idxMap}`" />
      </ConfigStruct>
  
      <ConfigStruct name="`${INST_NAME . &quot;_duCfg&quot;}`" type="cy_stc_smartio_ducfg_t" const="`${inFlash}`" public="true" include="`${duEn}`">
        <Member name="tr0" value="`${duTr0}`" />
        <Member name="tr1" value="`${duTr1}`" />
        <Member name="tr2" value="`${duTr2}`" />
        <Member name="data0" value="`${duData0}`" />
        <Member name="data1" value="`${duData1}`" />
        <Member name="opcode" value="`${duOpcode}`" />
        <Member name="size" value="`${duSize}`" />
        <Member name="dataReg" value="`${duDataReg}`" />
      </ConfigStruct>
      <ConfigStruct name="`${INST_NAME . &quot;_config&quot;}`" type="cy_stc_smartio_config_t" const="`${inFlash}`" public="true" include="true">
        <Member name="clkSrc" value="`${clkSrc}`" />
        <Member name="bypassMask" value="`${
        ((ioMode0 eq CY_SMARTIO_BYPASS) ? &quot;CY_SMARTIO_CHANNEL0&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode1 eq CY_SMARTIO_BYPASS) ? &quot;CY_SMARTIO_CHANNEL1&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode2 eq CY_SMARTIO_BYPASS) ? &quot;CY_SMARTIO_CHANNEL2&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode3 eq CY_SMARTIO_BYPASS) ? &quot;CY_SMARTIO_CHANNEL3&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode4 eq CY_SMARTIO_BYPASS) ? &quot;CY_SMARTIO_CHANNEL4&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode5 eq CY_SMARTIO_BYPASS) ? &quot;CY_SMARTIO_CHANNEL5&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode6 eq CY_SMARTIO_BYPASS) ? &quot;CY_SMARTIO_CHANNEL6&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode7 eq CY_SMARTIO_BYPASS) ? &quot;CY_SMARTIO_CHANNEL7&quot; : &quot;0u&quot;)}`" />
        <Member name="ioSyncEn" value="`${
        ((ioMode0 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL0&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode1 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL1&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode2 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL2&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode3 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL3&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode4 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL4&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode5 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL5&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode6 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL6&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((ioMode7 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL7&quot; : &quot;0u&quot;)}`" />
        <Member name="chipSyncEn" value="`${
        ((chipMode0 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL0&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((chipMode1 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL1&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((chipMode2 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL2&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((chipMode3 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL3&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((chipMode4 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL4&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((chipMode5 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL5&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((chipMode6 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL6&quot; : &quot;0u&quot;) . &quot;|&quot; .
        ((chipMode7 eq CY_SMARTIO_SYNC_INPUT) ? &quot;CY_SMARTIO_CHANNEL7&quot; : &quot;0u&quot;)}`" />
        <Member name="lutCfg0" value="`${lutEn0 eq true ? (&quot;&amp;&quot; . INST_NAME . &quot;_lutCfg0&quot;) : &quot;NULL&quot;}`" />
        <Member name="lutCfg1" value="`${lutEn1 eq true ? (&quot;&amp;&quot; . INST_NAME . &quot;_lutCfg1&quot;) : &quot;NULL&quot;}`" />
        <Member name="lutCfg2" value="`${lutEn2 eq true ? (&quot;&amp;&quot; . INST_NAME . &quot;_lutCfg2&quot;) : &quot;NULL&quot;}`" />
        <Member name="lutCfg3" value="`${lutEn3 eq true ? (&quot;&amp;&quot; . INST_NAME . &quot;_lutCfg3&quot;) : &quot;NULL&quot;}`" />
        <Member name="lutCfg4" value="`${lutEn4 eq true ? (&quot;&amp;&quot; . INST_NAME . &quot;_lutCfg4&quot;) : &quot;NULL&quot;}`" />
        <Member name="lutCfg5" value="`${lutEn5 eq true ? (&quot;&amp;&quot; . INST_NAME . &quot;_lutCfg5&quot;) : &quot;NULL&quot;}`" />
        <Member name="lutCfg6" value="`${lutEn6 eq true ? (&quot;&amp;&quot; . INST_NAME . &quot;_lutCfg6&quot;) : &quot;NULL&quot;}`" />
        <Member name="lutCfg7" value="`${lutEn7 eq true ? (&quot;&amp;&quot; . INST_NAME . &quot;_lutCfg7&quot;) : &quot;NULL&quot;}`" />
        <Member name="duCfg" value="`${duEn eq true ? (&quot;&amp;&quot; . INST_NAME . &quot;_duCfg&quot;) : &quot;NULL&quot;}`" />
        <Member name="hldOvr" value="`${hldOvr}`" />
      </ConfigStruct>
      <ConfigInstruction value="Cy_SysClk_PeriphAssignDivider(`${pclkDst}`, `${getExposedMember(pclk, &quot;clockSel&quot;)}`);" include="`${pclkOk}`" />
    </ConfigFirmware>
  </Personality>
  