Skip to Main Content
The Art of LEGO MINDSTORMS NXT-G Programming
book

The Art of LEGO MINDSTORMS NXT-G Programming

by Terry Griffin
August 2010
Intermediate to advanced content levelIntermediate to advanced
288 pages
13h 21m
English
No Starch Press
Content preview from The Art of LEGO MINDSTORMS NXT-G Programming

attach the wires

It’s easier to add the wires now before you add the final beam. Table 3-1 shows how to connect the motors and sensors to the NXT.

Table 3-1. cable connections

motor or sensor

port

cable length

Motor on the Ultrasonic Sensor side

B

14 inches (35 cm)

Motor on the Color/Light Sensor side

C

14 inches (35 cm)

Touch Sensor

1

8 inches (20 cm)

Sound Sensor

2

14 inches (35 cm)

Color or Light Sensor

3

14 inches (35 cm)

Ultrasonic Sensor

4

20 inches (50 cm)

The motors use ports B and C to match the default settings for the Move Block. Likewise, the NXT-G blocks that use sensors default to the port listed in the table. Any motor or sensor will work using any port (for example, the Touch Sensor works just as well using port 4 as it does using port 2), but using ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

The Art of LEGO MINDSTORMS EV3 Programming (Full Color)

The Art of LEGO MINDSTORMS EV3 Programming (Full Color)

Terry Griffin

Publisher Resources

ISBN: 9781593272180Errata