Optical Sensor
R2026bRead proximity, color, and brightness
Libraries:
Simulink Coder Support Package for VEX EDR V5 Robot Brain /
Sensors
Description
Add-On Required: This feature requires the Simulink Coder Support Package for VEX EDR V5 Robot Brain add-on.
The Optical Sensor block reads data from the optical sensor that is connected to the VEX® V5 Brain. You can use this block in your Simulink model to measure color, brightness, and proximity to an object from optical sensor.
Ports
Output
Parameters
Programmatic Use: Add Block
To add the block programmatically, use the add_block function with one of these library block paths as the source.
"vexv5lib/Sensors/Optical Sensor"
Example: add_block("vexv5lib/Sensors/Optical Sensor","myModel/myBlock",MakeNameUnique="on")
Extended Capabilities
Version History
Introduced in R2021b
