You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: simulator/simulator_programming.md
+8-8Lines changed: 8 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -103,14 +103,14 @@ This is shown as a red coloured block on the robot. Using the `digital_read` me
103
103
104
104
Analogous to ultrasound sensors, distance sensors allow you to retrieve the distance between your robot and an object. These are attached to analog pins A0-A5:
105
105
106
-
| Pin | Location |
107
-
|-----|-------------|
108
-
| A0 | Front Left |
109
-
| A1 | Front Right |
110
-
| A2 | Left |
111
-
| A3 | Right |
112
-
| A4 | Front |
113
-
| A5 | Back |
106
+
| Pin | Location | Required Mode |
107
+
|-----|-------------|---------------|
108
+
| A0 | Front Left |`INPUT`|
109
+
| A1 | Front Right |`INPUT`|
110
+
| A2 | Left |`INPUT`|
111
+
| A3 | Right |`INPUT`|
112
+
| A4 | Front |`INPUT`|
113
+
| A5 | Back |`INPUT`|
114
114
115
115
These are shown as blue boards with silver transceivers on the robot. The `analog_read` method will return the distance in metres. They can see in a narrow cone up to a maximum of about 2m away.
116
116
Since these sensors rely on echoes being reflected back from objects, if the angle of incidence between the sensor's pulse and the contacted surface exceeds 22.5 degrees then the sensor will be unable to detect the object.
0 commit comments