0% found this document useful (0 votes)
31 views

Compute Module IO Board PLUS User Manual EN

I/o boarf

Uploaded by

Moni Fayez
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
31 views

Compute Module IO Board PLUS User Manual EN

I/o boarf

Uploaded by

Moni Fayez
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 17

Compute Module IO Board Plus User Manual

Compute Module IO Board Plus


User Manual

OVERVIEW S

⚫ This is an Expansion board of Raspberry Pi Compute Module series. It is compatible with


Compute Module IO Board V3 from Raspberry Pi Foundation, along with various
common use components. Supports Compute Module 3, Compute Module 3 Lite,
Compute Module 3+ (8G/16G/32G), Compute Module 3+ Lite.

FEATURES

⚫ Compatible with the Compute Module IO Board V3 from the Raspberry Pi Foundation

⚫ Raspberry Pi GPIO header, for connecting sorts of Raspberry Pi HATs

⚫ Arduino connectivity, also supports Arduino shields

⚫ 1-WIRE interface, for connecting single-bus devices like DS18B20

⚫ 4x keys, 4x LEDs, 1x Buzzer, for I/O testing

⚫ Onboard USB HUB, allows connecting more USB devices

⚫ IR receiver, IR remote control is available

⚫ Onboard USB TO UART, for serial debugging

⚫ Sensor interface

⚫ 10-bit ADC, 38KSPS, 11-ch (6-ch for Arduino interface, 5-ch for sensors)

⚫ 16-bit DAC, 2-ch

⚫ Onboard RTC, one of the most common and useful functions

W HAT’S ONBOARD

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

1. Compute Module interface: for 7. USB ports: for connecting USB


connecting Compute Module 3, devices
Compute Module 3 Lite, Compute
8. USB SLAVE interface: allows you to
Module 3+ (8G/16G/32G) or Compute
burn system image in to Compute
Module 3+ Lite
Module 3
2. Compute Module GPIO header:
9. USB TO UART interface: for serial
breakout all the Compute Module pins
debugging
3. Raspberry Pi GPIO header: for
10. Arduino header: for connecting
connecting Raspberry Pi HATs
Arduino shields
4. CSI interface: camera ports, for
11. AD/DA input/output screw terminals
connecting Raspberry Pi Camera

12. 1-WIRE interface: for connecting


5. DSI interface: display ports, for
single-bus devices like DS18B20
connecting Raspberry Pi LCD

13. Sensor interface


6. HDMI port

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

14. Power port: 5V 2.5A 29. User Keys

15. FE1.1S: USB HUB chip 30. BOOT selection


- EN: enable the PC to access SD
16. 12MHz crystal
card/eMMC through USB SLAVE

17. CP2102: USB TO UART converter - DIS: the Compute Module will boot
from SD card/eMMC
18. Micro SD card slot: insert a Micro SD
card with pre-burnt system, to start up 31. VGx power selection: config the I/O

Compute Module 3 Lite level

19. TLC1543: AD converter 32. USB HUB enable jumper: HUB


enable and USB SLAVE power
20. DAC8552: 16-bit DAC, 2-ch
selection

21. DS3231: high-precision RTC chip, I2C


33. ADC/DAC configuration: config the
interface
power supply and reference voltage of

22. RTC battery holder: supports CR1220 ADC/DAC

batteries
34. Peripheral configuration: config the

23. Voltage regulator: 3.3V / 2.5V / 1.8V control pins of UART, user keys, user
LEDs, 1-WIRE interface, IR receiver,
24. LFN0038K: IR receiver and buzzer

25. Buzzer 35. Arduino AD selection


- connect 1 and 2: Arduino A0-A5 as
26. Power indicator
digital control pin
27. ACT indicator: indicating the Micro SD - connect 2 and 3: Arduino A0-A5 as
card status AD input

28. User LEDs

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

CONTENTS

OverViews ................................................................................................................................ 1

Features ............................................................................................................................ 1

What’s OnBoard ................................................................................................................ 1

HOW TO USE .......................................................................................................................... 7

INSTALLATION ................................................................................................................. 7

CM3/CM3+ ................................................................................................................. 7

CM3L/CM3+ L ............................................................................................................ 7

Connecting display and Camera ....................................................................................... 8

Connecting the officail 7inch display .......................................................................... 8

Connect Wveshare 7inch HDMI LCD (C) ................................................................... 8

Connect Camera ........................................................................................................ 8

Examples ................................................................................................................................ 10

Buzzer ............................................................................................................................. 10

pyhton code.............................................................................................................. 10

WiringPi code ........................................................................................................... 10

Expected result ........................................................................................................ 11

DAC ................................................................................................................................. 11

BCM2835 code ........................................................................................................ 11

Expected result ........................................................................................................ 11

DS18B20 ......................................................................................................................... 11

sysfs code ................................................................................................................ 11

python code.............................................................................................................. 12

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

Expected result ........................................................................................................ 12

