Distance Sensor

NOTE - You need firmware v0.0.124 or above for this add-on to function. Please use the app to check for updates available.

To connect your Distance Sensor to your Marty you will need:

  • A mounted distance sensor plus cable
  • A Marty

Attaching the Distance Sensor

Open the back of Marty's head, take off the top plate and open the face.

You can now see the I2C ports on the front of the RIC plug the other end of the Distance Sensor cable into port B6 (shown to the right of the Eye servo in the picture below).

distance_sensor_attached.jpg

Slide the mounted Distance Sensor onto the front of the face, pushing it down as far as it will go and pushing it into the side of the face as shown below.

You can now close the face, ensuring the mount is securely held by the face plate.

distance_sensor_-_attached_with_closed_head.jpg

Configuring the Distance Sensor

Before you can use your Distance Sensor you must configure it to your Robot. This is done using the app, you are just naming the Add-on in the app.

Step 1.

Open the app and connect to your Marty.

tempfileforshare_20201110-120854.jpg

Step 2.

PrintChoose “configure”, then, “Add-ons”.

Print

Step 3.

Select the Add-on which doesn't have a name.

tempfileforshare_20201110-121423.jpg

Step 4. Name the add-on "DistanceSensor". Click "Update Name". **NOTE** the capital letters on Distance and Sensor and no space between the words; if the Add-on isn't named exactly, then Scratch won't be able to read it.

distancesensor.jpegNow that your distance sensor is named. Click into Scratch to start programming with it!