Skip to content

Commit

Permalink
EV3 populate distance from either IR or UltraSonic sensor.
Browse files Browse the repository at this point in the history
  • Loading branch information
SirTechington committed Dec 2, 2019
1 parent d47ea58 commit ccd3c57
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/extensions/scratch3_ev3/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ const Ev3Device = {
29: 'color',
30: 'ultrasonic',
32: 'gyro',
33: 'ir',
16: 'touch',
8: 'mediumMotor',
7: 'largeMotor',
Expand All @@ -129,6 +130,7 @@ const Ev3Mode = {
touch: 0, // touch
color: 1, // ambient
ultrasonic: 1, // inch
ir: 0, // proximity
none: 0
};

Expand All @@ -140,7 +142,8 @@ const Ev3Mode = {
const Ev3Label = {
touch: 'button',
color: 'brightness',
ultrasonic: 'distance'
ultrasonic: 'distance',
ir: 'distance'
};

/**
Expand Down

0 comments on commit ccd3c57

Please sign in to comment.