RTC DS3231 ................................................................................................................... 12

BCM2835 code ........................................................................................................ 12

WiringPi code ........................................................................................................... 12

Python code ............................................................................................................. 12

Expected result ........................................................................................................ 13

IRM .................................................................................................................................. 13

BCM2835 code ........................................................................................................ 13

WiringPi code ........................................................................................................... 13

Python code ............................................................................................................. 13

Expected result ........................................................................................................ 14

KEY ................................................................................................................................. 14

BCM2835 code ........................................................................................................ 14

WiringPi code ........................................................................................................... 14

Python code ............................................................................................................. 14

Expected result ........................................................................................................ 14

LED ................................................................................................................................. 14

BCM2835 code ........................................................................................................ 15

WiringPi code ........................................................................................................... 15

Python code ............................................................................................................. 15

Expected result ........................................................................................................ 15

ADC ................................................................................................................................. 15

BCM2835 code ........................................................................................................ 15

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

WiringPi code ........................................................................................................... 16

Python code ............................................................................................................. 16

Expected result ........................................................................................................ 16

UART............................................................................................................................... 16

WiringPi code ........................................................................................................... 16

Python code ............................................................................................................. 17

Expected result ........................................................................................................ 17

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

HOW TO USE

INSTALLATION

CM3/CM3+

If you use Compute Module 3 or Compute Module 3+, you need to write OS image to the
embedded EMMC, otherwise they cannot work. Here show you how to write image to EMMC

1. Pull the jumpers of USB SLAVE 1/2/3/4 SELECTION (you need to pull two jumpers
here), set the BOOT ENABLE USB SLAVE jumpers to EN position.

2. Install USB driver. Run the software rpiboot_setup (You can download it from Resource
of wiki) to install the drivers and boot tool.

3. Connect 5V power adapter to Power interface, plug the USB SLAVE port of IO Board
Plus into your host PC USB.

4. Run the rpiboot.exe tool. After a few seconds, the CM3 eMMC will be recognized as a
disk.

5. Run WinDiskImager.exe tool to burn the image to eMMC of CM3.

Note:

Ensure you are not writing to any USB devices while installation.
Because the eMMC of CM3 is only 4G, the image file flashed should be small than 4G. If you
want the GUI, you can install it with these commands after installation
sudo apt-get update
sudo apt-get install raspberrypi-ui-mods

CM3L/CM3+ L

1. Download the image for CM3L

2. Connect the SD card to computer with card reader. The capacity of SD card should
larger than 8G.

3. Run the Win32DiskImager.exe, choose the CM3L image and burn it to SD card.

4. After burning successfully, insert the card to the card slot of IO Board Plus

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

CONNECTING DISPLAY AND CAMERA

Download the test image provide by us and install them.

Note: Before using, please check that whether the BOOT ENABLE USB SLAVE jumper is set
onto the DIS option.

CONNECTING THE OFFIC AIL 7INCH DISPLAY

1. You need an adapter plate and a 22PIN FFC to connect the display to DISP1 interface of
IO Board Plus

2. Connect the 5V and GND pin of display to 5V and GND pin of IO Board Plus with wires.

3. Connect these pins together with wires:

GPIO0<->CD1_SDA

GPIO1<->CD1_SCL

4. Connect the power adapter

5. Wait for a few seconds, the display will be powered on.

CONNECT W VESHARE 7IN CH HDMI LCD (C)

1. Make sure the official 7inch display don’t be connect to IO Board Plus. Only without the
DISP interface display, the Raspbian will display via HDMI interface by default.

2. Connect the HDMI interface of LCD to the HDMI interface of IO Board IO Plus

3. Connect power adapter

4. Waiting for a few seconds, the LCD will be powered on

CONNECT CAMERA

1. Connect camera to the CAM1 interface of IO Board Plus (need RPi Zero V1.3 Camera
Cable 15cm)

2. Connect these pins together:

GPIO0<->CD1_SDA

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

GPIO1<->CD1_SCL

GPIO4<->CAM1_IO1

GPIO5<->CAM1_IO0

3. Connect to power

4. If you want to connect more than one camera, you can connect another to CAM0
interface.

5. Use the CAM0 interface, you need to connect these pins together:

GPIO28<->CD0_SDA

GPIO29<->CD0_SCL

GPIO30<->CAM0_IO1

GPIO31<->CAM0_IO0

6. Execute these commands to use the camera:

raspivid -t 0 -cs 0

raspivid -t 0 -cs 1

Note:

1. -cs: Used to choose the camera 0 or 1. Parameter 0 means CAM1, and 1 means CAM0

2. Original Raspbian has no boot files for official display and official. If you use original
Raspbian, you need to convert dts files which are provided by Raspberry Pi to bin files
and copy the bin files to pi/boot/ of Raspbian.

Commands:

sudo dtc -I dts -O dtb -o /boot/dt-blob.bin dt-blob-disp1-cam2.dts

