Skip to content

Latest commit

 

History

History
107 lines (102 loc) · 2.86 KB

LEGO-EV3-Ultrasonic-Sensor-(45504).md

File metadata and controls

107 lines (102 loc) · 2.86 KB

General

This sensor uses the [[msensor|Using the Mindstorms Sensor Device Class]] device class.

Value
type_id 30
# Modes 7
Connection UART

Modes

Mode 0 Mode 1 Mode 2 Mode 31 Mode 41 Mode 5 Mode 6
mode US-DIST-CM US-DIST-IN US-LISTEN US-SI-CM US-SI-IN US-DC-CM US-DC-IN
Description Continuous measurement Continuous measurement Listen Single measurement Single measurement ??? ???
num_values 1 1 1 1 1 1 1
value0 Distance Distance Presence of another ultrasonic sensor Distance Distance Distance Distance
 Min 0 (0.0 cm) 0 (0.0 in) 0 (no other sensors detected) 0 (0.0 cm) 0 (0.0 in) 0 (0.0 cm) 0 (0.0 in)
 Max 2550 (255.0 cm) 1003 (100.3 in) 1 (another ultrasonic sensor was detected) 2550 (255.0 cm) 1003 (100.3 in) 2550 (255.0 cm) 1003 (100.3 in)
units cm (centimeters) in (inches) none cm (centimeters) in (inches) cm (centimeters) in (inches)
dp (decimal places) 1 1 0 1 1 1 1
LED State On, steady On, steady On, blinking On momentarily when mode is set, then off On momentarily when mode is set, then off On, steady On, steady
Values in the tables that look like ```this``` are the names of sysfs attributes or values returned by said attributes.

[1]: SI means SIngle shot mode. The value is read when the mode is set and does not change. To read a new value, set the mode again (e.g. echo US-SI-CM > mode).