Google Chat: zj734465502@gmail.com
+86-0755-88291180
sales01@spotpear.com
dragon_manager@163.com
services01@spotpear.com
manager01@spotpear.com
WhatsApp:13246739196
This is the basic IO board of the 4th generation of Raspberry Pi Compute Module. CM4-IO-BASE-C is a carrier board that can be used with Raspberry Pi Compute Module 4. With a dedicated 40PIN LCD Connector, it also is easier and faster to be integrated into applications.
1. Do not unplug any devices except USB and HDMI when powering on.
2. Only support fans with 5V, and 12V is not supported. Please check the voltage of the fan before connecting.
3. Only support LCD direct connection as there is not a DSI interface.
4. Type C interface can be used as the power supply or the USB SLAVE for programming images.
5. In order to ensure the power supply of the CM4, please do not connect to other devices when programming the images with the TypeC interface.
6. When using CM4, you must provide 5V 2A for it, otherwise, it may shut down, lower frequency or etc.
7. Please use the matching screws when using the M.2 interface as CM4 may be damaged if you use other screws.
8. The module does not have any protection, please do not short-circuit the power supply.
9. USB2.0 is closed by default, and you need to add "dtoverlay=dwc2,dr_mode=host" in "config.txt" when using.
10. This expansion board does not support POE function.
Number | Name | Description | |
1 | CM4 Socket | For all variants of Compute Module 4 | |
2 | Power Supply/Programming Interface | 5V/2.5A power supply, or used as the eMMC programming interface | |
3 | LCD Interface | 40PIN LCD display port, for direct connection to 70H-1024600 series display | |
4 | FAN header | For connecting to the cooling fan with 5V, support speed adjustment and measurement | |
5 | CAM Interface | Dual-channel MIPI CSI | |
6 | HDMI0 Interface | HDMI interface, for supporting 4K 30fps output | |
7 | USB 2.0 Interface | 2-ch USB2.0 and support all kinds of USB devices | |
8 | Gigabit Ethernet port | RJ45 Gigabit Ethernet port, support 10 / 100 / 1000M network access | |
9 | M.2 Interface Indicator | Indicating the working status | |
10 | PWR Indicator | Indicating the Raspberry Pi power status | |
11 | Status Indicators | Indicating the working status of the Raspberry Pi | |
12 | BOOT | Jumper cap connected: CM4 Type C booting guide Jumper cap not connected: eMMc or SD card booting guide | |
13 | 40PIN GPIO Header | For connecting all kinds of HAT | |
14 | Micro SD Card Interface | For connecting to a Micro SD card with the system, only for the Lite version | |
15 | FE1.1S | USB HUB chip, expand USB interface to 4 | |
16 | M.2 Interface | For NVIE SSD, or support PCIE M.2 communication module | |
17 | RTC Chip | PCF85063 chip, can be used for RTC wake-up, shutdown, restart, or other functions | |
18 | RTC Interrupt Selection | PI-RUN:RTC triggers interrupt CM4 restarts GN-EN:RTC trigger interrupt CM4 shutdown D4:RTC trigger interrupt D4 pin trigger | |
19 | RTC Battery Connection Socket | For connecting to CR1220 button cells |
Do not plug and unplug any devices when powering on.
The USB port is disabled by default on the CM4 to save power. If you need to start, you need to add the following to the config.txt file:
dtoverlay=dwc2,dr_mode=host
After restarting
If you use the latest Raspberry Pi OS (image after October 30, 2021) USB2.0 is OTG mode by default, CM4 will report an error:
config failed, hub doesn't have any ports! (err -19)
However, USB can still be used. If you want to remove this error, remove otg_mode=1 in [cm4] of config.txt, and add dtoverlay=dwc2, dr_mode=host (USB cannot be recognized without adding it).
The M.2 interface type is M KEY, which only supports PCIE channel devices (including NVME solid state, etc.), and does not support SATA hard disks.
Some adapter cards are supported, and the PCIE channel is used. Some devices cannot be driven by the official Raspberry Pi image, and the kernel needs to be recompiled.
sudo nano /boot/config.txt
#Add the following lines at the end
dtparam=i2c_vc=on
dtoverlay=i2c-rtc,pcf85063a,i2c_csi_dsi
#Add # in front of dtparam=audio=on
#dtparam=audio=on
#Save and exit, restart
sudo reboot
Synchronize system clock to hardware clock
sudo hwclock -w
Synchronize hardware clock to system clock
sudo hwclock -s
#The network needs to be closed, otherwise, it will be changed back.
Set the hardware clock time:
sudo hwclock --set --date="9/8/2021 16:45:05"
View hardware clock
sudo hwclock -r
Display version information
sudo hwclock --verbose
The fan PWM pin is connected to GPIO18.
CM4-IO-Base-C only has CSI but not DSI.
CSI and DSI are disabled by default. When using the camera and DSI, it will occupy three I2C devices: I2C-10, I2C-11, and I2C-0.
wget https://www.waveshare.com/w/upload/7/75/CM4_dt_blob_Source.zip
unzip -o CM4_dt_blob_Source.zip -d ./CM4_dt_blob_Source
sudo chmod 777 -R CM4_dt_blob_Source
cd CM4_dt_blob_Source/
sudo dtc -I dts -O dtb -o /boot/dt-blob.bin dt-blob-disp0-double_cam.dts
#If you need to restore, please delete the corresponding dt-blob.bin: sudo rm -rf /boot/dt-blob.bin
# After execution, turn off the power and restart the CM4
Connect the cameras:
1: Please power off the IO Board first before your connection.
2: Connect the power adapter after connecting the cameras and DSI display.
3: Wait a few seconds before the screen boot up.
4: If the DSI LCD cannot display, please check if you have added /boot/dt-blob.bin. If there already has the dt-blob.bin, just try to reboot.
Run the "raspi-config" in the camera, choose Interfacing Options->Camera->Yes->Finish-Yes, reboot the system, open "enable camera", and then reboot to save the change.
Test camera0:
sudo raspivid -t 0 -cs 0
Test camera1:
sudo raspivid -t 0 -cs 1
If you are using the latest Raspberry Pi OS (Bullseye):
#Use dual cameras in the new system
#Remove "camera_auto_detect=1" in config.txt
#camera_auto_detect=1
#Add
dtoverlay=imx219,cam1
dtoverlay=imx219,cam0
#imx219 is the model of the camera sensor, and it also supports other sensors.
dtoverlay=ov5647,cam0
dtoverlay=imx219,cam0
dtoverlay=ov9281,cam0
dtoverlay=imx477,cam0
dtoverlay=imx519,cam0
#Then reboot
reboot
#Open the camera
libcamera-hello -t 0
or
libcamera-hello
#Other commands:
#Check whether the camera is detected
libcamera-hello --list-cameras
#Open the corresponding camera for previewing 5 seconds
libcamera-hello --camera 1
libcamera-hello --camera 0
#Take a picture
libcamera-jpeg -o test.jpg
#Record a vedio
libcamera-vid -t 10000 -o test.h264
#You can add "--camera" to specify the camera
#-t <duration> allows the user to choose how long the window will be displayed in milliseconds.
More instructions click me
sudo rm -rf /boot/dt-blob.bin
Please refer to Raspberry Pi Manual