Difference between revisions of "MotoHawk:Blocks:Synchronized PWM Child"

From MotoHawk
Jump to navigationJump to search
(Common Errors)
(Block Parameters)
 
(2 intermediate revisions by the same user not shown)
Line 15: Line 15:
 
[[Image:Synchronized_PWM_Child.PNG]]
 
[[Image:Synchronized_PWM_Child.PNG]]
  
A synchronized PWM child may have an independent duty cycle from the parent. Either choose the resource to reference, or provide the name of a resource by name, as defined by a PWM Output block. This is necessary when the parent pin is made calibratable. The Duty Cycle input is an int16, ranging from -4096 to 4096, where 0 is 0%, 4096 is 100%. When the value is negative the polarity is reversed, this is only valid on PWM resources that are H-Bridge outputs, like ETC or H1. Phase offset delays the phase input/4096% of the period. A phase offset of 0 will have it start at the same time as the parent and 2048 would have it be delayed half the period of the parent. When "Output Current" is checked, the drive current in milliamps is provided. When "Output Fault Status" is checked, a value indicating fault status is provided. This value is one of: 0 - OK, 1 - Fault, 2 - Indeterminate.
+
A synchronized PWM child has an independent duty cycle, but has a defined phase relationship with a parent.
 +
 
 +
