3-Wire Devices#

3-Wire devices connect to the three-pin ports on the V5 Brain. These devices include sensors, legacy motors, and actuators that communicate using simple analog or digital signals.

Below is a list of available 3-Wire devices:

  • 3-Wire Expander – A 3-Wire Expander adds additional 3-Wire ports when all of a Brain’s built-in ports are in use.

  • Accelerometer – Detects acceleration and tilt along multiple axes to measure motion and orientation. The sensor includes a jumper that adjusts sensitivity between 2G and 6G ranges.

  • Addressable LED – Controls LED strips from a 3-Wire port, allowing individual LEDs to be set to specific colors and patterns.

  • Analog – Reads a continuous voltage signal from an analog 3-Wire sensor to report values across a range.

  • Bumper Switch – A spring-loaded switch used for detecting collisions or impacts on the robot.

  • Digital In – Reads binary input signals (HIGH or LOW) from external devices such as switches or sensors.

  • Digital Out – Sends binary output signals (HIGH or LOW) to control external devices like LEDs or relays.

  • Encoder – Measures the relative rotational position and direction of a shaft to determine speed or distance traveled.

  • Gyro Sensor – The Gyro Sensor measures the heading and the rotation of the robot.

  • LED Indicator – Controls LED Indicators by turning them on or off.

  • Light Sensor – Measures the intensity of ambient light to detect brightness or contrast changes in the robot’s environment.

  • Limit Switch – A small switch that detects contact with objects or surfaces.

  • Line Tracker – Detects differences in light reflection, allowing the robot to follow lines on the field surface.

  • Motor 393 – A legacy DC motor from VEX EDR systems.

  • Object Sensor – Uses infrared reflection to detect whether an object is nearby, returning a digital signal when something is within range.

  • Potentiometer – Measures the angular position of a rotating shaft or mechanism. The sensor supports 270 degrees of rotation.

  • V5 Pneumatics – Control the V5 Pneumatic Solenoid.

  • Pulse Width Modulation (PWM) – Outputs a pulse-width-modulated control signal through a 3-Wire port to drive legacy motor controllers or servos.

  • Range Finder – Uses ultrasonic sound waves to measure the distance between the sensor and nearby objects.

  • Servo Motor – A position-controlled motor used to rotate mechanisms to specific angles.

  • Victor Motor – A legacy motor controller that takes a 3-Wire PWM signal from the Brain to control VEXpro/EDR DC motors that can’t plug directly into Smart Ports.

These devices connect to one of eight 3-Wire ports (a through h) on the V5 Brain or a 3-Wire Expander. When constructing a 3-Wire device, pass the correct port as the port argument:

  • On the V5 Brain, ports are accessed through brain.three_wire_port (for example, brain.three_wire_port.a).

  • On a 3-Wire Expander, ports are accessed directly from the expander instance (for example, expander.a).

# Connect a Gyro Sensor to the Brain's E port
gyro_sensor = Gyro(brain.three_wire_port.e)

# Connect a Line Tracker to the 3-Wire Expander's C port
line_tracker = Line(expander.c)

For more information on constructing a 3-Wire Expander, go here.