Analog Input
R2026bRead analog values from the 3-wire port on VEX EDR V5 Robot Brain
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 Analog Input block reads analog values from the selected 3-wire port on VEX® EDR V5 Robot Brain. Use the block to measure the output of sensors (voltage), such as potentiometer, connected to the 3-wire port. The 12-bit sensor value has a range of 0 to 4095 that corresponds to an input voltage of 0V to 5V. You can use up to eight 3-wire ports on the VEX EDR V5 Robot Brain.
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/Analog Input"
Example: add_block("vexv5lib/Sensors/Analog Input","myModel/myBlock",MakeNameUnique="on")
Version History
Introduced in R2018b
