-
Notifications
You must be signed in to change notification settings - Fork 15
OneInchEye Quick Start Guide
This quick start guide will help you set up and start using your OneInchEye camera board for Raspberry Pi Compute Module 4 or Raspberry Pi5. Please follow the steps outlined below to set up and start using your camera board.
The following guide has updated for bookworm.
Make sure you are using Raspberry Pi5 or your Raspberry Pi Compute Module 4 board has a 22-pin FPC connector with the same pinout as the Raspberry Pi Compute Module 4 IO Board's CAM1 port.
Attach the OneInchEye camera board to the CAM1 connector.
FPC Guide.
And insure that the camera board is securely connected and that the pins are properly aligned.
Download and flash the latest 64bit Raspberry Pi OS for your board. Then insert the microSD card (with the flashed OS) into your Raspberry Pi board.
Connect your Raspberry Pi board to a power source and boot up the operating system.
We also need to recompile Libcamera and Libcamera-apps so that they recognize the IMX283 sensor. The following steps are similar to the Libcamera Compile Guide, but the repository is changed to a forked version that supports IMX283 (https://github.com/will127534/libcamera).
sudo apt install -y libboost-dev libgnutls28-dev openssl libtiff5-dev pybind11-dev qtbase5-dev libqt5core5a libqt5gui5 libqt5widgets5 meson cmake python3-yaml python3-ply
cd ~
git clone https://github.com/will127534/libcamera.git
cd libcamera
meson setup build --buildtype=release -Dpipelines=rpi/vc4,rpi/pisp -Dipas=rpi/vc4,rpi/pisp -Dv4l2=true -Dgstreamer=disabled -Dtest=false -Dlc-compliance=disabled -Dcam=disabled -Dqcam=disabled -Ddocumentation=disabled -Dpycamera=enabled
ninja -C build
sudo ninja -C build install
sudo apt install -y cmake libboost-program-options-dev libdrm-dev libexif-dev libepoxy-dev libjpeg-dev libtiff5-dev libpng-dev meson ninja-build libavcodec-dev libavdevice-dev libavformat-dev libswresample-dev
cd ~
git clone https://github.com/will127534/rpicam-apps.git
cd rpicam-apps
For Raspberry Pi OS:
meson setup build -Denable_libav=enabled -Denable_drm=enabled -Denable_egl=enabled -Denable_qt=enabled -Denable_opencv=disabled -Denable_tflite=disabled
For Raspberry Pi OS Lite:
meson setup build -Denable_libav=disabled -Denable_drm=enabled -Denable_egl=disabled -Denable_qt=disabled -Denable_opencv=disabled -Denable_tflite=disabled
Continuing with
meson compile -C build
sudo meson install -C build
sudo ldconfig
First, install the necessary tools (linux-headers
, dkms
, and git
):
sudo apt install linux-headers dkms git
Clone the repository to your local pi and navigate to the cloned directory:
git clone https://github.com/will127534/imx283-v4l2-driver.git
cd imx283-v4l2-driver/
Notes: If you are using kernel V6.1, use the branch kernel_6.1:
git clone https://github.com/will127534/imx283-v4l2-driver.git --branch kernel_6.1
cd imx283-v4l2-driver/
To compile and install the kernel driver, execute the provided installation script:
sudo ./setup.sh
Edit the boot configuration file using the following command:
sudo nano /boot/firmware/config.txt
In the opened editor, locate the line containing camera_auto_detect
and change its value to 0
. Then, add the line dtoverlay=imx283
. So, it will look like this:
camera_auto_detect=0
dtoverlay=imx283
After making these changes, save the file and exit the editor.
Side note is that if you want to use Cam/Disp port 0 (Only for RPI5), you can do dtoverlay=imx283,cam0
Run the following command to reboot the Raspberry Pi:
sudo reboot
Once the Raspberry Pi has rebooted, open a terminal window and run the following command to test the camera:
rpicam-still -r -o test.jpg -f -t 0
If you want to run it through SSH terminal and see the preview on a HDMI monitor like me, you can use:
export DISPLAY=:0; rpicam-still -r -o test.jpg -f -t 0
- "rpicam-apps only supports the raspberry pi platform"
If you got the "rpicam-apps only supports the raspberry pi platform" error, that can actually mean the driver is not loaded correctly, check if you see the imx283 in dmesg by
dmesg | grep imx283
, you should see some message like:
[ 3.328314] rp1-cfe 1f00110000.csi: found subdevice /axi/pcie@120000/rp1/i2c@88000/imx283@1a
[ 4.265573] imx283 6-001a: Device found
[ 4.265620] imx283 6-001a: Pixel Rate : 451968432
[ 4.265627] imx283 6-001a: Setting default HBLANK : 81, VBLANK : 336 with PixelRate: 451968432
[ 4.265644] rp1-cfe 1f00110000.csi: Using sensor imx283 6-001a for capture
And re-install the driver + double check the dtoverlay=imx283 should help
- Kernel header not found
If you are using a non-release version of Raspberry Pi Kernel, it might not be in the kernel-header package and you will need to download it using
rpi-source
Github