Component: Photo Reflector (Light): Difference between revisions
Appearance
m Text replacement - "width="10%" align="center" style="background-color:#D8C9D8;" align="center"" to "width="10%" align="center" class="mtx-class-macrohead"" |
m Text replacement - "style="background-color:#EAE1EA;"" to "class="mtx-class-propfolder"" |
||
| (3 intermediate revisions by the same user not shown) | |||
| Line 65: | Line 65: | ||
|- | |- | ||
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''Initialise''' | ||
|- | |- | ||
| colspan="2" | Sets up the I/O to allow the sensor to operate. | | colspan="2" | Sets up the I/O to allow the sensor to operate. | ||
| Line 79: | Line 79: | ||
|- | |- | ||
| width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-comp-macro.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''SampleSensor''' | ||
|- | |- | ||
| colspan="2" | Samples the sensor and automatically controls the emitter pin if enabled. Returns the analogue reading from the sensor pin. | | colspan="2" | Samples the sensor and automatically controls the emitter pin if enabled. Returns the analogue reading from the sensor pin. | ||
| Line 93: | Line 93: | ||
{| class="mtx-class-macrotable wikitable" | {| class="mtx-class-macrotable wikitable" | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-macrohead" | [[File:Fc9-prop-icon.png]] | ||
| width="90%" | | width="90%" class="mtx-class-macrohead" | '''Properties''' | ||
|- | |- | ||
|- | |- | ||
| Line 102: | Line 102: | ||
| colspan="2" | Decides if the emitter needs to be switched on and off during sampling | | colspan="2" | Decides if the emitter needs to be switched on and off during sampling | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-propfolder" | [[File:Fc9-conn-icon.png]] | ||
| width="90%" | | width="90%" class="mtx-class-propfolder" | Connections | ||
|- | |- | ||
|- | |- | ||
| Line 111: | Line 111: | ||
| colspan="2" | Pin connected to the sensor element of the photo transistor | | colspan="2" | Pin connected to the sensor element of the photo transistor | ||
|- | |- | ||
| width="10%" align="center" | | width="10%" align="center" class="mtx-class-propfolder" | [[File:Fc9-conn-icon.png]] | ||
| width="90%" | | width="90%" class="mtx-class-propfolder" | Simulation | ||
|- | |- | ||
|- | |- | ||
Latest revision as of 14:36, 13 July 2026
| Author | Matrix Ltd |
| Version | 1.0 |
| Category | Light |
Photo Reflector component
Uses InfraRed light to detect if an external object is near to the sensor. Returns a discrete analogue signal which can represent distance from the nearest object. Useful for applications like wall following, control based systems and robotics.
Component Source Code
Please click here to download the component source project: FC_Comp_Source_PhotoReflector.fcfx
Please click here to view the component source code (Beta): FC_Comp_Source_PhotoReflector.fcfx
Detailed description
No detailed description exists yet for this component
Examples
No additional examples
Macro reference
Initialise
| Initialise | |
| Sets up the I/O to allow the sensor to operate. | |
| Return | |
SampleSensor
| SampleSensor | |
| Samples the sensor and automatically controls the emitter pin if enabled. Returns the analogue reading from the sensor pin. | |
| Return | |