<?xml version="1.0" encoding="utf-8"?> <!--**************************************************************************** * \file pwm_ver2.cypersonality * \version 1.0 * * \brief * PWM 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="mxs40pwm_ver2" name="PWM" version="1.0" path="Digital/Functions" xmlns="http://cypress.com/xsd/cyhwpersonality_v1"> <Dependencies> <IpBlock name="mxtcpwm_ver2" /> <Resource name="tcpwm\.group\.cnt" 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__tcpwm__pwm.html" linkText="Open PWM (TCPWM) Documentation" visible="true" desc="Opens the Peripheral Driver Library Documentation" /> <!--General--> <ParamRange id="pCntGroup" name="pCntGroup" desc="pCntGroup" group="Internal" default="`${getInstNumber("group")}`" min="0" max="3" resolution="1" visible="false" editable="false" /> <ParamString id="pCntWidthEx" name="pCntWidthEx" desc="pCntWidthEx" group="Internal" default="GRP_NR[`${pCntGroup}`].CNT.GRP_CNT_WIDTH" visible="false" editable="false" /> <ParamRange id="pCntWidth" name="pCntWidth" desc="pCntWidth" group="Internal" default="`${lookupExpression(pCntWidthEx)}`" min="0" max="32" resolution="1" visible="false" editable="false" /> <ParamRange id="pCntWidthMax" name="pCntWidthMax" desc="pCntWidthMax" group="Internal" default="`${pow(2, pCntWidth)-1}`" min="0" max="4294967296" resolution="1" visible="false" editable="false" /> <ParamRange id="tcpwmInst" name="TCPWM Number" group="Internal" default="`${getInstNumber("tcpwm")}`" min="0" max="3" resolution="1" visible="false" editable="false" desc="" /> <ParamRange id="cntInst" name="CNT Number" group="Internal" default="`${getInstNumber("cnt") + pCntGroup * 256}`" min="0" max="1023" resolution="1" visible="false" editable="false" desc="" /> <ParamString id="pCntCC1Ex" name="pCntCC1Ex" desc="pCntCC1Ex" group="Internal" default="GRP_NR[`${pCntGroup}`].CNT.GRP_CC1_PRESENT" visible="false" editable="false" /> <ParamBool id="pCntCC1" name="pCntCC1" desc="pCntCC1" group="Internal" default="`${lookupExpression(pCntCC1Ex) eq 1}`" visible="false" editable="false" /> <ParamString id="pCntAMCEx" name="pCntAMCEx" desc="pCntAMCEx" group="Internal" default="GRP_NR[`${pCntGroup}`].CNT.GRP_AMC_PRESENT" visible="false" editable="false" /> <ParamBool id="pCntAMC" name="pCntAMC" desc="pCntAMC" group="Internal" default="`${lookupExpression(pCntAMCEx) eq 1}`" visible="false" editable="false" /> <ParamString id="TCPWM_version" name="TCPWM version" group="General" default="TCPWM_ver2" visible="true" editable="false" desc="Version of the TCPWM hardware block"/> <ParamChoice id="PwmMode" name="PWM Mode" group="General" default="CY_TCPWM_PWM_MODE_PWM" visible="true" editable="true" desc="Selects the PWM mode of operation."> <Entry name="PWM" value="CY_TCPWM_PWM_MODE_PWM" visible="true" /> <Entry name="PWM Dead Time" value="CY_TCPWM_PWM_MODE_DEADTIME" visible="true" /> <Entry name="PWM Pseudo random" value="CY_TCPWM_PWM_MODE_PSEUDORANDOM" visible="true" /> </ParamChoice> <ParamBool id="pPwmNePrs" name="pPwmNePrs" desc="pPwmNePrs" group="Internal" default="`${PwmMode ne CY_TCPWM_PWM_MODE_PSEUDORANDOM}`" visible="false" editable="false" /> <ParamChoice id="ClockPrescaler" name="Clock Prescaler" group="General" default="CY_TCPWM_PWM_PRESCALER_DIVBY_1" visible="`${PwmMode ne CY_TCPWM_PWM_MODE_DEADTIME}`" editable="true" desc="Divides down the input clock." > <Entry name="Divide by 1" value="CY_TCPWM_PWM_PRESCALER_DIVBY_1" visible="true" /> <Entry name="Divide by 2" value="CY_TCPWM_PWM_PRESCALER_DIVBY_2" visible="true" /> <Entry name="Divide by 4" value="CY_TCPWM_PWM_PRESCALER_DIVBY_4" visible="true" /> <Entry name="Divide by 8" value="CY_TCPWM_PWM_PRESCALER_DIVBY_8" visible="true" /> <Entry name="Divide by 16" value="CY_TCPWM_PWM_PRESCALER_DIVBY_16" visible="true" /> <Entry name="Divide by 32" value="CY_TCPWM_PWM_PRESCALER_DIVBY_32" visible="true" /> <Entry name="Divide by 64" value="CY_TCPWM_PWM_PRESCALER_DIVBY_64" visible="true" /> <Entry name="Divide by 128" value="CY_TCPWM_PWM_PRESCALER_DIVBY_128" visible="true" /> </ParamChoice> <ParamChoice id="Resolution" name="PWM Resolution" group="General" default="`${(pCntWidth eq 16) ? "CY_TCPWM_PWM_RESOLUTION_WIDTH_16_BITS" : "CY_TCPWM_PWM_RESOLUTION_WIDTH_32_BITS"}`" visible="true" editable="false" desc="Selects the width of the PWM."> <Entry name="16-bits" value="CY_TCPWM_PWM_RESOLUTION_WIDTH_16_BITS" visible="true" /> <Entry name="32-bits" value="CY_TCPWM_PWM_RESOLUTION_WIDTH_32_BITS" visible="true" /> </ParamChoice> <ParamChoice id="PwmAlignment" name="PWM Alignment" group="General" default="CY_TCPWM_PWM_LEFT_ALIGN" visible="`${pPwmNePrs}`" editable="true" desc="Selects which direction the PWM counts in. Left = Up, Right = Down, Center/Asymmetric = Up/Down." > <Entry name="Left Aligned" value="CY_TCPWM_PWM_LEFT_ALIGN" visible="true" /> <Entry name="Right Aligned" value="CY_TCPWM_PWM_RIGHT_ALIGN" visible="true" /> <Entry name="Center Aligned" value="CY_TCPWM_PWM_CENTER_ALIGN" visible="true" /> <Entry name="Asymmetric" value="CY_TCPWM_PWM_ASYMMETRIC_ALIGN" visible="true" /> <Entry name="Asymmetric CC0 & CC1" value="CY_TCPWM_PWM_ASYMMETRIC_CC0_CC1_ALIGN" visible="`${pCntCC1}`" /> <Entry name="Center Asymmetric CC0 & CC1" value="CY_TCPWM_PWM_CENTER_ASYMMETRIC_CC0_CC1_ALIGN" visible="`${pCntCC1}`" /> </ParamChoice> <ParamBool id="SwapUnderflowOverflow" name="Swap Underflow Overflow Set/Clear" group="General" default="false" visible="`${((PwmAlignment eq CY_TCPWM_PWM_CENTER_ALIGN) || (PwmAlignment eq CY_TCPWM_PWM_ASYMMETRIC_ALIGN))}`" editable="true" desc="If checked on underflow event, output is SET and on overflow event output is CLEAR." /> <ParamChoice id="RunMode" name="Run Mode" group="General" default="CY_TCPWM_PWM_CONTINUOUS" visible="true" editable="true" desc="If Continuous is selected counter runs forever. If One Shot is selected counter runs for one period and stops."> <Entry name="Continuous" value="CY_TCPWM_PWM_CONTINUOUS" visible="true" /> <Entry name="One Shot" value="CY_TCPWM_PWM_ONESHOT" visible="true" /> </ParamChoice> <ParamRange id="DeadClocks" name="Dead Time Clocks" group="General" default="0" min="0" max="255" resolution="1" visible="`${PwmMode eq CY_TCPWM_PWM_MODE_DEADTIME}`" editable="true" desc="Number of clock cycles of dead time between PWM outputs. Range: 0-255." /> <ParamBool id="ImmediateKill" name="Immediate Kill" group="General" default="false" visible="true" editable="true" desc="If checked kill event immediately deactivates the dt_line_out and dt_line_compl_out. If not with the next module clock." /> <!--Period--> <ParamBool id="EnablePeriodSwap" name="Enable Period Swap" group="Period" default="false" visible="`${!(PwmMode eq CY_TCPWM_PWM_MODE_PSEUDORANDOM)}`" editable="true" desc="If checked the periods will be swapped at the next OV/UN when a swap event has been registered." /> <ParamRange id="Period0" name="`${EnablePeriodSwap ? "Period 0" : "Period"}`" group="Period" default="32768" min="0" max="`${pCntWidthMax}`" resolution="1" visible="true" editable="true" desc="Sets the period of the counter. Range: 0-65535 (for 16 bit resolution) or 0–4294967295 (for 32 bit resolution)." /> <ParamRange id="Period1" name="Period 1" group="Period" default="32768" min="0" max="`${pCntWidthMax}`" resolution="1" visible="`${EnablePeriodSwap}`" editable="true" desc="Sets the period of the counter. Range: 0-65535 (for 16 bit resolution) or 0–4294967295 (for 32 bit resolution)." /> <!--Taps Enabled--> <ParamRange id="TapsEnabled" name="Taps Enabled" group="Taps Enabled" default="45" min="0" max="`${pCntWidthMax}`" resolution="1" visible="`${PwmMode eq CY_TCPWM_PWM_MODE_PSEUDORANDOM}`" editable="true" desc="Sets the tap value. Range: 0-65535 (for 16 bit resolution) or 0–4294967295 (for 32 bit resolution)." /> <!--Compare--> <ParamBool id="EnableCompare0Swap" name="Enable Compare 0 Swap" group="Compare" default="false" visible="true" editable="true" desc="If checked the compare register will be swapped at the next OV/UN when a swap event has been registered." /> <ParamRange id="Compare0" name="Compare 0" group="Compare" default="16384" min="0" max="`${pCntWidthMax}`" resolution="1" visible="true" editable="true" desc="Sets the compare value. When the count value equals the compare the compare output pulses high. Range: 0-65535 (for 16 bit resolution) or 0–4294967295 (for 32 bit resolution)." /> <ParamRange id="Compare1" name="Compare 0 Buff" group="Compare" default="16384" min="0" max="`${pCntWidthMax}`" resolution="1" visible="`${EnableCompare0Swap}`" editable="true" desc="Sets the buffered compare value. Range: 0-65535 (for 16 bit resolution) or 0–4294967295 (for 32 bit resolution)." /> <!--Compare1--> <ParamBool id="EnableCompare1Swap" name="Enable Compare 1 Swap" group="Compare" default="false" visible="`${pCntCC1}`" editable="true" desc="If checked the compare register will be swapped at the next OV/UN when a swap event has been registered." /> <ParamRange id="Compare2" name="Compare 1" group="Compare" default="16384" min="0" max="`${pCntWidthMax}`" resolution="1" visible="`${pCntCC1}`" editable="true" desc="Sets the compare value. When the count value equals the compare the compare output pulses high. Range: 0-65535 (for 16 bit resolution) or 0–4294967295 (for 32 bit resolution)." /> <ParamRange id="Compare3" name="Compare 1 Buff" group="Compare" default="16384" min="0" max="`${pCntWidthMax}`" resolution="1" visible="`${EnableCompare1Swap && pCntCC1}`" editable="true" desc="Sets the buffered compare value. Range: 0-65535 (for 16 bit resolution) or 0–4294967295 (for 32 bit resolution)." /> <!-- Event Generation --> <ParamBool id="pEventGenerationVisible" name="pEventGenerationVisible" group="Internal" default="`${(pCntAMC && ((PwmAlignment eq CY_TCPWM_PWM_CENTER_ALIGN) || (PwmAlignment eq CY_TCPWM_PWM_ASYMMETRIC_ALIGN) || (PwmAlignment eq CY_TCPWM_PWM_CENTER_ASYMMETRIC_CC0_CC1_ALIGN)))}`" visible="false" editable="false" desc="" /> <ParamBool id="Compare0MatchUp" name="Compare 0 match up" group="Event Generation" default="false" visible="`${pEventGenerationVisible}`" editable="true" desc="test" /> <ParamBool id="Compare0MatchDown" name="Compare 0 match Down" group="Event Generation" default="false" visible="`${pEventGenerationVisible}`" editable="true" desc="test" /> <ParamBool id="Compare1MatchUp" name="Compare 1 match up" group="Event Generation" default="false" visible="`${pEventGenerationVisible}`" editable="true" desc="test" /> <ParamBool id="Compare1MatchDown" name="Compare 1 match Down" group="Event Generation" default="false" visible="`${pEventGenerationVisible}`" editable="true" desc="test" /> <!--Interrupts--> <ParamBool id="InterruptTC" name="Overflow & Underflow" group="Interrupt Source" default="false" visible="true" editable="true" desc="Generate interrupt on Overflow & Underflow events" /> <ParamBool id="InterruptCC0" name="Compare 0" group="Interrupt Source" default="false" visible="true" editable="true" desc="Generates interrupt when counter value matches with compare 0 value" /> <ParamBool id="InterruptCC1" name="Compare 1" group="Interrupt Source" default="false" visible="`${pCntCC1}`" editable="true" desc="Generates interrupt when counter value matches with compare 1 value" /> <ParamString id="InterruptSource" name="InterruptSource" desc="InterruptSource" group="Interrupt Source" default="(CY_TCPWM_INT_ON_TC `${(InterruptTC)? "" : "& 0U"}`) | (CY_TCPWM_INT_ON_CC0 `${(InterruptCC0)? "" : "& 0U"}`) | (CY_TCPWM_INT_ON_CC1 `${(InterruptCC1)? "" : "& 0U"}`)" visible="false" editable="false" /> <!--Inputs--> <ParamSignal port="clock[0]" name="Clock Signal" group="Inputs" visible="true" desc="The clock input defines the operating frequency." canBeEmpty="false" /> <ParamChoice id="CountInput" name="Count Input" group="Inputs" default="CY_TCPWM_INPUT_DISABLED" visible="`${pPwmNePrs}`" editable="true" desc="Determines if a count input is needed and how that input is registered." > <Entry name="Rising Edge" value="CY_TCPWM_INPUT_RISINGEDGE" visible="true" /> <Entry name="Falling Edge" value="CY_TCPWM_INPUT_FALLINGEDGE" visible="true" /> <Entry name="Either Edge" value="CY_TCPWM_INPUT_EITHEREDGE" visible="true" /> <Entry name="Level" value="CY_TCPWM_INPUT_LEVEL" visible="true" /> <Entry name="Disabled" value="CY_TCPWM_INPUT_DISABLED" visible="true" /> </ParamChoice> <ParamSignal port="count[0]" name="Count Signal" group="Inputs" visible="`${CountInput ne CY_TCPWM_INPUT_DISABLED}`" desc="This digital input causes the PWM to count depending on how the it is configured." canBeEmpty="`${CountInput eq CY_TCPWM_INPUT_DISABLED}`" > <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="DEFAULT" reason=""> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="INFO" reason="The pin Drive Mode parameter does not match expected."> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation=".*" valid="true" /> </ParamSignal> <ParamChoice id="Kill0Input" name="Kill 0 Input" group="Inputs" default="CY_TCPWM_INPUT_DISABLED" visible="true" editable="true" desc="Determines how the kill 0 input behaves." > <Entry name="Rising Edge" value="CY_TCPWM_INPUT_RISINGEDGE" visible="true" /> <Entry name="Falling Edge" value="CY_TCPWM_INPUT_FALLINGEDGE" visible="true" /> <Entry name="Either Edge" value="CY_TCPWM_INPUT_EITHEREDGE" visible="true" /> <Entry name="Level" value="CY_TCPWM_INPUT_LEVEL" visible="true" /> <Entry name="Disabled" value="CY_TCPWM_INPUT_DISABLED" visible="true" /> </ParamChoice> <ParamSignal port="stop[0]" name="Kill 0 Signal" group="Inputs" visible="`${Kill0Input ne CY_TCPWM_INPUT_DISABLED}`" desc="This digital input kills the PWM, based on the Kill0 Input selection." canBeEmpty="`${Kill0Input eq CY_TCPWM_INPUT_DISABLED}`" > <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="DEFAULT" reason=""> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="INFO" reason="The pin Drive Mode parameter does not match expected."> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation=".*" valid="true" /> </ParamSignal> <ParamChoice id="ReloadInput" name="Reload Input" group="Inputs" default="CY_TCPWM_INPUT_DISABLED" visible="true" editable="true" desc="Determines if a reload input is needed and how the reload signal input is registered." > <Entry name="Rising Edge" value="CY_TCPWM_INPUT_RISINGEDGE" visible="true" /> <Entry name="Falling Edge" value="CY_TCPWM_INPUT_FALLINGEDGE" visible="true" /> <Entry name="Either Edge" value="CY_TCPWM_INPUT_EITHEREDGE" visible="true" /> <Entry name="Disabled" value="CY_TCPWM_INPUT_DISABLED" visible="true" /> </ParamChoice> <ParamSignal port="reload[0]" name="Reload Signal" group="Inputs" visible="`${ReloadInput ne CY_TCPWM_INPUT_DISABLED}`" desc="This digital input triggers a reload of the PWM, and starts the PWM." canBeEmpty="`${ReloadInput eq CY_TCPWM_INPUT_DISABLED}`" > <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="DEFAULT" reason=""> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="INFO" reason="The pin Drive Mode parameter does not match expected."> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation=".*" valid="true" /> </ParamSignal> <ParamChoice id="StartInput" name="Start Input" group="Inputs" default="CY_TCPWM_INPUT_DISABLED" visible="true" editable="true" desc="Determines if a start input is needed and how that input is registered." > <Entry name="Rising Edge" value="CY_TCPWM_INPUT_RISINGEDGE" visible="true" /> <Entry name="Falling Edge" value="CY_TCPWM_INPUT_FALLINGEDGE" visible="true" /> <Entry name="Either Edge" value="CY_TCPWM_INPUT_EITHEREDGE" visible="true" /> <Entry name="Disabled" value="CY_TCPWM_INPUT_DISABLED" visible="true" /> </ParamChoice> <ParamSignal port="start[0]" name="Start Signal" group="Inputs" visible="`${StartInput ne CY_TCPWM_INPUT_DISABLED}`" desc="This digital input triggers a Start of the PWM." canBeEmpty="`${StartInput eq CY_TCPWM_INPUT_DISABLED}`" > <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="DEFAULT" reason=""> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="INFO" reason="The pin Drive Mode parameter does not match expected."> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation=".*" valid="true" /> </ParamSignal> <ParamChoice id="SwapInput" name="Swap Input" group="Inputs" default="CY_TCPWM_INPUT_DISABLED" visible="true" editable="true" desc="This input controls when compare and period swaps occur." > <Entry name="Rising Edge" value="CY_TCPWM_INPUT_RISINGEDGE" visible="true" /> <Entry name="Falling Edge" value="CY_TCPWM_INPUT_FALLINGEDGE" visible="true" /> <Entry name="Either Edge" value="CY_TCPWM_INPUT_EITHEREDGE" visible="true" /> <Entry name="Disabled" value="CY_TCPWM_INPUT_DISABLED" visible="true" /> </ParamChoice> <ParamSignal port="capture0[0]" name="Swap Signal" group="Inputs" visible="`${SwapInput ne CY_TCPWM_INPUT_DISABLED}`" desc="This input latches a SWAP command. The swap doesn’t occur until the next Overflow/Underflow event." canBeEmpty="`${SwapInput eq CY_TCPWM_INPUT_DISABLED}`" > <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="DEFAULT" reason=""> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="INFO" reason="The pin Drive Mode parameter does not match expected."> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation=".*" valid="true" /> </ParamSignal> <ParamChoice id="Kill1Input" name="Kill 1 Input" group="Inputs" default="CY_TCPWM_INPUT_DISABLED" visible="`${pCntCC1}`" editable="true" desc="Determines how the kill 1 input behaves." > <Entry name="Rising Edge" value="CY_TCPWM_INPUT_RISINGEDGE" visible="true" /> <Entry name="Falling Edge" value="CY_TCPWM_INPUT_FALLINGEDGE" visible="true" /> <Entry name="Either Edge" value="CY_TCPWM_INPUT_EITHEREDGE" visible="true" /> <Entry name="Level" value="CY_TCPWM_INPUT_LEVEL" visible="true" /> <Entry name="Disabled" value="CY_TCPWM_INPUT_DISABLED" visible="true" /> </ParamChoice> <ParamSignal port="capture1[0]" name="Kill 1 Signal" group="Inputs" visible="`${Kill1Input ne CY_TCPWM_INPUT_DISABLED}`" desc="This digital input kills the PWM, based on the Kill1 Input selection." canBeEmpty="`${Kill1Input eq CY_TCPWM_INPUT_DISABLED}`" > <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="DEFAULT" reason=""> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="INFO" reason="The pin Drive Mode parameter does not match expected."> <Fixed value="CY_GPIO_DM_HIGHZ" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation=".*" valid="true" /> </ParamSignal> <!--Kill Mode--> <ParamChoice id="KillMode" name="Kill Mode" group="Kill Mode" default="CY_TCPWM_PWM_STOP_ON_KILL" visible="`${Kill0Input ne CY_TCPWM_INPUT_DISABLED}`" editable="true" desc="Determines what the kill signal does to the PWM." > <Entry name="Asynchronous Kill" value="CY_TCPWM_PWM_ASYNC_KILL" visible="true" /> <Entry name="Synchronous Kill" value="CY_TCPWM_PWM_SYNCH_KILL" visible="true" /> <Entry name="Stop on Kill" value="CY_TCPWM_PWM_STOP_ON_KILL" visible="true" /> </ParamChoice> <!--PWM Output Polarity--> <ParamBool id="InvertPwm" name="Invert PWM Output" group="PWM Output Polarity" default="false" visible="true" editable="true" desc="If checked the main PWM output is inverted." /> <ParamBool id="InvertPwm_n" name="Invert PWM_n Output" group="PWM Output Polarity" default="false" visible="true" editable="true" desc="If checked the main PWM_n output is inverted." /> <!--PWM output on Disable--> <ParamChoice id="PwmDisabledOutput" name="PWM Disabled Output" group="PWM Disabled Output" default="CY_TCPWM_PWM_OUTPUT_HIGHZ" visible="true" editable="true" desc="Specifies the behavior of the PWM outputs while PWM is disabled." > <Entry name="High Impedance" value="CY_TCPWM_PWM_OUTPUT_HIGHZ" visible="true" /> <Entry name="Retain" value="CY_TCPWM_PWM_OUTPUT_RETAIN" visible="true" /> <Entry name="Low" value="CY_TCPWM_PWM_OUTPUT_LOW" visible="true" /> <Entry name="High" value="CY_TCPWM_PWM_OUTPUT_HIGH" visible="true" /> </ParamChoice> <!--Outputs--> <ParamSignal port="line[0]" name="PWM (line)" group="Outputs" visible="true" desc="PWM output" canBeEmpty="true" > <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="DEFAULT" reason=""> <Fixed value="CY_GPIO_DM_STRONG_IN_OFF" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="INFO" reason="The pin Drive Mode parameter does not match expected."> <Fixed value="CY_GPIO_DM_STRONG_IN_OFF" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation=".*" valid="true" /> </ParamSignal> <ParamSignal port="line_compl[0]" name="PWM_n (line_compl)" group="Outputs" visible="true" desc="Complimentary PWM output." canBeEmpty="true" > <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="DEFAULT" reason=""> <Fixed value="CY_GPIO_DM_STRONG_IN_OFF" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="INFO" reason="The pin Drive Mode parameter does not match expected."> <Fixed value="CY_GPIO_DM_STRONG_IN_OFF" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation=".*" valid="true" /> </ParamSignal> <!--Trigger Outputs--> <ParamChoice id="trigger0Event" name="Trigger 0 Event" group="Trigger Outputs" default="CY_TCPWM_CNT_TRIGGER_ON_DISABLED" visible="true" editable="true" desc="This output used to connect TCPWM event signals to other peripherals." > <Entry name="Overflow" value="CY_TCPWM_CNT_TRIGGER_ON_OVERFLOW" visible="true" /> <Entry name="Underflow" value="CY_TCPWM_CNT_TRIGGER_ON_UNDEFLOW" visible="true" /> <Entry name="Terminal Count" value="CY_TCPWM_CNT_TRIGGER_ON_TC" visible="true" /> <Entry name="Compare 0 Match" value="CY_TCPWM_CNT_TRIGGER_ON_CC0_MATCH" visible="true" /> <Entry name="Compare 1 Match" value="CY_TCPWM_CNT_TRIGGER_ON_CC1_MATCH" visible="`${pCntCC1}`" /> <Entry name="PWM (line_out)" value="CY_TCPWM_CNT_TRIGGER_ON_LINE_OUT" visible="true" /> <Entry name="Disabled" value="CY_TCPWM_CNT_TRIGGER_ON_DISABLED" visible="true" /> </ParamChoice> <ParamSignal port="tr_out0[0]" name="Trigger 0 Signal" group="Trigger Outputs" visible="`${trigger0Event ne CY_TCPWM_CNT_TRIGGER_ON_DISABLED}`" desc="Signals to connect on Trigger 0 Event" canBeEmpty="`${trigger0Event eq CY_TCPWM_CNT_TRIGGER_ON_DISABLED}`" > <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="DEFAULT" reason=""> <Fixed value="CY_GPIO_DM_STRONG_IN_OFF" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="INFO" reason="The pin Drive Mode parameter does not match expected."> <Fixed value="CY_GPIO_DM_STRONG_IN_OFF" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation=".*" valid="true" /> </ParamSignal> <ParamChoice id="trigger1Event" name="Trigger 1 Event" group="Trigger Outputs" default="CY_TCPWM_CNT_TRIGGER_ON_DISABLED" visible="true" editable="true" desc="This output used to connect TCPWM event signals to other peripherals." > <Entry name="Overflow" value="CY_TCPWM_CNT_TRIGGER_ON_OVERFLOW" visible="true" /> <Entry name="Underflow" value="CY_TCPWM_CNT_TRIGGER_ON_UNDEFLOW" visible="true" /> <Entry name="Terminal Count" value="CY_TCPWM_CNT_TRIGGER_ON_TC" visible="true" /> <Entry name="Compare 0 Match" value="CY_TCPWM_CNT_TRIGGER_ON_CC0_MATCH" visible="true" /> <Entry name="Compare 1 Match" value="CY_TCPWM_CNT_TRIGGER_ON_CC1_MATCH" visible="`${pCntCC1}`" /> <Entry name="PWM (line_out)" value="CY_TCPWM_CNT_TRIGGER_ON_LINE_OUT" visible="true" /> <Entry name="Disabled" value="CY_TCPWM_CNT_TRIGGER_ON_DISABLED" visible="true" /> </ParamChoice> <ParamSignal port="tr_out1[0]" name="Trigger 1 Signal" group="Trigger Outputs" visible="`${trigger1Event ne CY_TCPWM_CNT_TRIGGER_ON_DISABLED}`" desc="Signals to connect on Trigger 1 Event " canBeEmpty="`${trigger1Event eq CY_TCPWM_CNT_TRIGGER_ON_DISABLED}`" > <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="DEFAULT" reason=""> <Fixed value="CY_GPIO_DM_STRONG_IN_OFF" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation="ioss\[\d+\]\.port\[\d+\]\.pin.*" valid="true" > <Parameter id="DriveModes" severity="INFO" reason="The pin Drive Mode parameter does not match expected."> <Fixed value="CY_GPIO_DM_STRONG_IN_OFF" /> </Parameter> </Constraint> <Constraint type="ACCEPT" targetLocation=".*" valid="true" /> </ParamSignal> <!--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)." /> <!-- Peripheral clock divider connection --> <ParamString id="definePrefix" name="Define prefix" group="Internal" default="`${"TCPWM" . tcpwmInst . "_GRP" . pCntGroup . "_CNT" . getInstNumber("cnt")}`" visible="false" editable="false" desc="" /> <ParamString id="defineInputDisabled" name="Define input disabled" group="Internal" default="`${INST_NAME . "_INPUT_DISABLED & 0x3U"}`" visible="false" editable="false" desc="" /> <ParamString id="pclk" name="PCLK" group="Internal" default="`${getBlockFromSignal("clock[0]")}`" visible="false" editable="false" desc="Connected peripheral clock divider (PCLK)" /> <ParamBool id="pclkOk" name="PCLK Valid" group="Internal" default="`${hasConnection("clock", 0) && 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_TCPWM`${tcpwmInst}`_CLOCKS`${cntInst}`" visible="false" editable="false" desc="" /> <!-- Auxiliary internal parameters--> <ParamBool id="pC0GtP0" name="pC0GtP0" desc="pC0GtP0" group="Internal" default="`${Compare0 > Period0}`" visible="false" editable="false" /> <ParamBool id="pC0GtP1" name="pC0GtP1" desc="pC0GtP1" group="Internal" default="`${Compare0 > Period1}`" visible="false" editable="false" /> <ParamBool id="pC1GtP0" name="pC1GtP0" desc="pC1GtP0" group="Internal" default="`${Compare1 > Period0}`" visible="false" editable="false" /> <ParamBool id="pC1GtP1" name="pC1GtP1" desc="pC1GtP1" group="Internal" default="`${Compare1 > Period1}`" visible="false" editable="false" /> <ParamBool id="pC2GtP0" name="pC2GtP0" desc="pC2GtP0" group="Internal" default="`${Compare2 > Period0}`" visible="false" editable="false" /> <ParamBool id="pC2GtP1" name="pC2GtP1" desc="pC2GtP1" group="Internal" default="`${Compare2 > Period1}`" visible="false" editable="false" /> <ParamBool id="pC3GtP0" name="pC3GtP0" desc="pC3GtP0" group="Internal" default="`${Compare3 > Period0}`" visible="false" editable="false" /> <ParamBool id="pC3GtP1" name="pC3GtP1" desc="pC3GtP1" group="Internal" default="`${Compare3 > Period1}`" visible="false" editable="false" /> <ParamBool id="pAlignAsymm" name="pAlignAsymm" desc="pAlignAsymm" group="Internal" default="`${(PwmAlignment eq CY_TCPWM_PWM_ASYMMETRIC_ALIGN) || (PwmAlignment eq CY_TCPWM_PWM_ASYMMETRIC_CC0_CC1_ALIGN) || (PwmAlignment eq CY_TCPWM_PWM_CENTER_ASYMMETRIC_CC0_CC1_ALIGN)}`" visible="false" editable="false" /> <ParamBool id="pAlignCenter" name="pAlignCenter" desc="pAlignCenter" group="Internal" default="`${PwmAlignment eq CY_TCPWM_PWM_CENTER_ALIGN}`" visible="false" editable="false" /> <ParamBool id="pAlignAsymmOrCenter" name="pAlignAsymmOrCenter" desc="pAlignAsymmOrCenter" group="Internal" default="`${pAlignAsymm || pAlignCenter}`" visible="false" editable="false" /> <ParamBool id="pPwmNePrsAndC0GtP0" name="pPwmNePrsAndC0GtP0" desc="pPwmNePrsAndC0GtP0" group="Internal" default="`${pPwmNePrs && pC0GtP0}`" visible="false" editable="false" /> <ParamBool id="pPwmNePrsAndC0GtP1" name="pPwmNePrsAndC0GtP1" desc="pPwmNePrsAndC0GtP1" group="Internal" default="`${pPwmNePrs && pC0GtP1}`" visible="false" editable="false" /> <ParamBool id="pKillEqSynch" name="pKillEqSynch" desc="pKillEqSynch" group="Internal" default="`${KillMode eq CY_TCPWM_PWM_SYNCH_KILL}`" visible="false" editable="false" /> <ParamBool id="pEnCAndNEnP" name="pEnCAndNEnP" desc="pEnCAndNEnP" group="Internal" default="`${EnableCompare0Swap && (!EnablePeriodSwap)}`" visible="false" editable="false" /> <ParamBool id="pEnCAndEnP" name="pEnCAndEnP" desc="pEnCAndEnP" group="Internal" default="`${EnableCompare0Swap && EnablePeriodSwap}`" visible="false" editable="false" /> <ParamBool id="pNEnCOrAssymAndC0GtP1" name="pNEnCOrAssymAndC0GtP1" desc="pNEnCOrAssymAndC0GtP1" group="Internal" default="`${((!EnableCompare0Swap) || pAlignAsymm)&& pC0GtP1}`" visible="false" editable="false" /> <ParamBool id="pNePrsAndEnCAndEnP" name="pNePrsAndEnCAndEnP" desc="pNePrsAndEnCAndEnP" group="Internal" default="`${pPwmNePrs && pEnCAndEnP}`" visible="false" editable="false" /> </Parameters> <DRCs> <!--Compare0 DRCs--> <DRC type="INFO" text="Compare 0 value have to be less or equal to Period 0 (Period). A value larger than period is uses to get 100% duty cycle (Left Aligned alignment) or 0% duty cycle (Right Aligned alignment)." condition="`${pPwmNePrsAndC0GtP0}`" /> <DRC type="INFO" text="Compare 0 value have to be less or equal to Period 1. A value larger than period is uses to get 100% duty cycle (Left Aligned alignment) or 0% duty cycle (Right Aligned alignment)." condition="`${pPwmNePrs && EnablePeriodSwap && pNEnCOrAssymAndC0GtP1}`" /> <DRC type="ERROR" text="Compare 0 value must be less or equal to Period 0 (Period)." condition="`${pPwmNePrs &&pAlignAsymmOrCenter && pC0GtP0}`" paramId="Compare0" /> <DRC type="ERROR" text="Compare 0 value must be less or equal to Period 1." condition="`${pPwmNePrs && pAlignAsymmOrCenter && EnablePeriodSwap && pNEnCOrAssymAndC0GtP1}`" paramId="Compare0" /> <!--Compare0Buff DRCs--> <DRC type="INFO" text="Compare 0 Buff value have to be less or equal to Period 0 (Period). A value larger than period is uses to get 100% duty cycle (Left Aligned alignment) or 0% duty cycle (Right Aligned alignment)." condition="`${pPwmNePrs && pEnCAndNEnP && pC1GtP0}`" /> <DRC type="INFO" text="Compare 0 Buff value have to be less or equal to Period 1. A value larger than period is uses to get 100% duty cycle (Left Aligned alignment) or 0% duty cycle (Right Aligned alignment)." condition="`${pNePrsAndEnCAndEnP && pC1GtP1}`" /> <DRC type="INFO" text="Compare 0 Buff value have to be less or equal to Period 0 (Period). A value larger than period is uses to get 100% duty cycle (Left Aligned alignment) or 0% duty cycle (Right Aligned alignment)." condition="`${pNePrsAndEnCAndEnP && pAlignAsymm && pC1GtP0}`" /> <DRC type="ERROR" text="Compare 0 Buff value must be less or equal to Period 0 (Period)." condition="`${pAlignAsymmOrCenter && pEnCAndNEnP && pC1GtP0}`" paramId="Compare1" /> <DRC type="ERROR" text="Compare 0 Buff value must be less or equal to Period 1." condition="`${pNePrsAndEnCAndEnP && pAlignAsymmOrCenter && pC1GtP1}`" paramId="Compare1" /> <DRC type="ERROR" text="Compare 0 Buff value must be less or equal to Period 0 (Period)." condition="`${pNePrsAndEnCAndEnP && pAlignAsymmOrCenter && pC1GtP0}`" paramId="Compare1" /> <!--Compare1 DRCs--> <DRC type="INFO" text="Compare 1 value have to be less or equal to Period 0 (Period). A value larger than period is uses to get 100% duty cycle (Left Aligned alignment) or 0% duty cycle (Right Aligned alignment)." condition="`${pCntCC1 && pPwmNePrs && pC2GtP0}`" /> <DRC type="INFO" text="Compare 1 value have to be less or equal to Period 1. A value larger than period is uses to get 100% duty cycle (Left Aligned alignment) or 0% duty cycle (Right Aligned alignment)." condition="`${pCntCC1 && pPwmNePrs && EnablePeriodSwap && ((!EnableCompare1Swap) || pAlignAsymm) && pC2GtP1}`" /> <DRC type="ERROR" text="Compare 1 value must be less or equal to Period 0 (Period)." condition="`${pAlignAsymmOrCenter && pCntCC1 && pPwmNePrs && pC2GtP0}`" paramId="Compare2" /> <DRC type="ERROR" text="Compare 1 value must be less or equal to Period 1." condition="`${pAlignAsymmOrCenter && pCntCC1 && pPwmNePrs && EnablePeriodSwap && ((!EnableCompare1Swap) || pAlignAsymm) && pC2GtP1}`" paramId="Compare2" /> <!--Compare1Buff DRCs--> <DRC type="INFO" text="Compare 1 Buff value have to be less or equal to Period 0 (Period). A value larger than period is uses to get 100% duty cycle (Left Aligned alignment) or 0% duty cycle (Right Aligned alignment)." condition="`${pCntCC1 && pPwmNePrs && EnableCompare1Swap && ((!EnablePeriodSwap) || (EnablePeriodSwap && pAlignAsymm)) && pC3GtP0}`" /> <DRC type="INFO" text="Compare 1 Buff value have to be less or equal to Period 1. A value larger than period is uses to get 100% duty cycle (Left Aligned alignment) or 0% duty cycle (Right Aligned alignment)." condition="`${pCntCC1 && pPwmNePrs && EnablePeriodSwap && pC3GtP1}`" /> <DRC type="ERROR" text="Compare 1 Buff value must be less or equal to Period 0 (Period)." condition="`${pAlignAsymmOrCenter && pCntCC1 && pPwmNePrs && EnableCompare1Swap && ((!EnablePeriodSwap) || (EnablePeriodSwap && pAlignAsymm)) && pC3GtP0}`" paramId="Compare3" /> <DRC type="ERROR" text="Compare 1 Buff value must be less or equal to Period 1." condition="`${pAlignAsymmOrCenter && pCntCC1 && pPwmNePrs && EnablePeriodSwap && pC3GtP1}`" paramId="Compare3" /> <!--CountInput DRCs--> <DRC type="ERROR" text="Count Event has to be enabled to use Count Signal." condition="`${hasConnection("count", 0) && (CountInput eq CY_TCPWM_INPUT_DISABLED)}`" paramId="CountInput"> <FixIt action="SET_PARAM" target="CountInput" value="CY_TCPWM_INPUT_RISINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="CountInput" value="CY_TCPWM_INPUT_FALLINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="CountInput" value="CY_TCPWM_INPUT_EITHEREDGE" valid="true" /> <FixIt action="SET_PARAM" target="CountInput" value="CY_TCPWM_INPUT_LEVEL" valid="true" /> </DRC> <!--ReloadInput DRCs--> <DRC type="ERROR" text="Reload Event has to be enabled to use Reload Signal." condition="`${hasConnection("reload", 0) && (ReloadInput eq CY_TCPWM_INPUT_DISABLED)}`" paramId="ReloadInput"> <FixIt action="SET_PARAM" target="ReloadInput" value="CY_TCPWM_INPUT_RISINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="ReloadInput" value="CY_TCPWM_INPUT_FALLINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="ReloadInput" value="CY_TCPWM_INPUT_EITHEREDGE" valid="true" /> <FixIt action="SET_PARAM" target="ReloadInput" value="CY_TCPWM_INPUT_LEVEL" valid="true" /> </DRC> <!--StartInput DRCs--> <DRC type="ERROR" text="Start Event has to be enabled to use Start Signal." condition="`${hasConnection("start", 0) && (StartInput eq CY_TCPWM_INPUT_DISABLED)}`" paramId="StartInput"> <FixIt action="SET_PARAM" target="StartInput" value="CY_TCPWM_INPUT_RISINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="StartInput" value="CY_TCPWM_INPUT_FALLINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="StartInput" value="CY_TCPWM_INPUT_EITHEREDGE" valid="true" /> <FixIt action="SET_PARAM" target="StartInput" value="CY_TCPWM_INPUT_LEVEL" valid="true" /> </DRC> <!--SwapInput DRCs--> <DRC type="ERROR" text="Swap Event has to be enabled to use Swap Signal." condition="`${hasConnection("capture0", 0) && (SwapInput eq CY_TCPWM_INPUT_DISABLED)}`" paramId="SwapInput"> <FixIt action="SET_PARAM" target="SwapInput" value="CY_TCPWM_INPUT_RISINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="SwapInput" value="CY_TCPWM_INPUT_FALLINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="SwapInput" value="CY_TCPWM_INPUT_EITHEREDGE" valid="true" /> <FixIt action="SET_PARAM" target="SwapInput" value="CY_TCPWM_INPUT_LEVEL" valid="true" /> </DRC> <!--Kill0Input DRCs--> <DRC type="ERROR" text="Level is not supported for Stop on Kill mode." condition="`${((KillMode eq CY_TCPWM_PWM_STOP_ON_KILL) && (Kill0Input eq CY_TCPWM_INPUT_LEVEL))}`" paramId="Kill0Input" /> <DRC type="ERROR" text="Asynchronous Kill mode just supports Level mode." condition="`${((Kill0Input ne CY_TCPWM_INPUT_DISABLED) && (KillMode eq CY_TCPWM_PWM_ASYNC_KILL) && (Kill0Input ne CY_TCPWM_INPUT_LEVEL))}`" paramId="Kill0Input" /> <DRC type="ERROR" text="Synchronous Kill mode just supports Rising Edge mode." condition="`${((Kill0Input ne CY_TCPWM_INPUT_DISABLED) && pKillEqSynch && (Kill0Input ne CY_TCPWM_INPUT_RISINGEDGE))}`" paramId="Kill0Input" /> <DRC type="ERROR" text="Kill 0 Event has to be enabled to use Kill 0 Signal." condition="`${hasConnection("stop", 0) && (Kill0Input eq CY_TCPWM_INPUT_DISABLED)}`" paramId="Kill0Input"> <FixIt action="SET_PARAM" target="Kill0Input" value="CY_TCPWM_INPUT_RISINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="Kill0Input" value="CY_TCPWM_INPUT_FALLINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="Kill0Input" value="CY_TCPWM_INPUT_EITHEREDGE" valid="true" /> <FixIt action="SET_PARAM" target="Kill0Input" value="CY_TCPWM_INPUT_LEVEL" valid="true" /> </DRC> <!--Kill1Input DRCs--> <DRC type="ERROR" text="Level is not supported for Stop on Kill mode." condition="`${(pCntCC1 &&(KillMode eq CY_TCPWM_PWM_STOP_ON_KILL) && (Kill1Input eq CY_TCPWM_INPUT_LEVEL))}`" paramId="Kill1Input" /> <DRC type="ERROR" text="Asynchronous Kill mode just supports Level mode." condition="`${((Kill1Input ne CY_TCPWM_INPUT_DISABLED) && pCntCC1 &&(KillMode eq CY_TCPWM_PWM_ASYNC_KILL) && (Kill1Input ne CY_TCPWM_INPUT_LEVEL))}`" paramId="Kill1Input" /> <DRC type="ERROR" text="Synchronous Kill mode just supports Rising Edge mode." condition="`${((Kill1Input ne CY_TCPWM_INPUT_DISABLED) && pCntCC1 && pKillEqSynch && (Kill1Input ne CY_TCPWM_INPUT_RISINGEDGE))}`" paramId="Kill1Input" /> <DRC type="ERROR" text="Kill 1 Event has to be enabled to use Kill 1 Signal." condition="`${hasConnection("capture1", 0) && (Kill1Input eq CY_TCPWM_INPUT_DISABLED)}`" paramId="Kill1Input"> <FixIt action="SET_PARAM" target="Kill1Input" value="CY_TCPWM_INPUT_RISINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="Kill1Input" value="CY_TCPWM_INPUT_FALLINGEDGE" valid="true" /> <FixIt action="SET_PARAM" target="Kill1Input" value="CY_TCPWM_INPUT_EITHEREDGE" valid="true" /> <FixIt action="SET_PARAM" target="Kill1Input" value="CY_TCPWM_INPUT_LEVEL" valid="true" /> </DRC> <!--KillMode DRCs--> <DRC type="ERROR" text="Synchronous Kill mode is not supported for PWM Pseudo Random mode." condition="`${pKillEqSynch && (PwmMode eq CY_TCPWM_PWM_MODE_PSEUDORANDOM)}`" paramId="PwmMode" /> <!--Trigger Output DRCs--> <DRC type="ERROR" text="Trigger 0 Event has to be enabled to use Trigger 0 Signal." condition="`${hasConnection("tr_out0", 0) && (trigger0Event eq CY_TCPWM_CNT_TRIGGER_ON_DISABLED)}`" paramId="trigger0Event"> <FixIt action="SET_PARAM" target="trigger0Event" value="CY_TCPWM_CNT_TRIGGER_ON_OVERFLOW" valid="true" /> <FixIt action="SET_PARAM" target="trigger0Event" value="CY_TCPWM_CNT_TRIGGER_ON_UNDEFLOW" valid="true" /> <FixIt action="SET_PARAM" target="trigger0Event" value="CY_TCPWM_CNT_TRIGGER_ON_TC" valid="true" /> <FixIt action="SET_PARAM" target="trigger0Event" value="CY_TCPWM_CNT_TRIGGER_ON_CC0_MATCH" valid="true" /> <FixIt action="SET_PARAM" target="trigger0Event" value="CY_TCPWM_CNT_TRIGGER_ON_CC1_MATCH" valid="`${pCntCC1}`" /> <FixIt action="SET_PARAM" target="trigger0Event" value="CY_TCPWM_CNT_TRIGGER_ON_LINE_OUT" valid="true" /> </DRC> <DRC type="ERROR" text="Trigger 1 Event has to be enabled to use Trigger 1 Signal." condition="`${hasConnection("tr_out1", 0) && (trigger1Event eq CY_TCPWM_CNT_TRIGGER_ON_DISABLED)}`" paramId="trigger1Event"> <FixIt action="SET_PARAM" target="trigger1Event" value="CY_TCPWM_CNT_TRIGGER_ON_OVERFLOW" valid="true" /> <FixIt action="SET_PARAM" target="trigger1Event" value="CY_TCPWM_CNT_TRIGGER_ON_UNDEFLOW" valid="true" /> <FixIt action="SET_PARAM" target="trigger1Event" value="CY_TCPWM_CNT_TRIGGER_ON_TC" valid="true" /> <FixIt action="SET_PARAM" target="trigger1Event" value="CY_TCPWM_CNT_TRIGGER_ON_CC0_MATCH" valid="true" /> <FixIt action="SET_PARAM" target="trigger1Event" value="CY_TCPWM_CNT_TRIGGER_ON_CC1_MATCH" valid="`${pCntCC1}`" /> <FixIt action="SET_PARAM" target="trigger1Event" value="CY_TCPWM_CNT_TRIGGER_ON_LINE_OUT" valid="true" /> </DRC> </DRCs> <ConfigFirmware> <ConfigInclude value="cy_tcpwm_pwm.h" include="true" /> <ConfigInclude value="cy_sysclk.h" include="`${pclkOk}`" /> <ConfigInclude value="cycfg_routing.h" include="true" /> <ConfigInclude value="cyhal_hwmgr.h" include="true" guard="defined (CY_USING_HAL)" /> <ConfigDefine name="`${INST_NAME}`_HW" value="TCPWM`${tcpwmInst}`" public="true" include="true" /> <ConfigDefine name="`${INST_NAME}`_NUM" value="`${cntInst}`UL" public="true" include="true" /> <ConfigDefine name="`${INST_NAME}`_IRQ" value="tcpwm_`${tcpwmInst}`_interrupts_`${cntInst}`_IRQn" public="true" include="`${InterruptTC || InterruptCC0 || InterruptCC1}`" /> <ConfigDefine name="`${INST_NAME}`_INPUT_DISABLED" value="0x7U" public="false" include="true" /> <ConfigStruct name="`${INST_NAME . "_config"}`" type="cy_stc_tcpwm_pwm_config_t" const="`${inFlash}`" public="true" include="true"> <Member name="pwmMode" value="`${PwmMode}`" /> <Member name="clockPrescaler" value="`${ClockPrescaler}`" /> <Member name="pwmAlignment" value="`${PwmAlignment}`" /> <Member name="deadTimeClocks" value="`${DeadClocks}`" /> <Member name="runMode" value="`${RunMode}`" /> <Member name="period0" value="`${Period0}`" /> <Member name="period1" value="`${Period1}`" /> <Member name="enablePeriodSwap" value="`${EnablePeriodSwap}`" /> <Member name="compare0" value="`${Compare0}`" /> <Member name="compare1" value="`${Compare1}`" /> <Member name="enableCompareSwap" value="`${EnableCompare0Swap}`" /> <Member name="interruptSources" value="`${InterruptSource}`" /> <Member name="invertPWMOut" value="`${InvertPwm ? "CY_TCPWM_PWM_INVERT_ENABLE" : "CY_TCPWM_PWM_INVERT_DISABLE"}`" /> <Member name="invertPWMOutN" value="`${InvertPwm_n ? "CY_TCPWM_PWM_INVERT_ENABLE" : "CY_TCPWM_PWM_INVERT_DISABLE"}`" /> <Member name="killMode" value="`${KillMode}`" /> <Member name="swapInputMode" value="`${SwapInput eq CY_TCPWM_INPUT_DISABLED ? defineInputDisabled : SwapInput}`" /> <Member name="swapInput" value="`${SwapInput eq CY_TCPWM_INPUT_DISABLED ? "CY_TCPWM_INPUT_0" : (definePrefix . "_CAPTURE0_VALUE")}`" /> <Member name="reloadInputMode" value="`${ReloadInput eq CY_TCPWM_INPUT_DISABLED ? defineInputDisabled : ReloadInput}`" /> <Member name="reloadInput" value="`${ReloadInput eq CY_TCPWM_INPUT_DISABLED ? "CY_TCPWM_INPUT_0" : (definePrefix . "_RELOAD_VALUE")}`" /> <Member name="startInputMode" value="`${StartInput eq CY_TCPWM_INPUT_DISABLED ? defineInputDisabled : StartInput}`" /> <Member name="startInput" value="`${StartInput eq CY_TCPWM_INPUT_DISABLED ? "CY_TCPWM_INPUT_0" : (definePrefix . "_START_VALUE")}`" /> <Member name="killInputMode" value="`${Kill0Input eq CY_TCPWM_INPUT_DISABLED ? defineInputDisabled : Kill0Input}`" /> <Member name="killInput" value="`${Kill0Input eq CY_TCPWM_INPUT_DISABLED ? "CY_TCPWM_INPUT_0" : (definePrefix . "_STOP_VALUE")}`" /> <Member name="countInputMode" value="`${CountInput eq CY_TCPWM_INPUT_DISABLED ? defineInputDisabled : CountInput}`" /> <Member name="countInput" value="`${CountInput eq CY_TCPWM_INPUT_DISABLED ? "CY_TCPWM_INPUT_1" : (definePrefix . "_COUNT_VALUE")}`" /> <Member name="swapOverflowUnderflow" value="`${((PwmAlignment eq CY_TCPWM_PWM_CENTER_ALIGN) || (PwmAlignment eq CY_TCPWM_PWM_ASYMMETRIC_ALIGN)) ? SwapUnderflowOverflow : false}`" /> <Member name="immediateKill" value="`${ImmediateKill}`" /> <Member name="tapsEnabled" value="`${TapsEnabled}`" /> <Member name="compare2" value="`${pCntCC1 ? Compare2 : "CY_TCPWM_GRP_CNT_CC0_DEFAULT"}`" /> <Member name="compare3" value="`${pCntCC1 ? Compare3 : "CY_TCPWM_GRP_CNT_CC0_BUFF_DEFAULT"}`" /> <Member name="enableCompare1Swap" value="`${EnableCompare1Swap}`" /> <Member name="compare0MatchUp" value="`${Compare0MatchUp}`" /> <Member name="compare0MatchDown" value="`${Compare0MatchDown}`" /> <Member name="compare1MatchUp" value="`${Compare1MatchUp}`" /> <Member name="compare1MatchDown" value="`${Compare1MatchDown}`" /> <Member name="kill1InputMode" value="`${Kill1Input eq CY_TCPWM_INPUT_DISABLED ? defineInputDisabled : Kill1Input}`" /> <Member name="kill1Input" value="`${Kill1Input eq CY_TCPWM_INPUT_DISABLED ? "CY_TCPWM_INPUT_0" : (definePrefix . "_CAPTURE1_VALUE")}`" /> <Member name="pwmOnDisable" value="`${PwmDisabledOutput}`" /> <Member name="trigger0Event" value="`${trigger0Event}`" /> <Member name="trigger1Event" value="`${trigger1Event}`" /> </ConfigStruct> <ConfigStruct name="`${INST_NAME}`_obj" type="cyhal_resource_inst_t" const="true" public="true" include="true" guard="defined (CY_USING_HAL)"> <Member name="type" value="CYHAL_RSC_TCPWM" /> <Member name="block_num" value="`${getInstNumber("tcpwm")}`U" /> <Member name="channel_num" value="`${getInstNumber("cnt")}`U" /> </ConfigStruct> <ConfigInstruction value="Cy_SysClk_PeriphAssignDivider(`${pclkDst}`, `${getExposedMember(pclk, "clockSel")}`);" include="`${pclkOk}`" /> <ConfigInstruction value="cyhal_hwmgr_reserve(&`${INST_NAME}`_obj);" include="true" guard="defined (CY_USING_HAL)" /> </ConfigFirmware> </Personality>