Difference between revisions of "Component: Quadrature Encoder 2D (General Input)"
From Flowcode Help
Jump to navigationJump to search| Line 17: | Line 17: | ||
==Component Source Code== | ==Component Source Code== | ||
| − | Please click here to download the component source project: [https://www.flowcode.co.uk/wiki/componentsource/ | + | Please click here to download the component source project: [https://www.flowcode.co.uk/wiki/componentsource/FC_Comp_Source_Encoder_Quadrature_2dgi.fcfx FC_Comp_Source_Encoder_Quadrature_2dgi.fcfx] |
| − | Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/ | + | Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/FC_Comp_Source_Encoder_Quadrature_2dgi.fcfx FC_Comp_Source_Encoder_Quadrature_2dgi.fcfx] |
==Detailed description== | ==Detailed description== | ||
| Line 48: | Line 48: | ||
''<span style="color:red;">No additional examples</span>'' | ''<span style="color:red;">No additional examples</span>'' | ||
| + | |||
| + | |||
Revision as of 13:10, 7 February 2023
| Author | Matrix TSL |
| Version | 1.4 |
| Category | General Input |
Contents
Quadrature Encoder 2D component
Quadrature Encoder component implements a rotary encoder connected to two pins. Quadrature Encoders provides incremental positioning rather than absolute positioning.
Component Source Code
Please click here to download the component source project: FC_Comp_Source_Encoder_Quadrature_2dgi.fcfx
Please click here to view the component source code (Beta): FC_Comp_Source_Encoder_Quadrature_2dgi.fcfx
Detailed description
No detailed description exists yet for this component
Examples
No additional examples
Macro reference
CheckForChanges
| CheckForChanges | |
| Polling function to check changes Returns 1 for chaged, 0 for no change, 255 for error | |
| Return | |
Disable
| Disable | |
| Disables the use of the quad encoder Once this ist called, the read functions will return zeros until the next Enable() call | |
| Return | |
Enable
| Enable | |
| Enables the use of the quad encoder If this is not called, the read functions will return zeros | |
| Return | |
ReadCounter
| ReadCounter | |
| Reads the current dial counter This is a counter from -32768 to 32767 | |
| Return | |
ReadCounter32
| ReadCounter32 | |
| Reads the current dial counter as a 32-bit value This is a counter from -2147483648 to 2147483647 | |
| Return | |
ResetCounter
| ResetCounter | |
| Resets the current dial counter to zero | |
| Return | |
Rotate
WriteCounter
| WriteCounter | |
| Sets the value of the internal count variable. Range: -32768 to 32767 | |
| Value | |
| Range: -32768 to 32767 | |
| Return | |
WriteCounter32
| WriteCounter32 | |
| Sets the value of the internal count variable. Range: -2147483648 to 2147483647 | |
| Value | |
| Range: -2147483648 to 2147483647 | |
| Return | |