Bird
0
0
Raspberry Piprogramming~10 mins

Enabling I2C on Raspberry Pi - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to install the I2C tools package on Raspberry Pi.

Raspberry Pi
sudo apt-get [1] i2c-tools
Drag options to blanks, or click blank then click option'
Aremove
Bupgrade
Cupdate
Dinstall
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'remove' instead of 'install' will uninstall the package.
Using 'update' or 'upgrade' does not install new packages.
2fill in blank
medium

Complete the command to open the Raspberry Pi configuration tool.

Raspberry Pi
sudo raspi-config [1]
Drag options to blanks, or click blank then click option'
Anonint
B--enable-i2c
Cnoninteractive
Dinteractive
Attempts:
3 left
💡 Hint
Common Mistakes
Using '--enable-i2c' directly is not a valid raspi-config option.
Using 'interactive' is the default mode, not a command option.
3fill in blank
hard

Fix the error in the command to enable I2C interface using raspi-config.

Raspberry Pi
sudo raspi-config [1] i2c
Drag options to blanks, or click blank then click option'
Adisable
Benable
Cset
Dget
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'disable' will turn off the I2C interface.
Using 'set' or 'get' are not valid for this command.
4fill in blank
hard

Fill both blanks to add I2C modules to the Raspberry Pi boot configuration.

Raspberry Pi
echo '[1]' | sudo tee -a /etc/modules
sudo modprobe [2]
Drag options to blanks, or click blank then click option'
Ai2c-dev
Bspi-dev
Ci2c-bcm2708
Di2c
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'spi-dev' instead of 'i2c-dev' is wrong for I2C.
Using 'i2c' alone is not a valid module name.
5fill in blank
hard

Fill all three blanks to check connected I2C devices on Raspberry Pi.

Raspberry Pi
sudo [1] -y [2]
Drag options to blanks, or click blank then click option'
Ai2cdetect
B1
C0
Di2cdump
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'i2cdump' instead of 'i2cdetect' will not scan devices.
Using bus 0 instead of 1 may not detect devices on newer models.