Difference between revisions of "Component: ADC (CAL) (Misc)"
From Flowcode Help
Jump to navigationJump to search| (12 intermediate revisions by the same user not shown) | |||
| Line 15: | Line 15: | ||
CAL - Code Abstraction Layer A low level implementation giving direct access to the analogue to digital converter peripheral. | CAL - Code Abstraction Layer A low level implementation giving direct access to the analogue to digital converter peripheral. | ||
| − | == | + | ==Detailed description== |
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| − | |||
| − | |||
| Line 36: | Line 44: | ||
==Examples== | ==Examples== | ||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| Line 54: | Line 74: | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | |||
| + | ==Macro reference== | ||
| + | |||
| + | ===Disable=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| Line 87: | Line 104: | ||
| + | ===Enable=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| Line 120: | Line 138: | ||
| + | ===GetList=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
| − | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetList''' |
|- | |- | ||
| − | | colspan="2" | | + | | colspan="2" | |
|- | |- | ||
|- | |- | ||
| − | | width="10%" align="center" | [[File:Fc9- | + | | width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING |
| − | | width="90%" | | + | | width="90%" | Name |
|- | |- | ||
| − | | colspan="2" | | + | | colspan="2" | |
|- | |- | ||
| − | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-string-icon.png]] - STRING |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
| + | ===GetValue=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
| − | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetValue''' |
|- | |- | ||
| − | | colspan="2" | | + | | colspan="2" | Gets the Name property value |
|- | |- | ||
|- | |- | ||
| Line 149: | Line 169: | ||
| width="90%" | Name | | width="90%" | Name | ||
|- | |- | ||
| − | | colspan="2" | | + | | colspan="2" | The name of the property |
| + | |- | ||
| + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-string-icon.png]] - STRING | ||
| + | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
| + | |} | ||
| + | |||
| + | |||
| + | ===Sample=== | ||
| + | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
| + | |- | ||
| + | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
| + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Sample''' | ||
| + | |- | ||
| + | | colspan="2" | Blocking call to read a sample on the currently enabled channel | ||
| + | |- | ||
|- | |- | ||
| − | | width="10%" align="center" | [[File:Fc9- | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
| − | | width="90%" | | + | | width="90%" | Sample_Mode |
|- | |- | ||
| − | | colspan="2" | | + | | colspan="2" | True to enable full-width sample (10 or 12 bits), else false for 8 bit |
|- | |- | ||
| − | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u16-icon.png]] - UINT |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
| + | ===SetValue=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
| − | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetValue''' |
|- | |- | ||
| − | | colspan="2" | | + | | colspan="2" | Sets the Value for the named property |
|- | |- | ||
|- | |- | ||
| Line 172: | Line 207: | ||
| width="90%" | Name | | width="90%" | Name | ||
|- | |- | ||
| − | | colspan="2" | | + | | colspan="2" | Name of property to update |
| + | |- | ||
| + | | width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING | ||
| + | | width="90%" | Value | ||
| + | |- | ||
| + | | colspan="2" | The new value for the property | ||
|- | |- | ||
| − | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
| − | |||
| − | |||
| Line 273: | Line 311: | ||
| colspan="2" | Selects if the scope traces are automatically generated or not | | colspan="2" | Selects if the scope traces are automatically generated or not | ||
|} | |} | ||
| + | |||
| + | ==Component Source Code== | ||
| + | |||
| + | Please click here to download the component source project: [https://www.flowcode.co.uk/wiki/componentsource/FC_Comp_Source_ADC.fcfx FC_Comp_Source_ADC.fcfx] | ||
| + | |||
| + | Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/FC_Comp_Source_ADC.fcfx FC_Comp_Source_ADC.fcfx] | ||
Latest revision as of 08:58, 9 June 2025
| Author | Matrix TSL |
| Version | 2.0 |
| Category | Misc |
Contents
ADC component
CAL - Code Abstraction Layer A low level implementation giving direct access to the analogue to digital converter peripheral.
Detailed description
No detailed description exists yet for this component
Examples
Example showing how to build a component using a CAL component Using CAL Components.
Macro reference
Disable
| Disable | |
| Disables the current ADC channel Call this once sampling is complete | |
| Return | |
Enable
GetList
| GetList | |
| Name | |
| Return | |
GetValue
| GetValue | |
| Gets the Name property value | |
| Name | |
| The name of the property | |
| Return | |
Sample
| Sample | |
| Blocking call to read a sample on the currently enabled channel | |
| Sample_Mode | |
| True to enable full-width sample (10 or 12 bits), else false for 8 bit | |
| Return | |
SetValue
| SetValue | |
| Sets the Value for the named property | |
| Name | |
| Name of property to update | |
| Value | |
| The new value for the property | |
| Return | |
Property reference
Component Source Code
Please click here to download the component source project: FC_Comp_Source_ADC.fcfx
Please click here to view the component source code (Beta): FC_Comp_Source_ADC.fcfx