If you use the image provide by us, the OS has been pre-configured. You need to
configure it again.

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

EXAMPLES

While test the examples, you had better connect a display and keyboard to the IO Board Plus.

If you use original Raspbian, you have to install necessary libraries before first. For more
information about how to install libraries, please refer to Libraries Installation for RPi.

BUZZER

PYHTON CODE

⚫ Execute command to enter the folder of program:

cd /home/pi/CM3/Buzzer_PWM/python/

⚫ Execute command to run the program:

sudo ./buzzer.py

W IRINGPI CODE

10

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

⚫ Execute command to enter the folder of program:

cd /home/pi/CM3/Buzzer_PWM/wiringPi/

⚫ Execute command to run the program:

sudo ./buzzer

EXPECTED RESULT

The buzzer will sound, and the sound is changing from low to high, and turn to low again.

Note:

The buzzer will sound even though not be used because of noise. In this case, you can pull
the buzzer jumper manually. (the last one of USER JMP)

DAC

BCM2835 CODE

⚫ Connect DA_A and DA_B to LED1 and LED2 of USER JMP separately with wires.

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/DAC8532

⚫ Execute command to run the program

sudo ./dac8532

EXPECTED RESULT

The brightness of LED1 and LED2 turns brighter and then turns dim alternately.

DS18B20

Testing this code, you need a DS18B20 module. Insert the DS18B20 into the 1-WIRE
interface of IO Board Plus. Note that the semicircle should faces the buzzer. The DS18B20
will produce high temperature even hurt your fingerprint if it is inserted incorrectly. Please be
carefully.

SYSFS CODE

11

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/DS18B20/fs/

⚫ Execute command to run the program

sudo ./ds18b20

PYTHON CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/DS18B20/python/

⚫ Execute command to run the program

sudo ./ds18b20.py

EXPECTED RESULT

The terminal will output the temperature value measured by DS18B20.

RTC DS3231

BCM2835 CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/DS3231/bcm2835/

⚫ Execute command to run the program

sudo ./ds3231

W IRINGPI CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/DS3231/wiringPi/

⚫ Execute command to run the program

sudo ./ds3231

PYTHON CODE
12

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/DS3231/python/

⚫ Execute command to run the program

sudo ./ds3231.py

EXPECTED RESULT

The terminal will output the information of date.

IRM

You need an infrared remote controller. Please take the interleaving paper down before using.

BCM2835 CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/IRM/bcm2835/

⚫ Execute command to run the program

sudo ./irm

W IRINGPI CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/IRM/wiringPi/

⚫ Execute command to run the program

sudo ./irm

PYTHON CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/IRM/python/

⚫ Execute command to run the program

sudo ./irm.py

13

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

EXPECTED RESULT

Press the buttons on Infrared Remote Controller, the terminal will output the corresponding
value.

KEY

BCM2835 CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/KEY/bcm2835/

⚫ Execute command to run the program

sudo ./key

W IRINGPI CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/KEY/wiringPi/

⚫ Execute command to run the program

sudo ./key

PYTHON CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/KEY/python/

⚫ Execute command to run the program

sudo ./key.py

EXPECTED RESULT

Press the keys (KEY1, KEY2, KEY3, KEY4), corresponding value will outputted on the
terminal. For example, if you press KEY1, the terminal will output press the key: 0.

LED

14

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

BCM2835 CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/LED/bcm2835/

⚫ Execute command to run the program

sudo ./led

W IRINGPI CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/LED/wiringPi/

⚫ Execute command to run the program

sudo ./led

PYTHON CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/LED/python/

⚫ Execute command to run the program

sudo ./led.py

EXPECTED RESULT

Four LEDs blink alternately.

ADC

BCM2835 CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/TLC1543/bcm2835/

⚫ Execute command to run the program

sudo ./tlc1543

15

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

W IRINGPI CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/TLC1543/wiringPi/

⚫ Execute command to run the program

sudo ./tlc1543

PYTHON CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/TLC1543/python/

⚫ Execute command to run the program

sudo ./tlc1543.py

EXPECTED RESULT

AD information are outputted on terminal.

UART

Connect the USB TO UART interface of IO Board Plus to PC with USB cable. Open the Putty
on your PC, set the Baudrate as 115200.
Enter the user name and password to log in the CM3/CM3L (user name is pi and password is
raspberry by default)

Here you need to run the program with keyboard and LCD (On IO Board Plus) instead of
Putty.

W IRINGPI CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/UART/wiringPi/

⚫ Execute command to run the program

sudo ./uart

16

Version:V1.0,Date:20171101
Compute Module IO Board Plus User Manual

PYTHON CODE

⚫ Execute command to enter the folder of program

cd /home/pi/CM3/UART/python/

⚫ Execute command to run the program

sudo ./uart.py

EXPECTED RESULT

Every time run the program, on the Putty, you can see that Hello World!!! is printed.

17

Version:V1.0,Date:20171101

You might also like