The MotoHawk block help topic [http://mcs.woodward.com/content/motohawk/Documentation/CurrentVersion/HTML/MotoHawk_lib_Blocks/SynchronizedPWMChild.html Synchronized PWM Child] provides up to date help content for this block.
  
 
==Limitations==
 
==Limitations==
 +
The level of child PWM support is defined by the capability of the hardware. Modules that can't support this capability will not populate resources in the drop down menu. Modules that have capability will have selectable resources. However in some cases the selected child can only be used with a subset of the PWM Outputs that the module has at its disposal. Generally only PWM resources that can operate as a child can be selected to operate as a parent to a child PWM. There can also be further limitations. Build or runtime errors will result (depending on the module type) if a legal child PWM attempts to use an incompatible parent PWM.
  
This block currently only works for 5xx processor targets, each parent can only have two or fewer child PWMs, and the parent and child resources must reside on the same [../MotoHawk_topics/TPU.html TPU bank]. <br /><br /> If the resource is not behaving as exspected there are a few common errors. To check the common errors look at the resource creation status in the display(System|Debug|Resources|PWM|"ResourceName").
+
The number of children that a parent PWM Output can support may also be limited.
 
 
===Common Errors===
 
 
 
 
 
{| class="TableMHStyle"
 
! class="TableHeaderTDStyle" style="width: 100px" | Error Enum
 
! class="TableHeaderTDStyle" style="width: 300px" | Common Causes
 
|- id="tpu_config"
 
| class="TableTDStyle" valign="top" | TPU Config
 
| class="TableTDStyle" valign="top" | Check parent PWM is enabled as parent PWM.<br /> Check parent and child are on same [http://mcs.woodward.com/content/motohawk/Documentation/CurrentVersion/HTML/MotoHawk_topics/TPU.html TPU bank].
 
|- id="tpu_primative_usage"
 
| class="TableTDStyle" valign="top" | TPU Primative Usage
 
| class="TableTDStyle" valign="top" | Use 2 or fewer child PWM per parent PWM.
 
|- id="tpu_primative_count"
 
| class="TableTDStyle" valign="top" | TPU Primative Count
 
| class="TableTDStyle" valign="top" | Use 2 or fewer child PWM per parent PWM.
 
|- id="hardware_not_support"
 
| class="TableTDStyle" valign="top" | Hardware not Supported
 
| class="TableTDStyle" valign="top" | Check that resource is on a [http://mcs.woodward.com/content/motohawk/Documentation/CurrentVersion/HTML/MotoHawk_topics/TPU.html TPU bank].
 
|}
 
 
 
==Block Parameters==
 
 
 
{| class="TableMHStyle"
 
! class="TableHeaderTDStyle" style="width: 172px" | Parameter Field
 
! class="TableHeaderTDStyle" style="width: 158px" | Values
 
! class="TableHeaderTDStyle" style="width: 299px" | Comments/Description
 
|- id="text_resource"
 
| class="TableTDStyle" style="width: 172px; height: 38px" valign="top" | Resource
 
| class="TableTDStyle" style="width: 158px; height: 38px" valign="top" | Drop-down list
 
| class="TableTDStyle" style="width: 299px; height: 38px" valign="top" | Select from available resource, per target ECU, such as H-bridge, etc.
 
|- id="ref_type"
 
| class="TableTDStyle" style="width: 172px" valign="top" | Parent Reference Type
 
| class="TableTDStyle" style="width: 158px" valign="top" |
 
| class="TableTDStyle" style="width: 299px" valign="top" | Select Method for choosing resource of Parent
 
|-
 
| class="TableTDStyle" style="width: 172px" rowspan="2" valign="top" |
 
| class="TableTDStyle" style="width: 158px" valign="top" | By Resource
 
| class="TableTDStyle" style="width: 299px" valign="top" | Enable Drop-down list
 
|-
 
| class="TableTDStyle" style="width: 158px" valign="top" | By VarDec Name
 
| class="TableTDStyle" style="width: 299px" valign="top" | Open Parent Name field
 
|- id="text_resource_parent"
 
| class="TableTDStyle" style="width: 172px" valign="top" | Parent Resource
 
| class="TableTDStyle" style="width: 158px" valign="top" | Drop-down list
 
| class="TableTDStyle" style="width: 299px" valign="top" | Select Parent Resource from available resource, per target ECU, such as H-bridge, etc.
 
|- id="parent_nam"
 
| class="TableTDStyle" style="width: 172px" valign="top" | Parent Name
 
| class="TableTDStyle" style="width: 158px" valign="top" | Alpha-numeric text, single-quote enclosed
 
| class="TableTDStyle" style="width: 299px" valign="top" | Indicate exact Name of Parent Resource. No special characters, such as spaces, dashes, commas (underscore allowed).
 
|- id="output_current"
 
| class="TableTDStyle" style="width: 172px" valign="top" | Output Current
 
| class="TableTDStyle" style="width: 158px" valign="top" | Check box  (enable)
 
| class="TableTDStyle" style="width: 299px" valign="top" | When "Output Current" is checked, the drive current in milliamps is provided.
 
|- id="output_fault_status"
 
| class="TableTDStyle" style="width: 172px; height: 112px" valign="top" | Output Fault Status
 
| class="TableTDStyle" style="width: 158px; height: 112px" valign="top" | Check box  (enable)
 
| class="TableTDStyle" style="width: 299px; height: 112px" valign="top" |
 
When "Output Fault Status" is checked, a value indicating fault status is provided. This value is one of: <br /> 0 - OK <br /> 1 - Fault <br /> 2 - Indeterminate
 
|- id="use_vardec"
 
| class="TableTDStyle" style="width: 172px" valign="top" | Allow I/O pin to be calibrated from MotoTune
 
| class="TableTDStyle" style="width: 158px" valign="top" | Check box  (enable)
 
| class="TableTDStyle" style="width: 299px" valign="top" | Name, Access Levels and MotoTune Group Strings fields available
 
|- id="nam"
 
| class="TableTDStyle" style="width: 172px" valign="top" | Name
 
| class="TableTDStyle" style="width: 158px" valign="top" | Alpha-numeric text, single-quote enclosed
 
| class="TableTDStyle" style="width: 299px" valign="top" | Name as displayed in MotoTune, for block. No special characters, such as spaces, dashes, commas (underscore allowed)
 
|- id="read_level"
 
| class="TableTDStyle" style="width: 172px" valign="top" | Read Access Level
 
| class="TableTDStyle" style="width: 158px" valign="top" | 1-4
 
| class="TableTDStyle" style="width: 299px" valign="top" | Sets security level 1 lowest, 4 highest, for user access to read value
 
|- id="write_level"
 
| class="TableTDStyle" style="width: 172px" valign="top" | Write Access Level
 
| class="TableTDStyle" style="width: 158px" valign="top" | 1-4
 
| class="TableTDStyle" style="width: 299px" valign="top" | Sets security level 1 lowest, 4 highest, for user access to write value
 
|- id="group"
 
| class="TableTDStyle" style="width: 172px" valign="top" | MotoTune Group String
 
| class="TableTDStyle" style="width: 158px" valign="top" | Alpha-numeric text, single-quote enclosed
 
| class="TableTDStyle" style="width: 299px" valign="top" | Determines Folder name and hierarchy as displayed in MotoTune. Use "|" character between folder names to delineate subfolder structure
 
|}
 
  
</div>
+
The [http://mcs.woodward.com/content/motohawk/Documentation/MotoHawk2016bSP0/HTML/MotoHawk_lib_Blocks/SynchronizedPWMChild.html Synchronized PWM] help topic provides additional information.

Latest revision as of 01:42, 24 May 2017

Synchronized PWM Child

This MotoHawk™ block references a PWM parent block, and drives the output with a square wave with a specified phase offset relative to the parent.

Block ID

motohawk_pwm_child

Library

MotoHawk_lib/Analog I/O Blocks

Description

Synchronized PWM Child.PNG

A synchronized PWM child has an independent duty cycle, but has a defined phase relationship with a parent.

The MotoHawk block help topic Synchronized PWM Child provides up to date help content for this block.

Limitations

The level of child PWM support is defined by the capability of the hardware. Modules that can't support this capability will not populate resources in the drop down menu. Modules that have capability will have selectable resources. However in some cases the selected child can only be used with a subset of the PWM Outputs that the module has at its disposal. Generally only PWM resources that can operate as a child can be selected to operate as a parent to a child PWM. There can also be further limitations. Build or runtime errors will result (depending on the module type) if a legal child PWM attempts to use an incompatible parent PWM.

The number of children that a parent PWM Output can support may also be limited.

The Synchronized PWM help topic provides additional information.